public SinglePatientViewModel(string login, int idPatient) { _currentLogin = login; _idPatient = idPatient; DetailsUC = new DetailsPatientUC(_currentLogin, _idPatient); InitializeCommands(); }
/// <summary> /// Handles subview navigation /// </summary> /// <param name="index"></param> private void ChangeUC(int index) { try { EPatientUserControl userControl = (EPatientUserControl)index; switch (userControl) { case EPatientUserControl.DETAILS: DetailsUC = new DetailsPatientUC(_currentLogin, _idPatient); break; case EPatientUserControl.OBSERVATIONS: ObservationsUC = new ObservationsPatientUC(_currentLogin, _idPatient); break; case EPatientUserControl.GRAPH: ChartUC = new ChartPatientUC(_currentLogin, _idPatient); break; case EPatientUserControl.LIVE: LiveUC = new LivePatientUC(_currentLogin, _idPatient); break; default: break; } } catch (Exception) { } }