|
|
|
|
@ -216,87 +216,91 @@ class _MyAppointmentsState extends State<MyAppointments>
|
|
|
|
|
|
|
|
|
|
Widget getBookedAppointments() {
|
|
|
|
|
return Container(
|
|
|
|
|
child: widget.bookedAppoList.length != 0
|
|
|
|
|
? new ListView.builder(
|
|
|
|
|
itemCount: widget.bookedAppoList.length,
|
|
|
|
|
itemBuilder: (context, i) {
|
|
|
|
|
return AppointmentCard(
|
|
|
|
|
appo: widget.bookedAppoList[i],
|
|
|
|
|
onReloadAppointmentHistory: getPatientAppointmentHistory,
|
|
|
|
|
);
|
|
|
|
|
},
|
|
|
|
|
)
|
|
|
|
|
: Container(
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Image.asset(
|
|
|
|
|
"assets/images/new-design/noAppointmentIcon.png"),
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(top: 10.0),
|
|
|
|
|
child: Text(TranslationBase.of(context).noBookedAppointments,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 16.0,
|
|
|
|
|
)),
|
|
|
|
|
),
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(top: 10.0),
|
|
|
|
|
child: Container(
|
|
|
|
|
child: widget.bookedAppoList.length != 0
|
|
|
|
|
? SingleChildScrollView(
|
|
|
|
|
physics: BouncingScrollPhysics(),
|
|
|
|
|
child: Column(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
...List.generate(
|
|
|
|
|
widget._patientBookedAppointmentListHospital.length,
|
|
|
|
|
child: widget.bookedAppoList.length != 0
|
|
|
|
|
? new ListView.builder(
|
|
|
|
|
itemCount: widget.bookedAppoList.length,
|
|
|
|
|
itemBuilder: (context, i) {
|
|
|
|
|
return AppointmentCard(
|
|
|
|
|
appo: widget.bookedAppoList[i],
|
|
|
|
|
onReloadAppointmentHistory: getPatientAppointmentHistory,
|
|
|
|
|
);
|
|
|
|
|
},
|
|
|
|
|
)
|
|
|
|
|
: Container(
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
// Image.asset(
|
|
|
|
|
// "assets/images/new-design/noAppointmentIcon.png"),
|
|
|
|
|
// Container(
|
|
|
|
|
// margin: EdgeInsets.only(top: 10.0),
|
|
|
|
|
// child: Text(TranslationBase.of(context).noBookedAppointments,
|
|
|
|
|
// style: TextStyle(
|
|
|
|
|
// fontSize: 16.0,
|
|
|
|
|
// )),
|
|
|
|
|
// ),
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(top: 10.0),
|
|
|
|
|
child: Container(
|
|
|
|
|
child: widget.bookedAppoList.length != 0
|
|
|
|
|
? SingleChildScrollView(
|
|
|
|
|
physics: BouncingScrollPhysics(),
|
|
|
|
|
child: Column(
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
...List.generate(
|
|
|
|
|
widget._patientBookedAppointmentListHospital
|
|
|
|
|
.length,
|
|
|
|
|
(index) => AppExpandableNotifier(
|
|
|
|
|
title: widget
|
|
|
|
|
._patientBookedAppointmentListHospital[index]
|
|
|
|
|
.filterName,
|
|
|
|
|
bodyWidget: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
children: widget
|
|
|
|
|
._patientBookedAppointmentListHospital[index]
|
|
|
|
|
.patientDoctorAppointmentList
|
|
|
|
|
.map((doctor) {
|
|
|
|
|
return AppointmentCard(
|
|
|
|
|
appo: doctor,
|
|
|
|
|
onReloadAppointmentHistory:
|
|
|
|
|
getPatientAppointmentHistory,
|
|
|
|
|
);
|
|
|
|
|
}).toList(),
|
|
|
|
|
)),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container(
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Image.asset(
|
|
|
|
|
"assets/images/new-design/noAppointmentIcon.png"),
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(top: 10.0),
|
|
|
|
|
child: Text("No Booked Appointments",
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 16.0,
|
|
|
|
|
)),
|
|
|
|
|
title: widget
|
|
|
|
|
._patientBookedAppointmentListHospital[
|
|
|
|
|
index]
|
|
|
|
|
.filterName,
|
|
|
|
|
bodyWidget: Column(
|
|
|
|
|
crossAxisAlignment:
|
|
|
|
|
CrossAxisAlignment.start,
|
|
|
|
|
mainAxisAlignment:
|
|
|
|
|
MainAxisAlignment.spaceBetween,
|
|
|
|
|
children: widget
|
|
|
|
|
._patientBookedAppointmentListHospital[
|
|
|
|
|
index]
|
|
|
|
|
.patientDoctorAppointmentList
|
|
|
|
|
.map((doctor) {
|
|
|
|
|
return AppointmentCard(
|
|
|
|
|
appo: doctor,
|
|
|
|
|
onReloadAppointmentHistory:
|
|
|
|
|
getPatientAppointmentHistory,
|
|
|
|
|
);
|
|
|
|
|
}).toList(),
|
|
|
|
|
)),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
: Container(
|
|
|
|
|
child: Center(
|
|
|
|
|
child: Column(
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
|
children: <Widget>[
|
|
|
|
|
Image.asset(
|
|
|
|
|
"assets/images/new-design/noAppointmentIcon.png"),
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(top: 10.0),
|
|
|
|
|
child: Text("No Booked Appointments",
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 16.0,
|
|
|
|
|
)),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
|
|
|
|
|
))));
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
))));
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Widget getConfirmedAppointments() {
|
|
|
|
|
@ -341,7 +345,8 @@ class _MyAppointmentsState extends State<MyAppointments>
|
|
|
|
|
Image.asset("assets/images/new-design/noAppointmentIcon.png"),
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(top: 10.0),
|
|
|
|
|
child: Text(TranslationBase.of(context).noConfirmedAppointments ,
|
|
|
|
|
child: Text(
|
|
|
|
|
TranslationBase.of(context).noConfirmedAppointments,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 16.0,
|
|
|
|
|
)),
|
|
|
|
|
@ -363,23 +368,24 @@ class _MyAppointmentsState extends State<MyAppointments>
|
|
|
|
|
...List.generate(
|
|
|
|
|
widget._patientArrivedAppointmentListHospital.length,
|
|
|
|
|
(index) => AppExpandableNotifier(
|
|
|
|
|
title: widget
|
|
|
|
|
title: widget
|
|
|
|
|
._patientArrivedAppointmentListHospital[index]
|
|
|
|
|
.filterName,
|
|
|
|
|
bodyWidget: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
children: widget
|
|
|
|
|
._patientArrivedAppointmentListHospital[index]
|
|
|
|
|
.filterName,
|
|
|
|
|
bodyWidget: Column(
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
|
|
|
|
children: widget
|
|
|
|
|
._patientArrivedAppointmentListHospital[index]
|
|
|
|
|
.patientDoctorAppointmentList
|
|
|
|
|
.map((doctor) {
|
|
|
|
|
return AppointmentCard(
|
|
|
|
|
appo: doctor,
|
|
|
|
|
onReloadAppointmentHistory:
|
|
|
|
|
getPatientAppointmentHistory,
|
|
|
|
|
);
|
|
|
|
|
}).toList(),
|
|
|
|
|
)),
|
|
|
|
|
.patientDoctorAppointmentList
|
|
|
|
|
.map((doctor) {
|
|
|
|
|
return AppointmentCard(
|
|
|
|
|
appo: doctor,
|
|
|
|
|
onReloadAppointmentHistory:
|
|
|
|
|
getPatientAppointmentHistory,
|
|
|
|
|
);
|
|
|
|
|
}).toList(),
|
|
|
|
|
),
|
|
|
|
|
),
|
|
|
|
|
)
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
@ -394,10 +400,11 @@ class _MyAppointmentsState extends State<MyAppointments>
|
|
|
|
|
Image.asset("assets/images/new-design/noAppointmentIcon.png"),
|
|
|
|
|
Container(
|
|
|
|
|
margin: EdgeInsets.only(top: 10.0),
|
|
|
|
|
child: Text(TranslationBase.of(context).noArrivedAppointments,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 16.0,
|
|
|
|
|
)),
|
|
|
|
|
child:
|
|
|
|
|
Text(TranslationBase.of(context).noArrivedAppointments,
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
fontSize: 16.0,
|
|
|
|
|
)),
|
|
|
|
|
),
|
|
|
|
|
],
|
|
|
|
|
),
|
|
|
|
|
|