From f4d1aac5e6b1d145c992394149d282c58806c868 Mon Sep 17 00:00:00 2001 From: Mohammad Aljammal Date: Thu, 15 Apr 2021 15:44:44 +0300 Subject: [PATCH] hot fixes on doctor replay and schedule --- lib/client/base_app_client.dart | 4 ++-- .../list_doctor_working_hours_table_model.dart | 7 +++++++ lib/widgets/doctor/doctor_reply_widget.dart | 1 + lib/widgets/doctor/my_schedule_widget.dart | 17 +++++++++++++++-- 4 files changed, 25 insertions(+), 4 deletions(-) diff --git a/lib/client/base_app_client.dart b/lib/client/base_app_client.dart index bbc26022..d31d4513 100644 --- a/lib/client/base_app_client.dart +++ b/lib/client/base_app_client.dart @@ -86,8 +86,8 @@ class BaseAppClient { print("URL : $url"); print("Body : ${json.encode(body)}"); - String request= json.encode(body); - var asd=""; + String request= json.encode(body); + var asd=""; if (await Helpers.checkConnection()) { diff --git a/lib/models/doctor/list_doctor_working_hours_table_model.dart b/lib/models/doctor/list_doctor_working_hours_table_model.dart index 5f1630bc..32c3f04a 100644 --- a/lib/models/doctor/list_doctor_working_hours_table_model.dart +++ b/lib/models/doctor/list_doctor_working_hours_table_model.dart @@ -4,6 +4,9 @@ class ListDoctorWorkingHoursTable { DateTime date; String dayName; String workingHours; + String projectName; + String clinicName; + ListDoctorWorkingHoursTable({ this.date, @@ -15,6 +18,8 @@ class ListDoctorWorkingHoursTable { date = Helpers.convertStringToDate(json['Date']); dayName = json['DayName']; workingHours = json['WorkingHours']; + projectName = json['ProjectName']; + clinicName = json['ClinicName']; } Map toJson() { @@ -22,6 +27,8 @@ class ListDoctorWorkingHoursTable { data['Date'] = this.date; data['DayName'] = this.dayName; data['WorkingHours'] = this.workingHours; + data['ProjectName'] = this.projectName; + data['ClinicName'] = this.clinicName; return data; } diff --git a/lib/widgets/doctor/doctor_reply_widget.dart b/lib/widgets/doctor/doctor_reply_widget.dart index fbdfe686..ad2ee7f3 100644 --- a/lib/widgets/doctor/doctor_reply_widget.dart +++ b/lib/widgets/doctor/doctor_reply_widget.dart @@ -63,6 +63,7 @@ class _DoctorReplyWidgetState extends State { ), ), Column( + crossAxisAlignment: CrossAxisAlignment.end, children: [ AppText( DateUtils.getDateTimeFromServerFormat( diff --git a/lib/widgets/doctor/my_schedule_widget.dart b/lib/widgets/doctor/my_schedule_widget.dart index 40b24cba..6c9e51cf 100644 --- a/lib/widgets/doctor/my_schedule_widget.dart +++ b/lib/widgets/doctor/my_schedule_widget.dart @@ -59,7 +59,7 @@ class MyScheduleWidget extends StatelessWidget { if (DateUtils.isToday(workingHoursTable.date)) AppText( "Today", - fontSize: 2.5 * SizeConfig.textMultiplier, + fontSize: 1.8 * SizeConfig.textMultiplier, fontFamily: 'Poppins', color: Colors.green[500], // fontSize: 18 @@ -72,10 +72,17 @@ class MyScheduleWidget extends StatelessWidget { children: workingHours.map((work) { return Container( child: Column( + crossAxisAlignment: CrossAxisAlignment.start, children: [ SizedBox( height: 5, ), + if(workingHoursTable.clinicName!=null) + AppText( + workingHoursTable.clinicName??"", + fontSize: 15, + fontWeight: FontWeight.w700, + ), Container( width: MediaQuery.of(context).size.width*0.55, child: AppText( @@ -83,7 +90,13 @@ class MyScheduleWidget extends StatelessWidget { fontSize: 15, fontWeight: FontWeight.w300, ), - ) + ), + if(workingHoursTable.projectName!=null) + AppText( + workingHoursTable.projectName??"", + fontSize: 15, + fontWeight: FontWeight.w700, + ), ], ), );