private void HandleUpdateClinicianAppointmentException(ExceptionInfo ex) { UpdateSchedule(true); _userDialogService.ShowDialog(ex.Message, "UpdateClinicianAppointmentCompleted", UserDialogServiceOptions.Ok); if (_previousClinicanKey != 0) { var appointmentUpdatedEventArgs = new AppointmentUpdatedEventArgs { ClinicianKey = _previousClinicanKey }; _eventAggregator.GetEvent <AppointmentUpdatedEvent> ().Publish(appointmentUpdatedEventArgs); } }
/// <summary> /// Requests the completed. /// </summary> /// <param name="receivedResponses">The received responses.</param> protected override void RequestCompleted(ReceivedResponses receivedResponses) { if (EditingDto != null) { EditingDto.PropertyChanged -= HandleDtoPropertyChanged; } base.RequestCompleted(receivedResponses); if (EditingDto != null) { EditingDto.PropertyChanged += HandleDtoPropertyChanged; } IsEdit = false; if (_isCreating) { _isCreating = false; if (EditingDto.ClinicianKey != null && EditingDto.AppointmentStartDateTime != null && EditingDto.AppointmentEndDateTime != null) { var appointmentCreatedEvent = new AppointmentCreatedEventArgs { AppointmentKey = EditingDto.AppointmentKey, PatientKey = EditingDto.PatientKey, ClinicianKey = EditingDto.ClinicianKey.Value, StartDateTime = EditingDto.AppointmentStartDateTime.Value, EndDateTime = EditingDto.AppointmentEndDateTime.Value }; _eventAggregator.GetEvent <AppointmentCreatedEvent> ().Publish(appointmentCreatedEvent); } } else if (_isUpdating) { if (EditingDto.ClinicianKey != null) { var appointmentUpdatedEvent = new AppointmentUpdatedEventArgs { ClinicianKey = EditingDto.ClinicianKey.Value }; _eventAggregator.GetEvent <AppointmentUpdatedEvent> ().Publish(appointmentUpdatedEvent); } } RaisePropertyChanged(() => IsCreate); RaiseVisitChanged(); EditingWrapper.EditableDto = EditingDto; }
private void HandleUpdateClinicianAppointmentCompleted(ReceivedResponses receivedResponses) { var response = receivedResponses.Get <UpdateClinicianAppointmentResponse> (); var clinicianAppointmentDto = response.ClinicianAppointmentDto; RaiseVisitChanged(clinicianAppointmentDto); ClinicianSchedule.AvailableAppointments = ClinicianSchedule.TotalAppointments - ClinicianSchedule.ClinicianAppointments.Count; if (_previousClinicanKey != 0) { var appointmentUpdatedEventArgs = new AppointmentUpdatedEventArgs { ClinicianKey = _previousClinicanKey }; _eventAggregator.GetEvent <AppointmentUpdatedEvent> ().Publish(appointmentUpdatedEventArgs); } IsLoading = false; }
private void HandleUpdateClinicianAppointmentException ( ExceptionInfo ex ) { UpdateSchedule ( true ); _userDialogService.ShowDialog ( ex.Message, "UpdateClinicianAppointmentCompleted", UserDialogServiceOptions.Ok ); if ( _previousClinicanKey != 0 ) { var appointmentUpdatedEventArgs = new AppointmentUpdatedEventArgs { ClinicianKey = _previousClinicanKey }; _eventAggregator.GetEvent<AppointmentUpdatedEvent> ().Publish ( appointmentUpdatedEventArgs ); } }
private void HandleUpdateClinicianAppointmentCompleted ( ReceivedResponses receivedResponses ) { var response = receivedResponses.Get<UpdateClinicianAppointmentResponse> (); var clinicianAppointmentDto = response.ClinicianAppointmentDto; RaiseVisitChanged ( clinicianAppointmentDto ); ClinicianSchedule.AvailableAppointments = ClinicianSchedule.TotalAppointments - ClinicianSchedule.ClinicianAppointments.Count; if ( _previousClinicanKey != 0 ) { var appointmentUpdatedEventArgs = new AppointmentUpdatedEventArgs { ClinicianKey = _previousClinicanKey }; _eventAggregator.GetEvent<AppointmentUpdatedEvent> ().Publish ( appointmentUpdatedEventArgs ); } IsLoading = false; }
/// <summary> /// Filters the appointment updated events. /// </summary> /// <param name="appointmentUpdatedEventArgs">The <see cref="Rem.Ria.PatientModule.FrontDeskDashboard.AppointmentUpdatedEventArgs"/> instance containing the event data.</param> /// <returns>A <see cref="System.Boolean"/></returns> public bool FilterAppointmentUpdatedEvents ( AppointmentUpdatedEventArgs appointmentUpdatedEventArgs ) { return appointmentUpdatedEventArgs.ClinicianKey == ClinicianSchedule.ClinicianKey; }
/// <summary> /// Appointments the updated event handler. /// </summary> /// <param name="obj">The <see cref="Rem.Ria.PatientModule.FrontDeskDashboard.AppointmentUpdatedEventArgs"/> instance containing the event data.</param> public void AppointmentUpdatedEventHandler ( AppointmentUpdatedEventArgs obj ) { Deployment.Current.InvokeIfNeeded ( () => UpdateSchedule ( true ) ); }
/// <summary> /// Filters the appointment updated events. /// </summary> /// <param name="appointmentUpdatedEventArgs">The <see cref="Rem.Ria.PatientModule.FrontDeskDashboard.AppointmentUpdatedEventArgs"/> instance containing the event data.</param> /// <returns>A <see cref="System.Boolean"/></returns> public bool FilterAppointmentUpdatedEvents(AppointmentUpdatedEventArgs appointmentUpdatedEventArgs) { return(appointmentUpdatedEventArgs.ClinicianKey == ClinicianSchedule.ClinicianKey); }
/// <summary> /// Appointments the updated event handler. /// </summary> /// <param name="obj">The <see cref="Rem.Ria.PatientModule.FrontDeskDashboard.AppointmentUpdatedEventArgs"/> instance containing the event data.</param> public void AppointmentUpdatedEventHandler(AppointmentUpdatedEventArgs obj) { Deployment.Current.InvokeIfNeeded(() => UpdateSchedule(true)); }