public override void Closing() { if (!_selectionMade) { //NOTE: Always fire location selection event, so subscribers can unsubscribe AppointmentDateSelectionMessageEvent.Publish(TaskResult.Canceled, null); } }
private async void AddNewAppointmentTime(DateTimeResult newTime) { _selectionMade = true; if (newTime.SelectedDate < DateTime.Now) { await CC.UserNotifier.ShowMessageAsync("You can't select an appointment in the past", "Invalid Appointment"); } else { AppointmentDateSelectionMessageEvent.Publish(TaskResult.Success, newTime); await Close(); } }