public void OnService3(object sender, System.EventArgs args) { btn_service3.IsEnabled = false; text_service3.IsEnabled = false; App.servicename = service3.serviceName; Image image = sender as Image; if (image != null) { string source = image.Source as FileImageSource; if (String.Equals(source, "bluebutton.png")) { image.Source = "bluebutton2.png"; } else { image.Source = "bluebutton.png"; } } UIReturn uiReturn = BranchActionsController.getInstance().reserveQueueBranch(service3); if (uiReturn.isSuccess) { BranchSessionModel.bookingQ = (Queue)uiReturn.returnObject; if (BranchSessionModel.bookingQ != null) { Navigation.PushAsync(new BranchSummaryQueuePage()); } } else { DisplayAlert("Error", uiReturn.getDescription(), "Cancel"); } }
public void getService() { List <Service> Service = (List <Service>)BranchActionsController.getInstance().getBranchServices().returnObject; service1 = Service[0]; service2 = Service[1]; service3 = Service[2]; service4 = Service[3]; service5 = Service[4]; service6 = Service[5]; service7 = Service[6]; service8 = Service[7]; service9 = Service[8]; service10 = Service[9]; service11 = Service[10]; service12 = Service[11]; service13 = Service[12]; service14 = Service[13]; service15 = Service[14]; service16 = Service[15]; service17 = Service[16]; text_service1.Text = service1.serviceName; text_service2.Text = service2.serviceName; text_service3.Text = service3.serviceName; text_service4.Text = service4.serviceName; text_service5.Text = service5.serviceName; text_service6.Text = service6.serviceName; text_service7.Text = service7.serviceName; text_service8.Text = service8.serviceName; text_service9.Text = service9.serviceName; text_service10.Text = service10.serviceName; text_service11.Text = service11.serviceName; text_service12.Text = service12.serviceName; text_service13.Text = service13.serviceName; text_service14.Text = service14.serviceName; text_service15.Text = service15.serviceName; text_service16.Text = service16.serviceName; text_service17.Text = service17.serviceName; btn_service1.IsEnabled = true; text_service1.IsEnabled = true; btn_service2.IsEnabled = true; text_service2.IsEnabled = true; btn_service3.IsEnabled = true; text_service3.IsEnabled = true; btn_service4.IsEnabled = true; text_service4.IsEnabled = true; btn_service5.IsEnabled = true; text_service5.IsEnabled = true; btn_service6.IsEnabled = true; text_service6.IsEnabled = true; btn_service7.IsEnabled = true; text_service7.IsEnabled = true; btn_service8.IsEnabled = true; text_service8.IsEnabled = true; btn_service9.IsEnabled = true; text_service9.IsEnabled = true; btn_service10.IsEnabled = true; text_service10.IsEnabled = true; btn_service11.IsEnabled = true; text_service11.IsEnabled = true; btn_service12.IsEnabled = true; text_service12.IsEnabled = true; btn_service13.IsEnabled = true; text_service13.IsEnabled = true; btn_service14.IsEnabled = true; text_service14.IsEnabled = true; btn_service15.IsEnabled = true; text_service15.IsEnabled = true; btn_service16.IsEnabled = true; text_service16.IsEnabled = true; btn_service17.IsEnabled = true; text_service17.IsEnabled = true; }
public void OnImageSignin(object sender, System.EventArgs args) { if (CrossConnectivity.Current.IsConnected) { var username = mUsernameEntry.Text; var password = mPasswordEntry.Text; Login MasQLogin = new Login(username, password); UIReturn uiReturn = BranchLoginController.getInstance().LoginBranch(MasQLogin); if (uiReturn.isSuccess) { if (App.IPAdress != "") { List <Service> Service = (List <Service>)BranchActionsController.getInstance().getBranchServices().returnObject; int CountService = Service.Count; //CountService = 2; if (CountService == 1) { App.NumberServiceBranch = 1; Navigation.PushAsync(new Service1Page()); } else if (CountService == 2) { App.NumberServiceBranch = 1; Navigation.PushAsync(new Service2Page()); } else if (CountService == 3) { App.NumberServiceBranch = 3; Navigation.PushAsync(new Service3Page()); } else if (CountService == 4) { App.NumberServiceBranch = 4; Navigation.PushAsync(new Service4Page()); } else if (CountService == 5) { App.NumberServiceBranch = 5; Navigation.PushAsync(new Service5Page()); } else if (CountService == 6) { App.NumberServiceBranch = 6; Navigation.PushAsync(new Service6Page()); } else if (CountService == 7) { App.NumberServiceBranch = 7; Navigation.PushAsync(new Service7Page()); } else if (CountService == 8) { App.NumberServiceBranch = 8; Navigation.PushAsync(new Service8Page()); } else if (CountService == 9) { App.NumberServiceBranch = 9; Navigation.PushAsync(new Service9Page()); } else if (CountService == 10) { App.NumberServiceBranch = 10; Navigation.PushAsync(new Service10Page()); } else if (CountService == 11) { App.NumberServiceBranch = 11; Navigation.PushAsync(new Service11Page()); } else if (CountService == 12) { App.NumberServiceBranch = 12; Navigation.PushAsync(new Service12Page()); } else if (CountService == 13) { App.NumberServiceBranch = 13; Navigation.PushAsync(new Service13Page()); } else if (CountService == 14) { App.NumberServiceBranch = 14; Navigation.PushAsync(new Service14Page()); } else if (CountService == 15) { App.NumberServiceBranch = 15; Navigation.PushAsync(new Service15Page()); } else if (CountService == 16) { App.NumberServiceBranch = 16; Navigation.PushAsync(new Service16Page()); } else if (CountService == 17) { App.NumberServiceBranch = 17; Navigation.PushAsync(new Service17Page()); } else if (CountService == 18) { App.NumberServiceBranch = 18; Navigation.PushAsync(new Service18Page()); } else if (CountService == 19) { App.NumberServiceBranch = 19; Navigation.PushAsync(new Service19Page()); } else if (CountService == 20) { App.NumberServiceBranch = 20; Navigation.PushAsync(new Service20Page()); } } else { DisplayAlert(App.AppicationName, "กรุณาตั้งค่า IP Address ก่อนเข้าระบบ", "Close"); Navigation.PushAsync(new BranchSetIPAddress()); } } else { DisplayAlert(App.AppicationName, uiReturn.getDescription(), "Close"); } } else { DisplayAlert(App.AppicationName, App.NoInternet, "Close"); } }
public void getService() { List <Service> Service = (List <Service>)BranchActionsController.getInstance().getBranchServices().returnObject; ServiceListview.ItemsSource = Service; }