diff --git a/lib/client/base_app_client.dart b/lib/client/base_app_client.dart index 07160811..6d0a5a66 100644 --- a/lib/client/base_app_client.dart +++ b/lib/client/base_app_client.dart @@ -349,8 +349,9 @@ class BaseAppClient { get({required String endPoint, required Function(dynamic response, int statusCode) onSuccess, required Function(String error, int statusCode) onFailure}) async { String token = await sharedPref.getString(TOKEN); String url = DOCTOR_ROTATION + endPoint + '&token=' + token; - + print(url); final response = await http.get(Uri.parse(url)); + final int statusCode = response.statusCode; if (statusCode < 200 || statusCode >= 400) { onFailure(Utils.generateContactAdminMsg(), statusCode); diff --git a/lib/screens/live_care/live_care_patient_screen.dart b/lib/screens/live_care/live_care_patient_screen.dart index a46121e0..c5e882d8 100644 --- a/lib/screens/live_care/live_care_patient_screen.dart +++ b/lib/screens/live_care/live_care_patient_screen.dart @@ -15,6 +15,9 @@ import 'package:doctor_app_flutter/widgets/shared/errors/error_message.dart'; import 'package:doctor_app_flutter/widgets/shared/text_fields/app_text_field_custom_serach.dart'; import 'package:flutter/material.dart'; +import '../../utils/translations_delegate_base_utils.dart'; +import '../../widgets/shared/errors/error_message.dart'; + class LiveCarePatientScreen extends StatefulWidget { @override _LiveCarePatientScreenState createState() => _LiveCarePatientScreenState(); diff --git a/lib/screens/patients/profile/profile_screen/profile_gird_for_search.dart b/lib/screens/patients/profile/profile_screen/profile_gird_for_search.dart index 3121d302..2ba0386e 100644 --- a/lib/screens/patients/profile/profile_screen/profile_gird_for_search.dart +++ b/lib/screens/patients/profile/profile_screen/profile_gird_for_search.dart @@ -167,7 +167,7 @@ class ProfileGridForSearch extends StatelessWidget { isInPatient: item.isInPatient, isDischargedPatient: item.isDischargedPatient, isDisable: item.isDisable, - onTap: item.onTap, + onTap:item.onTap, isLoading: item.isLoading, ); }).toList(), diff --git a/lib/screens/patients/profile/radiology/radiology_home_page.dart b/lib/screens/patients/profile/radiology/radiology_home_page.dart index 485ddcaf..20878cf4 100644 --- a/lib/screens/patients/profile/radiology/radiology_home_page.dart +++ b/lib/screens/patients/profile/radiology/radiology_home_page.dart @@ -115,7 +115,7 @@ class _RadiologyHomePageState extends State { //Colors.red[900] Color(0xff404545) color: model.radiologyList[index].isLiveCareAppodynamicment ?? false ? Colors.red[900] - : !model.radiologyList[index].isInOutPatient! + : model.radiologyList[index].isInOutPatient !=null && model.radiologyList[index].isInOutPatient==false ? Colors.black : Color(0xffa9a089), borderRadius: BorderRadius.only( @@ -128,9 +128,9 @@ class _RadiologyHomePageState extends State { quarterTurns: 3, child: Center( child: Text( - model.radiologyList[index].isLiveCareAppodynamicment! + model.radiologyList[index].isLiveCareAppodynamicment !=null && model.radiologyList[index].isLiveCareAppodynamicment==true ? TranslationBase.of(context).liveCare.toUpperCase() - : !model.radiologyList[index].isInOutPatient! + : model.radiologyList[index].isInOutPatient!=null && model.radiologyList[index].isInOutPatient==false ? TranslationBase.of(context).inPatientLabel.toUpperCase() : TranslationBase.of(context).outpatient.toUpperCase(), style: TextStyle(color: Colors.white), diff --git a/lib/screens/prescription/old_prescriptions_page.dart b/lib/screens/prescription/old_prescriptions_page.dart index 9d01fd2b..523f3549 100644 --- a/lib/screens/prescription/old_prescriptions_page.dart +++ b/lib/screens/prescription/old_prescriptions_page.dart @@ -101,8 +101,7 @@ class OldPrescriptionsPage extends StatelessWidget { ), ), ) - : Center( - child: FractionallySizedBox( + : FractionallySizedBox( widthFactor: 0.9, child: SingleChildScrollView( child: Column( @@ -182,7 +181,7 @@ class OldPrescriptionsPage extends StatelessWidget { ], ), ), - ), + ))); } } diff --git a/lib/widgets/shared/dialogs/master_key_dailog.dart b/lib/widgets/shared/dialogs/master_key_dailog.dart index 5d032c73..d5fd9ed2 100644 --- a/lib/widgets/shared/dialogs/master_key_dailog.dart +++ b/lib/widgets/shared/dialogs/master_key_dailog.dart @@ -25,7 +25,7 @@ class _MasterKeyDailogState extends State { @override void initState() { super.initState(); - widget.selectedValue = widget.selectedValue ?? widget.list[0]; + widget.selectedValue = widget.selectedValue ?? widget.list.first; } @override