public BillingVM() { GlobalVM.StockLayout.verticalMenu.Children.Clear(); companyData = new StockVerticalMenuItem(); bills = new StockVerticalMenuItem(); createBill = new StockVerticalMenuItem(); viewBill = new StockVerticalMenuItem(); companyData.button.Content = "Cégadatok"; bills.button.Content = "Számlák"; createBill.button.Content = "Számla kiállítása"; viewBill.button.Content = "Számla megtekintése"; GlobalVM.StockLayout.verticalMenu.Children.Add(companyData); GlobalVM.StockLayout.verticalMenu.Children.Add(bills); GlobalVM.StockLayout.verticalMenu.Children.Add(createBill); GlobalVM.StockLayout.verticalMenu.Children.Add(viewBill); companyData.button.Click += CompanyDataView; bills.button.Click += BillsView; createBill.button.Click += CreateBillView; viewBill.button.Click += ViewBillView; viewBill.IsEnabledTrigger = false; createBill.IsEnabledTrigger = GlobalVM.StockLayout.headerContent.Content != null; }
public EvidenceVM() { GlobalVM.StockLayout.verticalMenu.Children.Clear(); evidences = new StockVerticalMenuItem(); newEvidence = new StockVerticalMenuItem(); importEvidence = new StockVerticalMenuItem(); viewEvidence = new StockVerticalMenuItem(); editEvidence = new StockVerticalMenuItem(); evidences.button.Content = "Eddigi státuszok"; newEvidence.button.Content = "Új státusz"; importEvidence.button.Content = "Státusz importálása"; viewEvidence.button.Content = "Státusz megtekintése"; editEvidence.button.Content = "Státusz szerkesztése"; GlobalVM.StockLayout.verticalMenu.Children.Add(evidences); GlobalVM.StockLayout.verticalMenu.Children.Add(newEvidence); GlobalVM.StockLayout.verticalMenu.Children.Add(importEvidence); GlobalVM.StockLayout.verticalMenu.Children.Add(viewEvidence); GlobalVM.StockLayout.verticalMenu.Children.Add(editEvidence); evidences.button.Click += EvidencesView; newEvidence.button.Click += NewEvidenceView; importEvidence.button.Click += ImportEvidenceView; viewEvidence.button.Click += ViewEvidenceView; editEvidence.button.Click += EditEvidenceView; viewEvidence.IsEnabledTrigger = false; editEvidence.IsEnabledTrigger = false; newEvidence.IsEnabledTrigger = !GlobalVM.GlobalM.JustImportDocuments; }
protected internal async void Check(StockVerticalMenuItem select, Action OK, Action No) { earlierItem = currentItem; if (!currentItem.Equals(select)) { await Loading.Show(); currentItem = select; new FormChecking(OK, No, true); } }
protected internal async Task ViewLoad(Func <UserControl> method, StockVerticalMenuItem button) { await Task.Factory.StartNew(method, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.FromCurrentSynchronizationContext()).ContinueWith(async task => { GlobalVM.StockLayout.actualContent.Content = task.Result; button.button_Click(button.button, new RoutedEventArgs(Button.ClickEvent)); await Loading.Hide(); }, TaskScheduler.FromCurrentSynchronizationContext()); currentItem = button; }
public UsersVM() { GlobalVM.StockLayout.verticalMenu.Children.Clear(); registration = new StockVerticalMenuItem(); login = new StockVerticalMenuItem(); passChange = new StockVerticalMenuItem(); detailsModify = new StockVerticalMenuItem(); surgeryTime = new StockVerticalMenuItem(); userDelete = new StockVerticalMenuItem(); registration.button.Content = "Regisztráció"; login.button.Content = "Bejelentkezés"; passChange.button.Content = "Jelszó módosítása"; detailsModify.button.Content = "Adatok módosítása"; surgeryTime.button.Content = "Rendelési idő"; userDelete.button.Content = "Felhasználói fiók\ntörlése"; GlobalVM.StockLayout.verticalMenu.Children.Add(registration); GlobalVM.StockLayout.verticalMenu.Children.Add(login); GlobalVM.StockLayout.verticalMenu.Children.Add(passChange); GlobalVM.StockLayout.verticalMenu.Children.Add(detailsModify); GlobalVM.StockLayout.verticalMenu.Children.Add(surgeryTime); GlobalVM.StockLayout.verticalMenu.Children.Add(userDelete); if (GlobalVM.GlobalM.AccountID == null) { registration.button.Click += RegistrationView; login.button.Click += LoginView; passChange.button.IsEnabled = false; detailsModify.button.IsEnabled = false; surgeryTime.button.IsEnabled = false; userDelete.button.IsEnabled = false; } else { registration.button.Click += RegistrateWhenLogin; login.button.IsEnabled = false; passChange.button.Click += PassChangeView; detailsModify.button.Click += DetailsModifyView; surgeryTime.button.Click += SurgeryTimeView; userDelete.button.Click += UserDeleteView; } }
public SettingsVM() { GlobalVM.StockLayout.verticalMenu.Children.Clear(); services = new StockVerticalMenuItem(); users = new StockVerticalMenuItem(); priviledges = new StockVerticalMenuItem(); facilityData = new StockVerticalMenuItem(); connection = new StockVerticalMenuItem(); security = new StockVerticalMenuItem(); services.button.Content = "Szolgáltatások\nkezelése"; users.button.Content = "Felhasználók"; priviledges.button.Content = "Jogosultságok"; facilityData.button.Content = "Intézmény adatai"; connection.button.Content = "Adatbázis kapcsolat\nbeállítása"; security.button.Content = "Biztonsági profil"; GlobalVM.StockLayout.verticalMenu.Children.Add(services); GlobalVM.StockLayout.verticalMenu.Children.Add(users); GlobalVM.StockLayout.verticalMenu.Children.Add(priviledges); GlobalVM.StockLayout.verticalMenu.Children.Add(facilityData); GlobalVM.StockLayout.verticalMenu.Children.Add(connection); GlobalVM.StockLayout.verticalMenu.Children.Add(security); if (GlobalVM.GlobalM.Secure) { services.button.IsEnabled = false; users.button.IsEnabled = false; priviledges.button.IsEnabled = false; facilityData.button.IsEnabled = false; connection.button.Click += ConnectionView; security.button.IsEnabled = false; } else { services.button.Click += ServicesView; users.button.Click += UsersView; priviledges.button.Click += PriviledgesView; facilityData.button.Click += FacilityDataView; connection.button.Click += ConnectionView; security.button.Click += SecurityView; } }
private void Start() { GlobalVM.StockLayout.verticalMenu.Children.Clear(); newPatient = new StockVerticalMenuItem(); patientList = new StockVerticalMenuItem(); patientDetails = new StockVerticalMenuItem(); newPatient.button.Content = "Új páciens felvétele"; patientList.button.Content = "Páciensek listája"; patientDetails.button.Content = "Kiválasztott páciens\nadatai"; GlobalVM.StockLayout.verticalMenu.Children.Add(newPatient); GlobalVM.StockLayout.verticalMenu.Children.Add(patientList); GlobalVM.StockLayout.verticalMenu.Children.Add(patientDetails); newPatient.button.Click += NewPatientView; patientList.button.Click += PatientListView; patientDetails.button.Click += PatientDetailsView; Selected(); CheckUserData(); }
public ExaminationVM() { GlobalVM.StockLayout.verticalMenu.Children.Clear(); examinations = new StockVerticalMenuItem(); newExamination = new StockVerticalMenuItem(); importExamination = new StockVerticalMenuItem(); view = new StockVerticalMenuItem(); edit = new StockVerticalMenuItem(); examinationPlan = new StockVerticalMenuItem(); examinations.button.Content = "Eddigi vizsgálati\neredmények"; newExamination.button.Content = "Új vizsgálat"; importExamination.button.Content = "Vizsgálati anyagok\nimportálása"; view.button.Content = "Vizsgálat\nmegtekintése"; edit.button.Content = "Vizsgálat\nszerkesztése"; examinationPlan.button.Content = "Kezelési terv"; GlobalVM.StockLayout.verticalMenu.Children.Add(examinations); GlobalVM.StockLayout.verticalMenu.Children.Add(newExamination); GlobalVM.StockLayout.verticalMenu.Children.Add(importExamination); GlobalVM.StockLayout.verticalMenu.Children.Add(view); GlobalVM.StockLayout.verticalMenu.Children.Add(edit); GlobalVM.StockLayout.verticalMenu.Children.Add(examinationPlan); examinations.button.Click += ExaminationsView; newExamination.button.Click += NewExaminaionView; importExamination.button.Click += ImportExaminationView; view.button.Click += ViewView; edit.button.Click += EditView; examinationPlan.button.Click += ExaminationPlanView; view.IsEnabledTrigger = false; edit.IsEnabledTrigger = false; newExamination.IsEnabledTrigger = !GlobalVM.GlobalM.JustImportDocuments; }