doctor list handled to be cleared when going back

pull/66/head
tahaalam 4 weeks ago
parent a4a32cca44
commit 786aa05b19

@ -88,7 +88,7 @@ class _SearchDoctorByNameState extends State<SearchDoctorByName> {
),
),
Visibility(
visible: bookAppointmentsViewModel.doctorsList.isNotEmpty,
visible: context.watch<BookAppointmentsViewModel>().doctorsList.isNotEmpty,
child: SizedBox(
height: 56.h,
width: 56.h,
@ -264,4 +264,9 @@ class _SearchDoctorByNameState extends State<SearchDoctorByName> {
),
);
}
@override
void dispose() {
bookAppointmentsViewModel.doctorsList.clear();
super.dispose();
}
}

Loading…
Cancel
Save