public PersonalPageDoctorViewModel(UsersInfoModel doctorInfoModel, CountMessageForPersonalPage countMessageForPersonalPage, Connected connected) { ConnectedID = connected.ConnectedID; _connectionManager = new ConnectionManager(); UserId = doctorInfoModel.Id; FirstName = doctorInfoModel.FirstName; LastName = doctorInfoModel.LastName; DateOfBirthPatient = doctorInfoModel.DateOfBirth.UtcDateTime; PhoneNumber = doctorInfoModel.PhoneNumber; Email = doctorInfoModel.Email; SelectDoctorCommand = new DelegateCommand <InfoUserModel>(SelectDoctor); SelectPatientCommand = new DelegateCommand <InfoUserModel>(SelectPatient); DoctorsList = new ObservableCollection <InfoUserModel>(doctorInfoModel.DortorsList); PatientsList = new ObservableCollection <InfoUserModel>(doctorInfoModel.PatientsList); ButtonMessageCommand = new DelegateCommand(WriteMessageInChat); ActiveMessage(countMessageForPersonalPage.CountMessages); }
public PersonalPagePatientViewModel(UsersInfoModel patientInfoModel, CountMessageForPersonalPage countMessageForPersonalPage, Connected connected) { ConnectedID = connected.ConnectedID; _connectionManager = new ConnectionManager(); FirstName = patientInfoModel.FirstName; LastName = patientInfoModel.LastName; DateOfBirthPatient = patientInfoModel.DateOfBirth.UtcDateTime; PhoneNumber = patientInfoModel.PhoneNumber; Email = patientInfoModel.Email; IsTextBoxEnable = false; DateHistory = patientInfoModel.Date; DoctorsList = new ObservableCollection <InfoUserModel>(patientInfoModel.DortorsList); SelectDoctorCommand = new DelegateCommand <InfoUserModel>(SelectDoctor); ButtonMessageCommand = new DelegateCommand(WriteMessageInChat); UserId = patientInfoModel.Id; ActiveMessage(countMessageForPersonalPage.CountMessages); }
public PersonalPageDoctor(UsersInfoModel patientInfoModel, CountMessageForPersonalPage countMessageForPersonalPage, Connected connected) { InitializeComponent(); DataContext = new PersonalPageDoctorViewModel(patientInfoModel, countMessageForPersonalPage, connected); }
public async Task <CountMessageForPersonalPage> CountMessagesAsync([FromBody] CountMessageForPersonalPage input) { return(await _userService.CountMessages(input.UserId)); }