nearest appo crash fixed

merge-update-with-lab-changes
haroon amjad 3 years ago
parent 83ca5e8e4c
commit e4fe4baa27

@ -243,8 +243,7 @@ class _SearchByClinicState extends State<SearchByClinic> {
Navigator.push(context, FadePage(page: LaserClinic())); Navigator.push(context, FadePage(page: LaserClinic()));
} else if (!isDentalSelectedAndSupported()) { } else if (!isDentalSelectedAndSupported()) {
projectDropdownValue = ""; projectDropdownValue = "";
if(!nearestAppo) if (!nearestAppo) getDoctorsList(context);
getDoctorsList(context);
} else {} } else {}
}); });
projectViewModel.analytics.appointment.book_appointment_select_clinic(appointment_type: 'regular', clinic: clincs.clinicDescription); projectViewModel.analytics.appointment.book_appointment_select_clinic(appointment_type: 'regular', clinic: clincs.clinicDescription);
@ -531,8 +530,8 @@ class _SearchByClinicState extends State<SearchByClinic> {
searchInfo.clinic = selectedClinic; searchInfo.clinic = selectedClinic;
searchInfo.date = DateTime.now(); searchInfo.date = DateTime.now();
if(projectViewModel.isLogin) { if (projectViewModel.isLogin) {
if(projectViewModel.user.age > 12) { if (projectViewModel.user.age > 12) {
navigateToDentalComplaints(context, searchInfo); navigateToDentalComplaints(context, searchInfo);
} else { } else {
callDoctorsSearchAPI(17); callDoctorsSearchAPI(17);
@ -606,6 +605,8 @@ class _SearchByClinicState extends State<SearchByClinic> {
result = LinkedHashSet<String>.from(arr).toList(); result = LinkedHashSet<String>.from(arr).toList();
numAll = result.length; numAll = result.length;
nearestAppo = false;
isProjectLoaded = false;
navigateToSearchResults(context, doctorsList, _patientDoctorAppointmentListHospital); navigateToSearchResults(context, doctorsList, _patientDoctorAppointmentListHospital);
} else { } else {
AppToast.showErrorToast(message: res['ErrorEndUserMessage']); AppToast.showErrorToast(message: res['ErrorEndUserMessage']);

Loading…
Cancel
Save