Waiting appointment bug fix

merge-update-with-lab-changes
haroon amjad 2 years ago
parent 605f02afe2
commit c6ee01c652

@ -280,7 +280,9 @@ class _DocAvailableAppointmentsState extends State<DocAvailableAppointments> wit
selectedDateJSON = freeSlotsResponse[0];
});
openTimeSlotsPickerForDate(
(isLiveCareSchedule != null && isLiveCareSchedule)
isWaitingAppointmentAvailable
? DateTime.now()
: (isLiveCareSchedule != null && isLiveCareSchedule)
? DateUtil.convertStringToDate(selectedDateJSON)
: DateUtil.convertStringToDateSaudiTimezone(
selectedDateJSON,
@ -289,7 +291,9 @@ class _DocAvailableAppointmentsState extends State<DocAvailableAppointments> wit
),
),
docFreeSlots);
_calendarController.selectedDate = (isLiveCareSchedule != null && isLiveCareSchedule)
_calendarController.selectedDate = isWaitingAppointmentAvailable
? DateTime.now()
: (isLiveCareSchedule != null && isLiveCareSchedule)
? DateUtil.convertStringToDate(selectedDateJSON)
: DateUtil.convertStringToDateSaudiTimezone(
selectedDateJSON,
@ -362,13 +366,13 @@ class _DocAvailableAppointmentsState extends State<DocAvailableAppointments> wit
setState(() {
_events.clear();
_events = value;
if (widget.doctorSchedule != null)
{
if (widget.doctorSchedule != null) {
_onDaySelected(DateUtil.convertStringToDate(widget.doctorSchedule['Date']));
_calendarController.selectedDate = DateUtil.convertStringToDate(
widget.doctorSchedule['Date'],
);
};
}
;
});
});
} else {

Loading…
Cancel
Save