private void tSubmit(object sender, RoutedEventArgs e) { employeeList1 c1 = new employeeList1(); c1.Name = pToolList.Text; if (lTool.Items.Count > 0) { c1.SNo = lTool.Items.Count + 1; } else { c1.SNo = 1; } tList1.Add(c1); lTool.Items.Add(c1); }
private void mSubmit(object sender, RoutedEventArgs e) { employeeList1 c1 = new employeeList1(); c1.Name = pMachineList.Text; if (lMachine.Items.Count > 0) { c1.SNo = lMachine.Items.Count + 1; } else { c1.SNo = 1; } mList1.Add(c1); lMachine.Items.Add(c1); }
private void ssubmit(object sender, RoutedEventArgs e) { endList4.Items.Clear(); employeeList1 Name = new employeeList1(); employeeList1 Name1 = new employeeList1(); employeeList1 Name2 = new employeeList1(); employeeList1 Name3 = new employeeList1(); Name.Name = pName.Text; Name.SNo = 1; endList4.Items.Add(Name); Name1.Name = pFrom.Text; Name1.SNo = 2; endList4.Items.Add(Name1); Name2.Name = pTo.Text; Name2.SNo = 3; endList4.Items.Add(Name2); Name3.Name = pQuantity.Text; Name3.SNo = 4; endList4.Items.Add(Name3); Nav_Prod.IsOpen = false; }
private async void updateMaster(string cName) { client = new FireSharp.FirebaseClient(config); FirebaseResponse response5 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/employeeLayout/count"); int count5; try { count5 = response5.ResultAs <int>(); } catch (Exception) { count5 = 0; } List <String> nameLt5 = new List <String>(); for (int i = 1; i <= count5; i++) { FirebaseResponse response1 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/employeeLayout/" + i); employeeList1 list1 = new employeeList1(); list1 = response1.ResultAs <employeeList1>(); string nameNw = list1.Name; nameLt5.Add(nameNw); } int cnt5 = nameLt5.Count; empList = new string[cnt5]; empList = nameLt5.ToArray(); FirebaseResponse response6 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/machineLayout/count"); int count6; try { count6 = response6.ResultAs <int>(); } catch (Exception) { count6 = 0; } List <String> nameLt6 = new List <String>(); for (int i = 1; i <= count6; i++) { FirebaseResponse response1 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/machineLayout/" + i); employeeList1 list1 = new employeeList1(); list1 = response1.ResultAs <employeeList1>(); string nameNw = list1.Name; nameLt6.Add(nameNw); } int cnt6 = nameLt6.Count; machineList = new string[cnt6]; machineList = nameLt6.ToArray(); }
private async void orderQuery(AutoSuggestBox sender, AutoSuggestBoxQuerySubmittedEventArgs args) { rc.Visibility = Visibility.Collapsed; progress1.Visibility = Visibility.Visible; sender.Text = args.QueryText; string cName = fOrderNo.Text; client = new FireSharp.FirebaseClient(config); FirebaseResponse response = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/"); routeCard ab = new routeCard(); ab = response.ResultAs <routeCard>(); fSalesNo.Text = ab.salesid; fStripSize.Text = ab.stripsize; fDate.Text = ab.date; fTime.Text = ab.time; fQuantityStrip.Text = ab.quantityS.ToString(); fCoilNo.Text = ab.coilno; fBatchNo.Text = ab.batchNo; FirebaseResponse response5 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/employeeLayout/count/"); int count5; try { count5 = response5.ResultAs <int>(); } catch { count5 = 0; } for (int i = 1; i <= count5; i++) { FirebaseResponse response1 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/employeeLayout/" + i); employeeList1 list1 = new employeeList1(); list1 = response1.ResultAs <employeeList1>(); endList1.Items.Add(list1); lEmployee.Items.Add(list1); } FirebaseResponse response6 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/machineLayout/count/"); int count6; try { count6 = response6.ResultAs <int>(); } catch (Exception) { count6 = 0; } for (int i = 1; i <= count6; i++) { FirebaseResponse response1 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/machineLayout/" + i); employeeList1 list1 = new employeeList1(); list1 = response1.ResultAs <employeeList1>(); endList2.Items.Add(list1); lMachine.Items.Add(list1); } FirebaseResponse response7 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/toolLayout/count/"); int count7; try { count7 = response7.ResultAs <int>(); } catch (Exception) { count7 = 0; } for (int i = 1; i <= count7; i++) { FirebaseResponse response1 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/toolLayout/" + i); employeeList1 list1 = new employeeList1(); list1 = response1.ResultAs <employeeList1>(); endList3.Items.Add(list1); lTool.Items.Add(list1); } FirebaseResponse response8 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/processLayout/count/"); int count8; try { count8 = response8.ResultAs <int>(); } catch (Exception) { count8 = 0; } for (int i = 1; i <= count8; i++) { FirebaseResponse response1 = await client.GetAsync("Manufacturing/RouteCard/" + cName + "/processLayout/" + i); employeeList1 list1 = new employeeList1(); list1 = response1.ResultAs <employeeList1>(); endList4.Items.Add(list1); } rc.Visibility = Visibility.Visible; progress1.Visibility = Visibility.Collapsed; }