From fb7536b10605dffd3b9556eae2804f8a2cd30ec6 Mon Sep 17 00:00:00 2001 From: Amjad Amireh Date: Wed, 3 Jun 2020 10:13:25 +0300 Subject: [PATCH 1/8] svg --- pubspec.lock | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/pubspec.lock b/pubspec.lock index 7cf1a612..afe0aa60 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -277,6 +277,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.0.7" + flutter_svg: + dependency: "direct main" + description: + name: flutter_svg + url: "https://pub.dartlang.org" + source: hosted + version: "0.17.4" flutter_test: dependency: "direct dev" description: flutter @@ -462,6 +469,20 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "1.6.4" + path_drawing: + dependency: transitive + description: + name: path_drawing + url: "https://pub.dartlang.org" + source: hosted + version: "0.4.1" + path_parsing: + dependency: transitive + description: + name: path_parsing + url: "https://pub.dartlang.org" + source: hosted + version: "0.1.4" pedantic: dependency: transitive description: From 10877ac65839edb112b4a5e014284e2e4b20543e Mon Sep 17 00:00:00 2001 From: Elham Rababah Date: Wed, 3 Jun 2020 10:17:25 +0300 Subject: [PATCH 2/8] improve vital sign item details --- lib/routes.dart | 13 +-- .../vital_sign/vital_sign_details_screen.dart | 91 ++----------------- .../profile/vital_sign/vital_sign_item.dart | 79 ++++++++++++++++ ...rt => vital_sign_item_details_screen.dart} | 30 ++---- ...dart => vital_sing_chart_and_detials.dart} | 0 .../shared/charts/app_time_series_chart.dart | 14 ++- 6 files changed, 110 insertions(+), 117 deletions(-) create mode 100644 lib/screens/patients/profile/vital_sign/vital_sign_item.dart rename lib/screens/patients/profile/vital_sign/{body_measurements_screen.dart => vital_sign_item_details_screen.dart} (82%) rename lib/screens/patients/profile/vital_sign/{vital_ding_chart_and_detials.dart => vital_sing_chart_and_detials.dart} (100%) diff --git a/lib/routes.dart b/lib/routes.dart index 9c87ff2f..f90e1ba9 100644 --- a/lib/routes.dart +++ b/lib/routes.dart @@ -1,11 +1,4 @@ -import 'package:doctor_app_flutter/config/config.dart'; -import 'package:doctor_app_flutter/screens/patients/profile/insurance_approvals_screen.dart'; -import 'package:doctor_app_flutter/screens/patients/profile/patient_orders_screen.dart'; -import 'package:doctor_app_flutter/screens/patients/profile/progress_note_screen.dart'; - -import './screens/patients/profile/vital_sign/body_measurements_screen.dart'; - import './screens/QR_reader_screen.dart'; import './screens/auth/change_password_screen.dart'; import './screens/auth/login_screen.dart'; @@ -21,11 +14,15 @@ import './screens/medicine/pharmacies_list_screen.dart'; import './screens/patients/patient_search_screen.dart'; import './screens/patients/patients_referred_screen.dart'; import './screens/patients/patients_screen.dart'; +import './screens/patients/profile/insurance_approvals_screen.dart'; import './screens/patients/profile/lab_result/lab_orders_screen.dart'; +import './screens/patients/profile/patient_orders_screen.dart'; import './screens/patients/profile/patient_profile_screen.dart'; import './screens/patients/profile/prescriptions/prescriptions_screen.dart'; +import './screens/patients/profile/progress_note_screen.dart'; import './screens/patients/profile/radiology/radiology_screen.dart'; import './screens/patients/profile/vital_sign/vital_sign_details_screen.dart'; +import './screens/patients/profile/vital_sign/vital_sign_item_details_screen.dart'; import './screens/patients/profile/vital_sign/vital_sign_screen.dart'; import './screens/profile_screen.dart'; import './screens/settings/settings_screen.dart'; @@ -91,5 +88,5 @@ var routes = { PATIENT_ORDERS: (_) => PatientsOrdersScreen(), PATIENT_INSURANCE_APPROVALS: (_) => InsuranceApprovalsScreen(), VITAL_SIGN_DETAILS: (_) => VitalSignDetailsScreen(), - BODY_MEASUREMENTS: (_) => BodyMeasurementsScreen() + BODY_MEASUREMENTS: (_) => VitalSignItemDetailsScreen() }; diff --git a/lib/screens/patients/profile/vital_sign/vital_sign_details_screen.dart b/lib/screens/patients/profile/vital_sign/vital_sign_details_screen.dart index 8b9cbead..ca21e7aa 100644 --- a/lib/screens/patients/profile/vital_sign/vital_sign_details_screen.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sign_details_screen.dart @@ -1,16 +1,16 @@ -import 'package:doctor_app_flutter/config/shared_pref_kay.dart'; -import 'package:doctor_app_flutter/lookups/patient_lookup.dart'; -import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; -import 'package:doctor_app_flutter/models/patient/vital_sign_req_model.dart'; -import 'package:doctor_app_flutter/providers/patients_provider.dart'; -import 'package:doctor_app_flutter/routes.dart'; -import 'package:doctor_app_flutter/util/dr_app_shared_pref.dart'; -import 'package:doctor_app_flutter/widgets/shared/rounded_container_widget.dart'; import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; +import '../../../../config/shared_pref_kay.dart'; import '../../../../config/size_config.dart'; +import '../../../../lookups/patient_lookup.dart'; +import '../../../../models/patient/patiant_info_model.dart'; +import '../../../../models/patient/vital_sign_req_model.dart'; import '../../../../models/patient/vital_sign_res_model.dart'; +import '../../../../providers/patients_provider.dart'; +import '../../../../routes.dart'; +import '../../../../screens/patients/profile/vital_sign/vital_sign_item.dart'; +import '../../../../util/dr_app_shared_pref.dart'; import '../../../../widgets/shared/app_scaffold_widget.dart'; DrAppSharedPreferances sharedPref = new DrAppSharedPreferances(); @@ -199,78 +199,3 @@ class _VitalSignDetailsScreenState extends State { } } -class VitalSignItem extends StatelessWidget { - const VitalSignItem( - {Key key, - @required this.url, - @required this.des, - this.lastVal = 'N/A', - this.unit = '', - this.height, - this.width}) - : super(key: key); - - final String url; - final String des; - final String lastVal; - final String unit; - - final double height; - final double width; - - @override - Widget build(BuildContext context) { - return RoundedContainer( - margin: 0.025 * SizeConfig.realScreenWidth, - height: 0.14 * SizeConfig.realScreenHeight, - width: 0.45 * SizeConfig.realScreenWidth, - child: Container( - padding: EdgeInsets.all(5), - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Expanded( - flex: 2, - child: Text( - des, - style: TextStyle( - fontSize: 1.7 * SizeConfig.textMultiplier, - color: Theme.of(context).primaryColor, - fontWeight: FontWeight.bold), - ), - ), - Expanded( - flex: 1, - child: Column( - // mainAxisAlignment: MainAxisAlignment.spaceEvenly, - // crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Expanded( - child: Image.asset( - url, - height: SizeConfig.heightMultiplier * 7, - ), - ), - Expanded( - child: RichText( - text: TextSpan( - style: TextStyle(color: Colors.black), - children: [ - new TextSpan(text: lastVal), - new TextSpan( - text: ' ${unit}', - style: - TextStyle(color: Theme.of(context).primaryColor)), - ], - ), - )) - ], - ), - ) - ], - ), - ), - ); - } -} diff --git a/lib/screens/patients/profile/vital_sign/vital_sign_item.dart b/lib/screens/patients/profile/vital_sign/vital_sign_item.dart new file mode 100644 index 00000000..702d7bac --- /dev/null +++ b/lib/screens/patients/profile/vital_sign/vital_sign_item.dart @@ -0,0 +1,79 @@ +import 'package:flutter/material.dart'; + +import '../../../../config/size_config.dart'; +import '../../../../widgets/shared/rounded_container_widget.dart'; +class VitalSignItem extends StatelessWidget { + const VitalSignItem( + {Key key, + @required this.url, + @required this.des, + this.lastVal = 'N/A', + this.unit = '', + this.height, + this.width}) + : super(key: key); + + final String url; + final String des; + final String lastVal; + final String unit; + + final double height; + final double width; + + @override + Widget build(BuildContext context) { + return RoundedContainer( + margin: 0.025 * SizeConfig.realScreenWidth, + height: 0.14 * SizeConfig.realScreenHeight, + width: 0.45 * SizeConfig.realScreenWidth, + child: Container( + padding: EdgeInsets.all(5), + child: Row( + mainAxisAlignment: MainAxisAlignment.spaceBetween, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Expanded( + flex: 2, + child: Text( + des, + style: TextStyle( + fontSize: 1.7 * SizeConfig.textMultiplier, + color: Theme.of(context).primaryColor, + fontWeight: FontWeight.bold), + ), + ), + Expanded( + flex: 1, + child: Column( + // mainAxisAlignment: MainAxisAlignment.spaceEvenly, + // crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Expanded( + child: Image.asset( + url, + height: SizeConfig.heightMultiplier * 7, + ), + ), + Expanded( + child: RichText( + text: TextSpan( + style: TextStyle(color: Colors.black), + children: [ + new TextSpan(text: lastVal), + new TextSpan( + text: ' ${unit}', + style: + TextStyle(color: Theme.of(context).primaryColor)), + ], + ), + )) + ], + ), + ) + ], + ), + ), + ); + } +} diff --git a/lib/screens/patients/profile/vital_sign/body_measurements_screen.dart b/lib/screens/patients/profile/vital_sign/vital_sign_item_details_screen.dart similarity index 82% rename from lib/screens/patients/profile/vital_sign/body_measurements_screen.dart rename to lib/screens/patients/profile/vital_sign/vital_sign_item_details_screen.dart index eb1f011d..8acfeaf0 100644 --- a/lib/screens/patients/profile/vital_sign/body_measurements_screen.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sign_item_details_screen.dart @@ -1,15 +1,14 @@ -import 'package:doctor_app_flutter/lookups/patient_lookup.dart'; -import 'package:doctor_app_flutter/models/patient/vital_sign_res_model.dart'; -import 'package:doctor_app_flutter/providers/patients_provider.dart'; -import 'package:doctor_app_flutter/screens/patients/profile/vital_sign/vital_ding_chart_and_detials.dart'; -import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart'; -import 'package:doctor_app_flutter/widgets/shared/charts/app_time_series_chart.dart'; -import 'package:doctor_app_flutter/widgets/shared/rounded_container_widget.dart'; import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; -class BodyMeasurementsScreen extends StatelessWidget { - BodyMeasurementsScreen(); +import '../../../../lookups/patient_lookup.dart'; +import '../../../../models/patient/vital_sign_res_model.dart'; +import '../../../../providers/patients_provider.dart'; +import '../../../../screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart'; +import '../../../../widgets/shared/app_scaffold_widget.dart'; + +class VitalSignItemDetailsScreen extends StatelessWidget { + VitalSignItemDetailsScreen(); // ; PatientsProvider patientsProv; List vitalList = []; @@ -164,17 +163,4 @@ class BodyMeasurementsScreen extends StatelessWidget { } } -class LinearSales { - final int year; - final int sales; - - LinearSales(this.year, this.sales); -} -/// Sample time series data type. -class TimeSeriesSales { - final DateTime time; - final int sales; - - TimeSeriesSales(this.time, this.sales); -} diff --git a/lib/screens/patients/profile/vital_sign/vital_ding_chart_and_detials.dart b/lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart similarity index 100% rename from lib/screens/patients/profile/vital_sign/vital_ding_chart_and_detials.dart rename to lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart diff --git a/lib/widgets/shared/charts/app_time_series_chart.dart b/lib/widgets/shared/charts/app_time_series_chart.dart index d22fb951..f581e1e7 100644 --- a/lib/widgets/shared/charts/app_time_series_chart.dart +++ b/lib/widgets/shared/charts/app_time_series_chart.dart @@ -1,10 +1,10 @@ import 'package:charts_flutter/flutter.dart' as charts; -import 'package:doctor_app_flutter/config/size_config.dart'; -import 'package:doctor_app_flutter/models/patient/vital_sign_res_model.dart'; -import 'package:doctor_app_flutter/screens/patients/profile/vital_sign/body_measurements_screen.dart'; -import 'package:doctor_app_flutter/widgets/shared/rounded_container_widget.dart'; import 'package:flutter/material.dart'; +import '../../../config/size_config.dart'; +import '../../../models/patient/vital_sign_res_model.dart'; +import '../../../widgets/shared/rounded_container_widget.dart'; + class AppTimeSeriesChart extends StatelessWidget { AppTimeSeriesChart( {Key key, @@ -91,3 +91,9 @@ class AppTimeSeriesChart extends StatelessWidget { ]; } } +class TimeSeriesSales { + final DateTime time; + final int sales; + + TimeSeriesSales(this.time, this.sales); +} \ No newline at end of file From c792aa1fc760dec87d85a498529871fafa8f1fb2 Mon Sep 17 00:00:00 2001 From: Amjad Amireh Date: Wed, 3 Jun 2020 13:14:51 +0300 Subject: [PATCH 3/8] Change design patiant profile --- lib/config/config.dart | 4 +- lib/providers/patients_provider.dart | 3 +- lib/providers/referred_patient_provider.dart | 28 +--- .../doctor/my_referred_patient_widget.dart | 145 ++++++------------ lib/widgets/shared/Text.dart | 2 +- .../shared/card_with_bgNew_widget.dart | 14 +- 6 files changed, 72 insertions(+), 124 deletions(-) diff --git a/lib/config/config.dart b/lib/config/config.dart index 6f094704..f4494a91 100644 --- a/lib/config/config.dart +++ b/lib/config/config.dart @@ -2,8 +2,8 @@ const MAX_SMALL_SCREEN = 660; const ONLY_NUMBERS = "[0-9]"; const ONLY_LETTERS = "[a-zA-Z]"; const ONLY_DATE = "[0-9/]"; -//const BASE_URL = 'https://hmgwebservices.com/Services/'; -const BASE_URL = 'https://uat.hmgwebservices.com/Services/'; +const BASE_URL = 'https://hmgwebservices.com/Services/'; +//const BASE_URL = 'https://uat.hmgwebservices.com/Services/'; const PHARMACY_ITEMS_URL = "Lists.svc/REST/GetPharmcyItems_Region"; const PHARMACY_LIST_URL = "Patients.svc/REST/GetPharmcyList"; const PATIENT_PROGRESS_NOTE_URL = "DoctorApplication.svc/REST/GetProgressNoteForInPatient"; diff --git a/lib/providers/patients_provider.dart b/lib/providers/patients_provider.dart index 8b84420a..be972ea2 100644 --- a/lib/providers/patients_provider.dart +++ b/lib/providers/patients_provider.dart @@ -25,7 +25,8 @@ import '../util/helpers.dart'; Helpers helpers = Helpers(); -class PatientsProvider with ChangeNotifier { +class PatientsProvider with ChangeNotifier +{ bool isLoading = false; bool isError = false; String error = ''; diff --git a/lib/providers/referred_patient_provider.dart b/lib/providers/referred_patient_provider.dart index 6dfd5e88..dbda8c05 100644 --- a/lib/providers/referred_patient_provider.dart +++ b/lib/providers/referred_patient_provider.dart @@ -1,11 +1,10 @@ import 'package:doctor_app_flutter/client/base_app_client.dart'; -//import 'package:doctor_app_flutter/models/my_referral_patient_model.dart'; import 'package:doctor_app_flutter/models/my_referred_patient_model.dart'; -//import 'package:doctor_app_flutter/models/my_referred_patient_model.dart'; -//import 'package:doctor_app_flutter/models/request_add_referred_doctor_remarks.dart'; import 'package:doctor_app_flutter/models/request_my_referral_patient_model.dart'; import 'package:doctor_app_flutter/models/verify_referral_doctor_remarks.dart'; + import 'package:flutter/cupertino.dart'; +import '../util/helpers.dart'; class MyReferredPatientProvider with ChangeNotifier { @@ -14,9 +13,8 @@ class MyReferredPatientProvider with ChangeNotifier { bool isLoading = true; bool isError = false; String error = ''; - + Helpers helpers = Helpers(); RequestMyReferralPatientModel _requestMyReferralPatient = RequestMyReferralPatientModel(); - // RequestAddReferredDoctorRemarks _requestAddReferredDoctorRemarks = RequestAddReferredDoctorRemarks(); VerifyReferralDoctorRemarks _verifyreferraldoctorremarks = VerifyReferralDoctorRemarks(); MyReferredPatientProvider() { getMyReferralPatient(); @@ -49,16 +47,13 @@ class MyReferredPatientProvider with ChangeNotifier { } } - // Future replay( - // String referredDoctorRemarks, MyReferredPatientModel model) async { - Future replay( + + Future verify( MyReferredPatientModel model) async { try { - _verifyreferraldoctorremarks.patientID=model.projectId; _verifyreferraldoctorremarks.admissionNo =model.admissionNo; _verifyreferraldoctorremarks.lineItemNo = model.lineItemNo; - _verifyreferraldoctorremarks.referredDoctorRemarks=model.referredDoctorRemarks; _verifyreferraldoctorremarks.referringDoctor=model.referringDoctor; _verifyreferraldoctorremarks.firstName=model.firstName; @@ -67,15 +62,6 @@ class MyReferredPatientProvider with ChangeNotifier { _verifyreferraldoctorremarks.patientMobileNumber=model.mobileNumber; _verifyreferraldoctorremarks.patientIdentificationID=model.patientIdentificationNo; - - - - - - - - - await BaseAppClient.post( 'DoctorApplication.svc/REST/GtMyReferredPatient', body: _verifyreferraldoctorremarks.toJson(),//_requestAddReferredDoctorRemarks.toJson(), @@ -86,11 +72,11 @@ class MyReferredPatientProvider with ChangeNotifier { notifyListeners(); }, onFailure: (String error, int statusCode) { - throw (error); + helpers.showErrorToast(error); }, ); } catch (error) { - throw error; + helpers.showErrorToast(error); } } } diff --git a/lib/widgets/doctor/my_referred_patient_widget.dart b/lib/widgets/doctor/my_referred_patient_widget.dart index f1aeb03a..f55a191b 100644 --- a/lib/widgets/doctor/my_referred_patient_widget.dart +++ b/lib/widgets/doctor/my_referred_patient_widget.dart @@ -1,9 +1,7 @@ - import 'package:doctor_app_flutter/models/my_referral_patient_model.dart'; import 'package:doctor_app_flutter/models/my_referred_patient_model.dart'; import 'package:flutter/material.dart'; - import 'package:doctor_app_flutter/config/size_config.dart'; import 'package:doctor_app_flutter/providers/referred_patient_provider.dart'; @@ -18,35 +16,24 @@ import 'package:flutter/cupertino.dart'; import 'package:provider/provider.dart'; - - class MyReferredPatientWidget extends StatefulWidget { + final MyReferredPatientModel myReferredPatientModel; -final MyReferredPatientModel myReferredPatientModel; + MyReferredPatientWidget({Key key, this.myReferredPatientModel}); - MyReferredPatientWidget({Key key, this.myReferredPatientModel}); - @override - _MyReferredPatientWidgetState createState() => _MyReferredPatientWidgetState(); - - - + _MyReferredPatientWidgetState createState() => + _MyReferredPatientWidgetState(); } class _MyReferredPatientWidgetState extends State { - bool _showDetails = false; bool _isLoading = false; - final _formKey = GlobalKey(); - String error; TextEditingController answerController; @override void initState() { - - super.initState(); - } @override @@ -58,7 +45,6 @@ class _MyReferredPatientWidgetState extends State { children: [ Row( mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ AppText( '${widget.myReferredPatientModel.firstName} ${widget.myReferredPatientModel.lastName}', @@ -86,43 +72,48 @@ class _MyReferredPatientWidgetState extends State { Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ - Divider(color: Colors.grey), - - // VerticalDivider(color: Colors.black, - // thickness: 2, width: 20, - // indent: 200, - // endIndent: 200,), + Divider(color: Colors.grey), + + // VerticalDivider(color: Colors.black, + // thickness: 2, width: 20, + // indent: 200, + // endIndent: 200,), Row( children: [ Expanded( child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - AppText( - 'File No', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, - ), - AppText( - '${widget.myReferredPatientModel.patientId}', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], - ), - + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + AppText( + 'File No', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + AppText( + '${widget.myReferredPatientModel.patientId}', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.w300, + ) + ], + ), ), Container( - height: SizeConfig.realScreenWidth * .1,//0.1, + height: + SizeConfig.realScreenWidth * .1, //0.1, width: 0.8, color: Colors.grey, margin: EdgeInsets.only(left: 15, right: 15), ), +// VerticalDivider(color:Colors.black,thickness: 1, width: 2, +// indent: 1, +// endIndent: 2,), Expanded( child: Column( - crossAxisAlignment: CrossAxisAlignment.start, + crossAxisAlignment: + CrossAxisAlignment.start, children: [ AppText( 'Referral Doctor', @@ -133,10 +124,9 @@ class _MyReferredPatientWidgetState extends State { Texts( widget.myReferredPatientModel .referralDoctorName, - maxLength: 80, - readMore: true, + maxLength: 80, + readMore: true, ), - ], ), ), @@ -255,12 +245,12 @@ class _MyReferredPatientWidgetState extends State { fontWeight: FontWeight.bold, textAlign: TextAlign.start, ), - + SizedBox( height: 5, ), - - Texts( + + Texts( '${widget.myReferredPatientModel.referringDoctorRemarks}', style: "bodyText1", readMore: true, @@ -278,8 +268,8 @@ class _MyReferredPatientWidgetState extends State { SizedBox( height: 5, ), - - Texts( + + Texts( '${widget.myReferredPatientModel.referredDoctorRemarks}', style: "bodyText1", readMore: true, @@ -288,54 +278,19 @@ class _MyReferredPatientWidgetState extends State { SizedBox( height: 5, ), - - SizedBox(height: 10.0), - if (error != null && error.isNotEmpty) - Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(6.0), - color: Theme.of(context) - .errorColor - .withOpacity(0.06), - ), - padding: EdgeInsets.symmetric( - vertical: 8.0, horizontal: 12.0), - child: Row( - children: [ - Expanded( - child: Texts(error ?? "", - style: "bodyText1", - color: Theme.of(context) - .errorColor)), - ], - ), - ), - SizedBox(height: 10.0), - ], - ), + SizedBox(height: 10.0), Container( width: double.infinity, child: Button( onTap: () async { - final form = _formKey.currentState; - - try { - await Provider.of(context, listen: false).replay(widget.myReferredPatientModel); - - setState(() { - _isLoading = false; - }); - } catch (e) { - setState(() { - error = e.toString(); - _isLoading = false; - }); - } - + await Provider.of( + context, + listen: false) + .verify(widget.myReferredPatientModel); + setState(() { + _isLoading = false; + }); }, title: 'Verify', loading: _isLoading, @@ -351,4 +306,4 @@ class _MyReferredPatientWidgetState extends State { ), ); } -} \ No newline at end of file +} diff --git a/lib/widgets/shared/Text.dart b/lib/widgets/shared/Text.dart index 76402617..95b55127 100644 --- a/lib/widgets/shared/Text.dart +++ b/lib/widgets/shared/Text.dart @@ -226,7 +226,7 @@ class _TextsState extends State { }, child: Text(hidden ? "Read More" : "Read less", style: _getFontStyle().copyWith( - color: Hexcolor('#515b5d'), + color: Hexcolor('#FF0000'), fontWeight: FontWeight.w800, fontFamily: "WorkSans" ) diff --git a/lib/widgets/shared/card_with_bgNew_widget.dart b/lib/widgets/shared/card_with_bgNew_widget.dart index 20387615..130d1b84 100644 --- a/lib/widgets/shared/card_with_bgNew_widget.dart +++ b/lib/widgets/shared/card_with_bgNew_widget.dart @@ -21,6 +21,7 @@ class CardWithBgWidgetNew extends StatelessWidget { @override Widget build(BuildContext context) { return Container( + //margin: EdgeInsets.symmetric(vertical: 10.0), margin: EdgeInsets.symmetric(vertical: 10.0), width: double.infinity, decoration: BoxDecoration( @@ -33,10 +34,15 @@ class CardWithBgWidgetNew extends StatelessWidget { color: Hexcolor('#FFFFFF'), child: Stack( children: [ - Container( - padding: EdgeInsets.all(10.0), - margin: EdgeInsets.only(left: 10), - child: widget) + Center( + child: Container( + padding:EdgeInsets.fromLTRB(0, 10,0, 10), //EdgeInsets.all(10.0),//10 + // margin: EdgeInsets.only(left: 10), + child: Padding( + padding: const EdgeInsets.all(8.0), + child: widget, + )), + ) ], ), ), From 489ad9e729e23a8f2c66f5c469fc6c6d321867d4 Mon Sep 17 00:00:00 2001 From: Elham Rababah Date: Wed, 3 Jun 2020 15:16:25 +0300 Subject: [PATCH 4/8] improve code and add AppExpandableNotifier --- .../profile/insurance_approvals_screen.dart | 1 - .../profile/vital_sign/vital_sign_item.dart | 7 +++ .../vital_sign_item_details_screen.dart | 9 +++- .../vital_sing_chart_and_detials.dart | 38 ++++++++----- .../patients/vital_sign_details_wideget.dart | 7 ++- .../shared/app_expandable_notifier.dart | 53 +++++++++++++++++++ lib/widgets/shared/charts/app_line_chart.dart | 7 +++ .../shared/charts/app_time_series_chart.dart | 26 ++++++++- 8 files changed, 131 insertions(+), 17 deletions(-) create mode 100644 lib/widgets/shared/app_expandable_notifier.dart diff --git a/lib/screens/patients/profile/insurance_approvals_screen.dart b/lib/screens/patients/profile/insurance_approvals_screen.dart index e2d531c5..2015e106 100644 --- a/lib/screens/patients/profile/insurance_approvals_screen.dart +++ b/lib/screens/patients/profile/insurance_approvals_screen.dart @@ -1,6 +1,5 @@ import 'package:doctor_app_flutter/config/config.dart'; import 'package:doctor_app_flutter/models/patient/insurance_aprovals_request.dart'; -import 'package:doctor_app_flutter/widgets/shared/app_buttons_widget.dart'; import 'package:doctor_app_flutter/widgets/shared/errors/dr_app_embedded_error.dart'; import 'package:doctor_app_flutter/widgets/shared/rounded_container_widget.dart'; import 'package:flutter/material.dart'; diff --git a/lib/screens/patients/profile/vital_sign/vital_sign_item.dart b/lib/screens/patients/profile/vital_sign/vital_sign_item.dart index 702d7bac..9e25af85 100644 --- a/lib/screens/patients/profile/vital_sign/vital_sign_item.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sign_item.dart @@ -2,6 +2,13 @@ import 'package:flutter/material.dart'; import '../../../../config/size_config.dart'; import '../../../../widgets/shared/rounded_container_widget.dart'; +/* + *@author: Elham Rababah + *@Date:03/6/2020 + *@param: + *@return: + *@desc: VitalSignItem + */ class VitalSignItem extends StatelessWidget { const VitalSignItem( {Key key, diff --git a/lib/screens/patients/profile/vital_sign/vital_sign_item_details_screen.dart b/lib/screens/patients/profile/vital_sign/vital_sign_item_details_screen.dart index 8acfeaf0..55f636d2 100644 --- a/lib/screens/patients/profile/vital_sign/vital_sign_item_details_screen.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sign_item_details_screen.dart @@ -7,6 +7,14 @@ import '../../../../providers/patients_provider.dart'; import '../../../../screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart'; import '../../../../widgets/shared/app_scaffold_widget.dart'; + +/* + *@author: Elham Rababah + *@Date:03/6/2020 + *@param: + *@return: + *@desc: VitalSignItemDetailsScreen + */ class VitalSignItemDetailsScreen extends StatelessWidget { VitalSignItemDetailsScreen(); // ; @@ -145,7 +153,6 @@ class VitalSignItemDetailsScreen extends StatelessWidget { default: } - // generateData(); return AppScaffold( appBarTitle: pageTitle, body: ListView( diff --git a/lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart b/lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart index e01290c1..1bc5b55d 100644 --- a/lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart @@ -1,9 +1,21 @@ import 'package:doctor_app_flutter/models/patient/vital_sign_res_model.dart'; import 'package:doctor_app_flutter/widgets/patients/vital_sign_details_wideget.dart'; +import 'package:doctor_app_flutter/widgets/shared/Text.dart'; +import 'package:doctor_app_flutter/widgets/shared/app_expandable_notifier.dart'; import 'package:doctor_app_flutter/widgets/shared/charts/app_time_series_chart.dart'; +import 'package:doctor_app_flutter/widgets/shared/rounded_container_widget.dart'; +import 'package:expandable/expandable.dart'; import 'package:flutter/material.dart'; + +/* + *@author: Elham Rababah + *@Date:03/6/2020 + *@param: + *@return: + *@desc: VitalSingChartAndDetials + */ class VitalSingChartAndDetials extends StatelessWidget { - VitalSingChartAndDetials({ + VitalSingChartAndDetials({ Key key, @required this.vitalList, @required this.name, @@ -12,7 +24,7 @@ class VitalSingChartAndDetials extends StatelessWidget { @required this.title2, }) : super(key: key); - final List vitalList ; + final List vitalList; final String name; final String viewKey; final String title1; @@ -22,16 +34,18 @@ class VitalSingChartAndDetials extends StatelessWidget { Widget build(BuildContext context) { return Column( children: [ - AppTimeSeriesChart( - vitalList: vitalList, - chartName: name, - viewKey: viewKey, - ), - VitalSignDetailsWidget( - vitalList: vitalList.reversed.toList(), - title1: '${title1}', - title2: '${title2}', - viewKey: '${viewKey}', + AppExpandableNotifier( + headerWid: AppTimeSeriesChart( + vitalList: vitalList, + chartName: name, + viewKey: viewKey, + ), + bodyWid: VitalSignDetailsWidget( + vitalList: vitalList.reversed.toList(), + title1: '${title1}', + title2: '${title2}', + viewKey: '${viewKey}', + ), ), ], ); diff --git a/lib/widgets/patients/vital_sign_details_wideget.dart b/lib/widgets/patients/vital_sign_details_wideget.dart index 35e85699..7c91b499 100644 --- a/lib/widgets/patients/vital_sign_details_wideget.dart +++ b/lib/widgets/patients/vital_sign_details_wideget.dart @@ -11,7 +11,8 @@ class VitalSignDetailsWidget extends StatefulWidget { final String title2; final String viewKey; - VitalSignDetailsWidget({Key key, this.vitalList, this.title1, this.title2,this.viewKey}); + VitalSignDetailsWidget( + {Key key, this.vitalList, this.title1, this.title2, this.viewKey}); @override _VitalSignDetailsWidgetState createState() => _VitalSignDetailsWidgetState(); @@ -26,6 +27,10 @@ class _VitalSignDetailsWidgetState extends State { borderRadius: BorderRadius.only( topLeft: Radius.circular(10.0), ), + border: Border.all( + color: Colors.grey, + width: 0.5 + ), ), margin: EdgeInsets.all(20), child: Container( diff --git a/lib/widgets/shared/app_expandable_notifier.dart b/lib/widgets/shared/app_expandable_notifier.dart new file mode 100644 index 00000000..ca3edd09 --- /dev/null +++ b/lib/widgets/shared/app_expandable_notifier.dart @@ -0,0 +1,53 @@ +import 'package:expandable/expandable.dart'; +import 'package:flutter/material.dart'; + +class AppExpandableNotifier extends StatelessWidget { + final Widget headerWid; + final Widget bodyWid; + + AppExpandableNotifier({this.headerWid, this.bodyWid}); + @override + Widget build(BuildContext context) { + return ExpandableNotifier( + child: Padding( + padding: const EdgeInsets.all(10), + child: Card( + clipBehavior: Clip.antiAlias, + child: Column( + children: [ + SizedBox( + child: headerWid, + ), + ScrollOnExpand( + scrollOnExpand: true, + scrollOnCollapse: false, + child: ExpandablePanel( + theme: const ExpandableThemeData( + headerAlignment: ExpandablePanelHeaderAlignment.center, + tapBodyToCollapse: true, + ), + header: Padding( + padding: EdgeInsets.all(10), + child: Text( + "See Graph Details", + )), + collapsed: Text(''), + expanded: bodyWid, + builder: (_, collapsed, expanded) { + return Padding( + padding: EdgeInsets.only(left: 10, right: 10, bottom: 10), + child: Expandable( + collapsed: collapsed, + expanded: expanded, + theme: const ExpandableThemeData(crossFadePoint: 0), + ), + ); + }, + ), + ), + ], + ), + ), + )); + } +} diff --git a/lib/widgets/shared/charts/app_line_chart.dart b/lib/widgets/shared/charts/app_line_chart.dart index 554eafa1..35320962 100644 --- a/lib/widgets/shared/charts/app_line_chart.dart +++ b/lib/widgets/shared/charts/app_line_chart.dart @@ -1,6 +1,13 @@ import 'package:flutter/material.dart'; import 'package:charts_flutter/flutter.dart' as charts; +/* + *@author: Elham Rababah + *@Date:03/6/2020 + *@param: + *@return: + *@desc: AppLineChart + */ class AppLineChart extends StatelessWidget { const AppLineChart({ Key key, diff --git a/lib/widgets/shared/charts/app_time_series_chart.dart b/lib/widgets/shared/charts/app_time_series_chart.dart index f581e1e7..1ffb1afb 100644 --- a/lib/widgets/shared/charts/app_time_series_chart.dart +++ b/lib/widgets/shared/charts/app_time_series_chart.dart @@ -5,8 +5,15 @@ import '../../../config/size_config.dart'; import '../../../models/patient/vital_sign_res_model.dart'; import '../../../widgets/shared/rounded_container_widget.dart'; +/* + *@author: Elham Rababah + *@Date:03/6/2020 + *@param: + *@return: + *@desc: AppTimeSeriesChart + */ class AppTimeSeriesChart extends StatelessWidget { - AppTimeSeriesChart( + AppTimeSeriesChart( {Key key, @required this.vitalList, @required this.viewKey, @@ -66,6 +73,13 @@ class AppTimeSeriesChart extends StatelessWidget { ); } + /* + *@author: Elham Rababah + *@Date:03/6/2020 + *@param: + *@return: + *@desc: generateData + */ generateData() { final List data = []; if (vitalList.length > 0) { @@ -91,9 +105,17 @@ class AppTimeSeriesChart extends StatelessWidget { ]; } } + +/* + *@author: Elham Rababah + *@Date:03/6/2020 + *@param: + *@return: + *@desc: TimeSeriesSales + */ class TimeSeriesSales { final DateTime time; final int sales; TimeSeriesSales(this.time, this.sales); -} \ No newline at end of file +} From 9b5658c00e1d9ca74950655b346a9bf07d2cf2c2 Mon Sep 17 00:00:00 2001 From: Mohammad ALjammal Date: Wed, 3 Jun 2020 15:21:42 +0300 Subject: [PATCH 5/8] change design My Referral and My Referral Patient --- lib/providers/referral_patient_provider.dart | 3 + lib/providers/referred_patient_provider.dart | 6 +- .../doctor/my_referral_patient_screen.dart | 2 +- .../doctor/my_referred_patient_screen.dart | 2 +- lib/util/dr_app_toast_msg.dart | 4 +- lib/util/helpers.dart | 3 +- lib/widgets/auth/known_user_login.dart | 7 +- lib/widgets/auth/verfiy_account.dart | 3 +- .../doctor/my_referral_patient_widget.dart | 420 +++++++++--------- .../doctor/my_referred_patient_widget.dart | 359 ++++++++------- 10 files changed, 412 insertions(+), 397 deletions(-) diff --git a/lib/providers/referral_patient_provider.dart b/lib/providers/referral_patient_provider.dart index 782bced7..84e27e98 100644 --- a/lib/providers/referral_patient_provider.dart +++ b/lib/providers/referral_patient_provider.dart @@ -2,6 +2,7 @@ import 'package:doctor_app_flutter/client/base_app_client.dart'; import 'package:doctor_app_flutter/models/my_referral_patient_model.dart'; import 'package:doctor_app_flutter/models/request_add_referred_doctor_remarks.dart'; import 'package:doctor_app_flutter/models/request_my_referral_patient_model.dart'; +import 'package:doctor_app_flutter/util/helpers.dart'; import 'package:flutter/cupertino.dart'; @@ -11,6 +12,8 @@ class MyReferralPatientProvider with ChangeNotifier { bool isLoading = true; bool isError = false; String error = ''; + Helpers helpers = Helpers(); + RequestMyReferralPatientModel _requestMyReferralPatient = RequestMyReferralPatientModel(); RequestAddReferredDoctorRemarks _requestAddReferredDoctorRemarks = RequestAddReferredDoctorRemarks(); diff --git a/lib/providers/referred_patient_provider.dart b/lib/providers/referred_patient_provider.dart index dbda8c05..9234da69 100644 --- a/lib/providers/referred_patient_provider.dart +++ b/lib/providers/referred_patient_provider.dart @@ -64,7 +64,7 @@ class MyReferredPatientProvider with ChangeNotifier { await BaseAppClient.post( 'DoctorApplication.svc/REST/GtMyReferredPatient', - body: _verifyreferraldoctorremarks.toJson(),//_requestAddReferredDoctorRemarks.toJson(), + body: _verifyreferraldoctorremarks.toJson(), onSuccess: (dynamic body, int statusCode) { listMyReferredPatientModel[ @@ -72,11 +72,11 @@ class MyReferredPatientProvider with ChangeNotifier { notifyListeners(); }, onFailure: (String error, int statusCode) { - helpers.showErrorToast(error); + throw(error); }, ); } catch (error) { - helpers.showErrorToast(error); + throw(error); } } } diff --git a/lib/screens/doctor/my_referral_patient_screen.dart b/lib/screens/doctor/my_referral_patient_screen.dart index e2e10e82..4c95663a 100644 --- a/lib/screens/doctor/my_referral_patient_screen.dart +++ b/lib/screens/doctor/my_referral_patient_screen.dart @@ -19,7 +19,7 @@ class MyReferralPatient extends StatelessWidget { return AppScaffold( showBottomBar: false, showAppDrawer: false, - appBarTitle: TranslationBase.of(context).mySchedule, + appBarTitle: 'My Referral Patient', body: referralPatientProvider.isLoading ? DrAppCircularProgressIndeicator() : referralPatientProvider.isError diff --git a/lib/screens/doctor/my_referred_patient_screen.dart b/lib/screens/doctor/my_referred_patient_screen.dart index dc50d12e..bfed1ef3 100644 --- a/lib/screens/doctor/my_referred_patient_screen.dart +++ b/lib/screens/doctor/my_referred_patient_screen.dart @@ -20,7 +20,7 @@ class MyReferredPatient extends StatelessWidget { return AppScaffold( showBottomBar: false, showAppDrawer: false, - appBarTitle: TranslationBase.of(context).mySchedule, + appBarTitle: 'My Referred Patient', body: referredPatientProvider.isLoading ? DrAppCircularProgressIndeicator() : referredPatientProvider.isError diff --git a/lib/util/dr_app_toast_msg.dart b/lib/util/dr_app_toast_msg.dart index 6fcea99a..fd1baa01 100644 --- a/lib/util/dr_app_toast_msg.dart +++ b/lib/util/dr_app_toast_msg.dart @@ -8,7 +8,7 @@ import 'package:flutter_flexible_toast/flutter_flexible_toast.dart'; ); } - void showSuccesToast(msg) { + static void showSuccesToast(msg) { FlutterFlexibleToast.showToast( message: msg, toastLength: Toast.LENGTH_SHORT, @@ -20,7 +20,7 @@ import 'package:flutter_flexible_toast/flutter_flexible_toast.dart'; } - void showErrorToast(msg) { + static void showErrorToast(msg) { FlutterFlexibleToast.showToast( message: msg, toastLength: Toast.LENGTH_SHORT, diff --git a/lib/util/helpers.dart b/lib/util/helpers.dart index 156457ff..e05f0d74 100644 --- a/lib/util/helpers.dart +++ b/lib/util/helpers.dart @@ -7,7 +7,6 @@ import '../util/dr_app_toast_msg.dart'; import 'package:connectivity/connectivity.dart'; -DrAppToastMsg toastMsg = DrAppToastMsg(); /* *@author: Elham Rababah @@ -126,7 +125,7 @@ class Helpers { localMsg = msg.toString(); } - toastMsg.showErrorToast(localMsg); + DrAppToastMsg.showErrorToast(localMsg); } /* diff --git a/lib/widgets/auth/known_user_login.dart b/lib/widgets/auth/known_user_login.dart index 9fcbd105..cda3a0e1 100644 --- a/lib/widgets/auth/known_user_login.dart +++ b/lib/widgets/auth/known_user_login.dart @@ -14,7 +14,6 @@ import '../../util/dr_app_toast_msg.dart'; import '../../widgets/shared/dr_app_circular_progress_Indeicator.dart'; DrAppSharedPreferances sharedPref = new DrAppSharedPreferances(); -DrAppToastMsg toastMsg = DrAppToastMsg(); class KnownUserLogin extends StatefulWidget { @override @@ -80,14 +79,14 @@ class _KnownUserLoginState extends State { 2; //res['SELECTDeviceIMEIbyIMEI_List'][0]['LogInType']; }).catchError((err) { print('${err}'); - toastMsg.showErrorToast(err); + DrAppToastMsg.showErrorToast(err); }); switch (snapshot.connectionState) { case ConnectionState.waiting: return DrAppCircularProgressIndeicator(); default: if (snapshot.hasError) { - toastMsg.showErrorToast('Error: ${snapshot.error}'); + DrAppToastMsg.showErrorToast('Error: ${snapshot.error}'); return Text('Error: ${snapshot.error}'); } else { return Column( @@ -323,6 +322,6 @@ class _KnownUserLoginState extends State { } showErorrMsg(localMsg) { - toastMsg.showErrorToast(localMsg); + DrAppToastMsg.showErrorToast(localMsg); } } diff --git a/lib/widgets/auth/verfiy_account.dart b/lib/widgets/auth/verfiy_account.dart index 963b26bf..7bf1944f 100644 --- a/lib/widgets/auth/verfiy_account.dart +++ b/lib/widgets/auth/verfiy_account.dart @@ -15,7 +15,6 @@ import '../../util/helpers.dart'; import '../../widgets/shared/dr_app_circular_progress_Indeicator.dart'; DrAppSharedPreferances sharedPref = new DrAppSharedPreferances(); -DrAppToastMsg toastMsg = DrAppToastMsg(); Helpers helpers = Helpers(); class VerifyAccount extends StatefulWidget { @@ -63,7 +62,7 @@ class _VerifyAccountState extends State { return DrAppCircularProgressIndeicator(); default: if (snapshot.hasError) { - toastMsg.showErrorToast('Error: ${snapshot.error}'); + DrAppToastMsg.showErrorToast('Error: ${snapshot.error}'); return Text('Error: ${snapshot.error}'); } else { return Form( diff --git a/lib/widgets/doctor/my_referral_patient_widget.dart b/lib/widgets/doctor/my_referral_patient_widget.dart index 433b9593..a2eb5f1d 100644 --- a/lib/widgets/doctor/my_referral_patient_widget.dart +++ b/lib/widgets/doctor/my_referral_patient_widget.dart @@ -1,6 +1,7 @@ import 'package:doctor_app_flutter/config/size_config.dart'; import 'package:doctor_app_flutter/models/my_referral_patient_model.dart'; import 'package:doctor_app_flutter/providers/referral_patient_provider.dart'; +import 'package:doctor_app_flutter/util/dr_app_toast_msg.dart'; import 'package:doctor_app_flutter/util/helpers.dart'; import 'package:doctor_app_flutter/widgets/shared/Text.dart'; import 'package:doctor_app_flutter/widgets/shared/TextFields.dart'; @@ -42,7 +43,7 @@ class _MyReferralPatientWidgetState extends State { crossAxisAlignment: CrossAxisAlignment.start, children: [ Row( - mainAxisAlignment: MainAxisAlignment.spaceAround, + mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ AppText( '${widget.myReferralPatientModel.firstName} ${widget.myReferralPatientModel.lastName}', @@ -67,265 +68,252 @@ class _MyReferralPatientWidgetState extends State { child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ - Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Divider(color: Colors.grey), - Row( - children: [ + SizedBox(height: 5,), + Divider(color: Color(0xFF000000),height: 0.5,), + Table( + border: TableBorder.symmetric(inside: BorderSide(width: 0.5),), + children: [ + TableRow( + children: [ Expanded( - child: Column( + child: Container( + margin: EdgeInsets.all(2.5), + padding: EdgeInsets.all(5), + child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ AppText( 'File No', fontSize: - 1.7 * SizeConfig.textMultiplier, + 1.7 * SizeConfig.textMultiplier, fontWeight: FontWeight.bold, ), AppText( '${widget.myReferralPatientModel.referringDoctor}', fontSize: - 1.7 * SizeConfig.textMultiplier, + 1.7 * SizeConfig.textMultiplier, fontWeight: FontWeight.w300, ) ], ), + ), ), - Container( - height: SizeConfig.realScreenWidth * 0.1, - width: 0.8, - color: Colors.grey, - margin: EdgeInsets.only(left: 15, right: 15), - ), Expanded( - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - AppText( - 'Referring Doctor', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, - ), - AppText( - widget.myReferralPatientModel - .referringClinicDescription, - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], + child: Container( + margin: EdgeInsets.only(left: 4,top: 2.5,right: 2.5,bottom: 2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + AppText( + 'Referring Doctor', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + AppText( + widget.myReferralPatientModel + .referringClinicDescription, + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.w300, + ) + ], + ), ), - ), - ], + ) + ] ), - - Divider(color: Colors.grey), - Row( - children: [ - Expanded( - child: Column( - crossAxisAlignment: + TableRow( + children: [ + Expanded( + child: Container( + margin: EdgeInsets.all(2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, - children: [ - AppText( - 'Referring Clinic', - fontSize: + children: [ + AppText( + 'Referring Clinic', + fontSize: 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, - ), - AppText( - '${widget.myReferralPatientModel.referringClinicDescription}', - fontSize: + fontWeight: FontWeight.bold, + ), + AppText( + '${widget.myReferralPatientModel.referringClinicDescription}', + fontSize: 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], + fontWeight: FontWeight.w300, + ) + ], + ), + ), ), - ), - Container( - height: SizeConfig.realScreenWidth * 0.1, - width: 0.8, - color: Colors.grey, - margin: EdgeInsets.only(left: 15, right: 15), - ), - Expanded( - child: Column( - crossAxisAlignment: + Expanded( + child: Container( + margin: EdgeInsets.only(left: 4,top: 2.5,right: 2.5,bottom: 2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, - children: [ - AppText( - 'Frequency', - fontSize: + children: [ + AppText( + 'Frequency', + fontSize: 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, - ), - AppText( - widget.myReferralPatientModel - .frequencyDescription, - fontSize: + fontWeight: FontWeight.bold, + ), + AppText( + widget.myReferralPatientModel + .frequencyDescription, + fontSize: 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], - ), - ), - ], + fontWeight: FontWeight.w300, + ) + ], + ), + ), + ) + ] ), - Divider(color: Colors.grey), - Row( - children: [ + TableRow( + children: [ Expanded( - child: Column( - crossAxisAlignment: - CrossAxisAlignment.start, - children: [ - AppText( - 'Priority', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, - ), - AppText( - '${widget.myReferralPatientModel.priorityDescription}', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], + child: Container( + margin: EdgeInsets.all(2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + AppText( + 'Priority', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + AppText( + '${widget.myReferralPatientModel.priorityDescription}', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.w300, + ) + ], + ), ), ), - Container( - height: SizeConfig.realScreenWidth * 0.1, - width: 0.8, - color: Colors.grey, - margin: EdgeInsets.only(left: 15, right: 15), - ), Expanded( - child: Column( - crossAxisAlignment: - CrossAxisAlignment.start, - children: [ - AppText( - 'Max Response Time', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, - ), - AppText( - Helpers.getDateFormatted(widget - .myReferralPatientModel - .mAXResponseTime), - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], + child: Container( + margin: EdgeInsets.only(left: 4,top: 2.5,right: 2.5,bottom: 2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + AppText( + 'Max Response Time', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + AppText( + Helpers.getDateFormatted(widget + .myReferralPatientModel + .mAXResponseTime), + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.w300, + ) + ], + ), ), - ), + ) ], ), - Divider(color: Colors.grey), + + ], + ), + Divider(color: Color(0xFF000000),height: 0.5,), + SizedBox( + height: 5, + ), + Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ AppText( 'Clinic Details and Remarks', fontSize: 1.7 * SizeConfig.textMultiplier, fontWeight: FontWeight.bold, - textAlign: TextAlign.start, - ), - SizedBox( - height: 5, - ), + textAlign: TextAlign.start,), Texts( - '73 years old female known case of HTN and dm on regular medication one day prior the patient had rt sided weakness suddenly and reduced level of conscoiusness no vomting no headache no bluriing of vision no other relevant symptoms.\r\nPMH:No history of similar condition no history of surgey or blood transfusions\r\nCT brain was done apparently effaced left insular cortex', + '${widget.myReferralPatientModel.referringDoctorRemarks}', style: "bodyText1", readMore: true, textAlign: TextAlign.start, - maxLength: 100), - SizedBox( - height: 5, - ), - AppText( - 'Answer/Suggestions', - fontSize: 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, - textAlign: TextAlign.start, - ), - SizedBox( - height: 5, - ), - Form( - key: _formKey, - child: TextFields( - maxLines: 2, - minLines: 2, - hintText: 'Answer the patient', - initialValue: widget.myReferralPatientModel.referredDoctorRemarks ?? '', - readOnly: _isLoading, - validator: (value) { - if (value.isEmpty) - return "please enter answer"; - else - return null; - }, - ), - ), - SizedBox(height: 10.0), - if (error != null && error.isNotEmpty) - Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - Container( - decoration: BoxDecoration( - borderRadius: BorderRadius.circular(6.0), - color: Theme.of(context) - .errorColor - .withOpacity(0.06), - ), - padding: EdgeInsets.symmetric( - vertical: 8.0, horizontal: 12.0), - child: Row( - children: [ - Expanded( - child: Texts(error ?? "", - style: "bodyText1", - color: Theme.of(context) - .errorColor)), - ], - ), - ), - SizedBox(height: 10.0), - ], - ), - SizedBox(height: 10.0), - Container( - width: double.infinity, - child: Button( - onTap: () async { - final form = _formKey.currentState; - if (form.validate()) { - setState(() { - _isLoading = true; - }); - try { - await Provider.of(context, listen: false).replay(answerController.text.toString(), widget.myReferralPatientModel); - setState(() { - _isLoading = false; - }); - } catch (e) { - setState(() { - error = e.toString(); - _isLoading = false; - }); - } - } - }, - title: 'Reply', - loading: _isLoading, - ), - ) + maxLength: 100) ], + ), + SizedBox( + height: 5, + ), + AppText( + 'Answer/Suggestions', + fontSize: 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + textAlign: TextAlign.start, + ), + SizedBox( + height: 5, + ), + Form( + key: _formKey, + child: TextFields( + maxLines: 2, + minLines: 2, + hintText: 'Answer the patient', + fontWeight: FontWeight.normal, + initialValue: widget.myReferralPatientModel.referredDoctorRemarks ?? '', + readOnly: _isLoading, + validator: (value) { + if (value.isEmpty) + return "please enter answer"; + else + return null; + }, + ), + ), + SizedBox(height: 10.0), + SizedBox(height: 10.0), + Container( + width: double.infinity, + margin: EdgeInsets.only(left: 10,right: 10), + child: Button( + onTap: () async { + final form = _formKey.currentState; + if (form.validate()) { + setState(() { + _isLoading = true; + }); + try { + await Provider.of(context, listen: false).replay(answerController.text.toString(), widget.myReferralPatientModel); + setState(() { + _isLoading = false; + }); + DrAppToastMsg.showSuccesToast('Reply Successfully'); + + } catch (e) { + setState(() { + _isLoading = false; + }); + DrAppToastMsg.showErrorToast(e); + } + } + }, + title: 'Reply', + loading: _isLoading, + ), ) ], ), diff --git a/lib/widgets/doctor/my_referred_patient_widget.dart b/lib/widgets/doctor/my_referred_patient_widget.dart index f55a191b..af5ea4f8 100644 --- a/lib/widgets/doctor/my_referred_patient_widget.dart +++ b/lib/widgets/doctor/my_referred_patient_widget.dart @@ -1,5 +1,6 @@ import 'package:doctor_app_flutter/models/my_referral_patient_model.dart'; import 'package:doctor_app_flutter/models/my_referred_patient_model.dart'; +import 'package:doctor_app_flutter/util/dr_app_toast_msg.dart'; import 'package:flutter/material.dart'; import 'package:doctor_app_flutter/config/size_config.dart'; @@ -72,184 +73,204 @@ class _MyReferredPatientWidgetState extends State { Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ - Divider(color: Colors.grey), - - // VerticalDivider(color: Colors.black, - // thickness: 2, width: 20, - // indent: 200, - // endIndent: 200,), - Row( - children: [ - Expanded( - child: Column( - crossAxisAlignment: - CrossAxisAlignment.start, - children: [ - AppText( - 'File No', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, + SizedBox( + height: 5, + ), + Divider( + color: Color(0xFF000000), + height: 0.5, + ), + Table( + border: TableBorder.symmetric( + inside: BorderSide(width: 0.5), + ), + children: [ + TableRow(children: [ + Expanded( + child: Container( + margin: EdgeInsets.all(2.5), + padding: EdgeInsets.all(5), + decoration: BoxDecoration(), + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + AppText( + 'File No', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + AppText( + '${widget.myReferredPatientModel.patientId}', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.w300, + ) + ], ), - AppText( - '${widget.myReferredPatientModel.patientId}', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], + ), ), - ), - Container( - height: - SizeConfig.realScreenWidth * .1, //0.1, - width: 0.8, - color: Colors.grey, - margin: EdgeInsets.only(left: 15, right: 15), - ), -// VerticalDivider(color:Colors.black,thickness: 1, width: 2, -// indent: 1, -// endIndent: 2,), - Expanded( - child: Column( - crossAxisAlignment: - CrossAxisAlignment.start, - children: [ - AppText( - 'Referral Doctor', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, + Expanded( + child: Container( + margin: EdgeInsets.only( + left: 4, + top: 2.5, + right: 2.5, + bottom: 2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + AppText( + 'Referral Doctor', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + Texts( + widget.myReferredPatientModel + .referralDoctorName, + maxLength: 80, + readMore: true, + ), + ], ), - Texts( - widget.myReferredPatientModel - .referralDoctorName, - maxLength: 80, - readMore: true, - ), - ], + ), ), - ), - ], - ), - - Divider(color: Colors.grey), - Row( - children: [ - Expanded( - child: Column( - crossAxisAlignment: - CrossAxisAlignment.start, - children: [ - AppText( - 'Referring Clinic', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, + ]), + TableRow( + children: [ + Expanded( + child: Container( + margin: EdgeInsets.all(2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + AppText( + 'Referring Clinic', + fontSize: 1.7 * + SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + AppText( + '${widget.myReferredPatientModel.referralClinicDescription}', + fontSize: 1.7 * + SizeConfig.textMultiplier, + fontWeight: FontWeight.w300, + ) + ], + ), ), - AppText( - '${widget.myReferredPatientModel.referralClinicDescription}', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], - ), - ), - Container( - height: SizeConfig.realScreenWidth * 0.1, - width: 0.8, - color: Colors.grey, - margin: EdgeInsets.only(left: 15, right: 15), - ), - Expanded( - child: Column( - crossAxisAlignment: - CrossAxisAlignment.start, - children: [ - AppText( - 'Frequency', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, + ), + Expanded( + child: Container( + margin: EdgeInsets.only( + left: 4, + top: 2.5, + right: 2.5, + bottom: 2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + AppText( + 'Frequency', + fontSize: 1.7 * + SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + AppText( + widget.myReferredPatientModel + .frequencyDescription, + fontSize: 1.7 * + SizeConfig.textMultiplier, + fontWeight: FontWeight.w300, + ) + ], + ), ), - AppText( - widget.myReferredPatientModel - .frequencyDescription, - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], - ), + ) + ], ), - ], - ), - Divider(color: Colors.grey), - Row( - children: [ - Expanded( - child: Column( - crossAxisAlignment: - CrossAxisAlignment.start, - children: [ - AppText( - 'Priority', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, + TableRow(children: [ + Expanded( + child: Container( + margin: EdgeInsets.all(2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + AppText( + 'Priority', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + AppText( + '${widget.myReferredPatientModel.priorityDescription}', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.w300, + ) + ], ), - AppText( - '${widget.myReferredPatientModel.priorityDescription}', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], + ), ), - ), - Container( - height: SizeConfig.realScreenWidth * 0.1, - width: 0.8, - color: Colors.grey, - margin: EdgeInsets.only(left: 15, right: 15), - ), - Expanded( - child: Column( - crossAxisAlignment: - CrossAxisAlignment.start, - children: [ - AppText( - 'Max Response Time', - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.bold, + Expanded( + child: Container( + margin: EdgeInsets.only( + left: 4, + top: 2.5, + right: 2.5, + bottom: 2.5), + padding: EdgeInsets.all(5), + child: Column( + crossAxisAlignment: + CrossAxisAlignment.start, + children: [ + AppText( + 'Max Response Time', + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.bold, + ), + AppText( + Helpers.getDateFormatted(widget + .myReferredPatientModel + .maxResponseTime), + fontSize: + 1.7 * SizeConfig.textMultiplier, + fontWeight: FontWeight.w300, + ) + ], ), - AppText( - Helpers.getDateFormatted(widget - .myReferredPatientModel - .maxResponseTime), - fontSize: - 1.7 * SizeConfig.textMultiplier, - fontWeight: FontWeight.w300, - ) - ], - ), - ), + ), + ) + ]) ], ), - Divider(color: Colors.grey), + Divider( + color: Color(0xFF000000), + height: 0.5, + ), + SizedBox( + height: 5, + ), AppText( 'Clinic Details and Remarks', fontSize: 1.7 * SizeConfig.textMultiplier, fontWeight: FontWeight.bold, textAlign: TextAlign.start, ), - SizedBox( height: 5, ), - Texts( '${widget.myReferredPatientModel.referringDoctorRemarks}', style: "bodyText1", @@ -268,7 +289,6 @@ class _MyReferredPatientWidgetState extends State { SizedBox( height: 5, ), - Texts( '${widget.myReferredPatientModel.referredDoctorRemarks}', style: "bodyText1", @@ -278,19 +298,26 @@ class _MyReferredPatientWidgetState extends State { SizedBox( height: 5, ), - SizedBox(height: 10.0), Container( width: double.infinity, child: Button( onTap: () async { - await Provider.of( - context, - listen: false) - .verify(widget.myReferredPatientModel); - setState(() { - _isLoading = false; - }); + try { + setState(() { + _isLoading = true; + }); + await Provider.of(context, listen: false).verify(widget.myReferredPatientModel); + setState(() { + _isLoading = false; + }); + DrAppToastMsg.showSuccesToast('Verify Successfully'); + } catch (e) { + setState(() { + _isLoading = false; + }); + DrAppToastMsg.showErrorToast(e); + } }, title: 'Verify', loading: _isLoading, From 55a4bfba83f1a3b690bfe0e63f0a17b08d532e79 Mon Sep 17 00:00:00 2001 From: Elham Rababah Date: Wed, 3 Jun 2020 15:31:34 +0300 Subject: [PATCH 6/8] hot fix --- .../profile/vital_sign/vital_sing_chart_and_detials.dart | 3 --- pubspec.yaml | 2 ++ 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart b/lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart index 1bc5b55d..1959ca52 100644 --- a/lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sing_chart_and_detials.dart @@ -1,10 +1,7 @@ import 'package:doctor_app_flutter/models/patient/vital_sign_res_model.dart'; import 'package:doctor_app_flutter/widgets/patients/vital_sign_details_wideget.dart'; -import 'package:doctor_app_flutter/widgets/shared/Text.dart'; import 'package:doctor_app_flutter/widgets/shared/app_expandable_notifier.dart'; import 'package:doctor_app_flutter/widgets/shared/charts/app_time_series_chart.dart'; -import 'package:doctor_app_flutter/widgets/shared/rounded_container_widget.dart'; -import 'package:expandable/expandable.dart'; import 'package:flutter/material.dart'; /* diff --git a/pubspec.yaml b/pubspec.yaml index 4336bacd..9ed6b4ef 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -37,6 +37,8 @@ dependencies: url_launcher: ^5.4.5 charts_flutter: ^0.9.0 eva_icons_flutter: ^2.0.0 + expandable: ^4.1.4 + # Qr code Scanner barcode_scan: ^3.0.1 From ec85a0ea18ff8f576232d9f5549f7a0d32581b3f Mon Sep 17 00:00:00 2001 From: Mohammad ALjammal Date: Wed, 3 Jun 2020 15:58:58 +0300 Subject: [PATCH 7/8] change design VitalSignDetailsWidget --- .../patients/vital_sign_details_wideget.dart | 153 +++++++++--------- pubspec.lock | 7 + 2 files changed, 80 insertions(+), 80 deletions(-) diff --git a/lib/widgets/patients/vital_sign_details_wideget.dart b/lib/widgets/patients/vital_sign_details_wideget.dart index 7c91b499..437b4085 100644 --- a/lib/widgets/patients/vital_sign_details_wideget.dart +++ b/lib/widgets/patients/vital_sign_details_wideget.dart @@ -26,11 +26,9 @@ class _VitalSignDetailsWidgetState extends State { color: Colors.transparent, borderRadius: BorderRadius.only( topLeft: Radius.circular(10.0), + topRight: Radius.circular(10.0) ), - border: Border.all( - color: Colors.grey, - width: 0.5 - ), + border: Border.all(color: Colors.grey, width: 1), ), margin: EdgeInsets.all(20), child: Container( @@ -38,86 +36,81 @@ class _VitalSignDetailsWidgetState extends State { child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ - Row( - children: [ - Expanded( - child: Container( - decoration: BoxDecoration( - color: Hexcolor('#515B5D'), - borderRadius: BorderRadius.only( - topLeft: Radius.circular(10.0), - ), - ), - child: Center( - child: Texts( - widget.title1, - color: Colors.white, - ), - ), - height: 60, - ), - ), - Expanded( - child: Container( - decoration: BoxDecoration( - color: Hexcolor('#515B5D'), - borderRadius: BorderRadius.only( - topRight: Radius.circular(10.0), - ), - ), - child: Center( - child: Texts(widget.title2, color: Colors.white), - ), - height: 60), - ), - ], - ), - Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: widget.vitalList.map((vital) { - return Column( - children: [ - Row( - children: [ - Expanded( - child: Container( - height: 50, - color: Colors.white, - child: Center( - child: Texts( - '${Helpers.getWeekDay(vital.vitalSignDate.weekday)}, ${vital.vitalSignDate.day} ${Helpers.getMonth(vital.vitalSignDate.month)}, ${vital.vitalSignDate.year} ', - textAlign: TextAlign.center, - ), - ), - ), - ), - SizedBox( - width: 2, - ), - Expanded( - child: Container( - height: 50, - color: Colors.white, - child: Center( - child: Texts( - '${vital.toJson()[widget.viewKey]}', - textAlign: TextAlign.center, - ), - ), - ), - ), - ], - ), - SizedBox( - height: 2, - ), - ], - ); - }).toList(), + Table( + border: TableBorder.symmetric( + inside: BorderSide(width: 2.0,color: Colors.grey[300]), + ), + children: fullData(), ), ], ), ), ); } + + List fullData(){ + List tableRow = []; + tableRow.add(TableRow(children: [ + Expanded( + child: Container( + decoration: BoxDecoration( + color: Hexcolor('#515B5D'), + borderRadius: BorderRadius.only( + topLeft: Radius.circular(10.0), + ), + ), + child: Center( + child: Texts( + widget.title1, + color: Colors.white, + ), + ), + height: 60, + ), + ), + Expanded( + child: Container( + decoration: BoxDecoration( + color: Hexcolor('#515B5D'), + borderRadius: BorderRadius.only( + topRight: Radius.circular(10.0), + ), + ), + child: Center( + child: Texts(widget.title2, color: Colors.white), + ), + height: 60), + ) + ])); + widget.vitalList.forEach((vital) { + tableRow.add(TableRow(children: [ + Expanded( + child: Container( + height: 50, + color: Colors.white, + child: Center( + child: Texts( + '${Helpers.getWeekDay(vital.vitalSignDate.weekday)}, ${vital.vitalSignDate.day} ${Helpers.getMonth(vital.vitalSignDate.month)}, ${vital.vitalSignDate.year} ', + textAlign: TextAlign.center, + ), + ), + ), + ), + Expanded( + child: Container( + height: 50, + color: Colors.white, + child: Center( + child: Texts( + '${vital.toJson()[widget.viewKey]}', + textAlign: TextAlign.center, + ), + ), + ), + ), + ])); + }); + return tableRow; + } + } diff --git a/pubspec.lock b/pubspec.lock index afe0aa60..20f3bbd9 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -239,6 +239,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.0.0" + expandable: + dependency: "direct main" + description: + name: expandable + url: "https://pub.dartlang.org" + source: hosted + version: "4.1.4" fixnum: dependency: transitive description: From 5d7937c08daf6773165ec11909e4a7a2eb69173b Mon Sep 17 00:00:00 2001 From: Mohammad ALjammal Date: Wed, 3 Jun 2020 17:28:31 +0300 Subject: [PATCH 8/8] add arrow back in PatientProfileScreen , PatientSearchScreen and PatientsScreen --- lib/screens/patients/patient_search_screen.dart | 2 ++ lib/screens/patients/patients_screen.dart | 10 ++++++---- .../patients/profile/patient_profile_screen.dart | 2 ++ 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/lib/screens/patients/patient_search_screen.dart b/lib/screens/patients/patient_search_screen.dart index d00aabdb..dfccc188 100644 --- a/lib/screens/patients/patient_search_screen.dart +++ b/lib/screens/patients/patient_search_screen.dart @@ -116,6 +116,8 @@ class _PatientSearchScreenState extends State { Widget build(BuildContext context) { return AppScaffold( appBarTitle: "SEARCH FOR PATIENT", + showBottomBar: false, + showAppDrawer: false, body: ListView( children: [ RoundedContainer( diff --git a/lib/screens/patients/patients_screen.dart b/lib/screens/patients/patients_screen.dart index bcdc4218..b5ec9b83 100644 --- a/lib/screens/patients/patients_screen.dart +++ b/lib/screens/patients/patients_screen.dart @@ -296,6 +296,8 @@ class _PatientsScreenState extends State { PatientsProvider patientsProv = Provider.of(context); return AppScaffold( + showBottomBar: false, + showAppDrawer: false, appBarTitle: patientTypetitle, body: _isLoading ? DrAppCircularProgressIndeicator() @@ -402,7 +404,7 @@ class _PatientsScreenState extends State { semanticsLabel: 'Female Logo') ], - + ), SizedBox( width: 10, @@ -441,7 +443,7 @@ class _PatientsScreenState extends State { backGroundcolor: Colors.white, ), - + // SizedBox( // height: 8, // ), @@ -591,7 +593,7 @@ class _PatientsScreenState extends State { child: Center( child: Text( item, - + style: TextStyle( fontSize: 12, color: _isActive @@ -613,7 +615,7 @@ class _PatientsScreenState extends State { setState(() { _activeLocation = _locations.indexOf(item); - + }); }), _isActive diff --git a/lib/screens/patients/profile/patient_profile_screen.dart b/lib/screens/patients/profile/patient_profile_screen.dart index 5241f18c..20954d38 100644 --- a/lib/screens/patients/profile/patient_profile_screen.dart +++ b/lib/screens/patients/profile/patient_profile_screen.dart @@ -10,6 +10,8 @@ class PatientProfileScreen extends StatelessWidget { Widget build(BuildContext context) { return AppScaffold( // child: child, + showBottomBar: false, + showAppDrawer: false, appBarTitle: 'Patient Profile', body: PatientProfileWidget(), );