diff --git a/lib/config/localized_values.dart b/lib/config/localized_values.dart index 66c2e58c..1dc0216e 100644 --- a/lib/config/localized_values.dart +++ b/lib/config/localized_values.dart @@ -504,4 +504,7 @@ const Map> localizedValues = { 'itemExist': {'en': "This item already exist", 'ar': "هذا العنصر موجود"}, 'selectAllergy': {'en': "Select Allergy", 'ar': "أختر الحساسية"}, 'selectSeverity': {'en': "Select Severity", 'ar': "أختر الدرجه"}, + 'medications': {'en': "Medications", 'ar':"الأدوية" }, + 'procedures': {'en': "Procedures", 'ar':"الإجراءات" }, + 'vitalSignEmptyMsg': {'en': "There is no vital signs for this patient", 'ar':"لا توجد علامات حيوية لهذا المريض" }, }; diff --git a/lib/core/service/patient-doctor-referral-service.dart b/lib/core/service/patient-doctor-referral-service.dart index a15ed05a..7eb8001b 100644 --- a/lib/core/service/patient-doctor-referral-service.dart +++ b/lib/core/service/patient-doctor-referral-service.dart @@ -7,6 +7,7 @@ import 'package:doctor_app_flutter/models/patient/get_clinic_by_project_id_reque import 'package:doctor_app_flutter/models/patient/get_doctor_by_clinic_id_request.dart'; import 'package:doctor_app_flutter/models/patient/my_referral/PendingReferral.dart'; import 'package:doctor_app_flutter/models/patient/my_referral/my_referred_patient_model.dart'; +import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; import 'package:doctor_app_flutter/models/patient/request_my_referral_patient_model.dart'; import 'base/lookup-service.dart'; @@ -188,7 +189,7 @@ class PatientReferralService extends LookupService { } Future makeReferral( - PatientArrivalEntity patientArrivalEntity, + PatiantInformtion patient, String isoStringDate, int projectID, int clinicID, @@ -203,8 +204,8 @@ class PatientReferralService extends LookupService { .add({"goalId": element.id, "remarks": element.remarks}); }); - body['PatientMRN'] = patientArrivalEntity.patientMRN; - body['AppointmentNo'] = patientArrivalEntity.appointmentNo; + body['PatientMRN'] = patient.patientMRN; + body['AppointmentNo'] = patient.appointmentNo; body['SetupID'] = setupID; body['appointmentDate'] = isoStringDate; body['SlotStart'] = isoStringDate; diff --git a/lib/core/service/patient-vital-signs-service.dart b/lib/core/service/patient-vital-signs-service.dart index d508fec6..31c8721d 100644 --- a/lib/core/service/patient-vital-signs-service.dart +++ b/lib/core/service/patient-vital-signs-service.dart @@ -1,6 +1,7 @@ import 'package:doctor_app_flutter/config/config.dart'; import 'package:doctor_app_flutter/core/service/base/base_service.dart'; import 'package:doctor_app_flutter/models/patient/PatientArrivalEntity.dart'; +import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; import 'package:doctor_app_flutter/models/patient/vital_sign/patient-vital-sign-data.dart'; import 'package:doctor_app_flutter/models/patient/vital_sign/vital_sign_res_model.dart'; @@ -46,18 +47,18 @@ class VitalSignsService extends BaseService{ ); } // Vit*/ - Future getPatientVitalSign(PatientArrivalEntity patientArrivalEntity) async { + Future getPatientVitalSign(PatiantInformtion patient) async { hasError = false; Map body = Map(); - body['PatientMRN'] = patientArrivalEntity.patientMRN; - body['AppointmentNo'] = patientArrivalEntity.appointmentNo; - body['EpisodeID'] = patientArrivalEntity.episodeNo; + body['PatientMRN'] = patient.patientMRN; + body['AppointmentNo'] = patient.appointmentNo; + body['EpisodeID'] = patient.episodeNo; await baseAppClient.post( GET_PATIENT_VITAL_SIGN_DATA, onSuccess: (dynamic response, int statusCode) { if(response['VitalSignsList'] != null){ - if(response['VitalSignsList']['entityList'] = null && (response['VitalSignsList']['entityList'] as List).length > 0){ + if(response['VitalSignsList']['entityList'] != null && (response['VitalSignsList']['entityList'] as List).length > 0){ patientVitalSigns = VitalSignData.fromJson(response['VitalSignsList']['entityList']['0']); } } diff --git a/lib/core/viewModel/patient-referral-viewmodel.dart b/lib/core/viewModel/patient-referral-viewmodel.dart index 9662a910..e5657883 100644 --- a/lib/core/viewModel/patient-referral-viewmodel.dart +++ b/lib/core/viewModel/patient-referral-viewmodel.dart @@ -7,6 +7,7 @@ import 'package:doctor_app_flutter/models/doctor/doctor_profile_model.dart'; import 'package:doctor_app_flutter/models/patient/PatientArrivalEntity.dart'; import 'package:doctor_app_flutter/models/patient/my_referral/PendingReferral.dart'; import 'package:doctor_app_flutter/models/patient/my_referral/my_referred_patient_model.dart'; +import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; import '../../locator.dart'; @@ -117,35 +118,14 @@ class PatientReferralViewModel extends BaseViewModel { setState(ViewState.Idle); } - Future getPatientArrivalList(String date) async { - setState(ViewState.Busy); - await _referralPatientService.getPatientArrivalList(date); - if (_referralPatientService.hasError) { - error = _referralPatientService.error; - setState(ViewState.ErrorLocal); - } else { - setState(ViewState.Idle); - } - } - - List getAppointmentsByPatientName(String patientName) { - List appointments = []; - patientArrivalList.forEach((element) { - if (element.patientName == patientName) { - appointments.add(element.toJson()); - } - }); - return appointments; - } - - Future makeReferral(PatientArrivalEntity patientArrivalEntity, + Future makeReferral(PatiantInformtion patient, String isoStringDate, int projectID, int clinicID, int doctorID, String remarks) async { setState(ViewState.Busy); - await _referralPatientService.makeReferral(patientArrivalEntity, isoStringDate, projectID, clinicID, doctorID, remarks); + await _referralPatientService.makeReferral(patient, isoStringDate, projectID, clinicID, doctorID, remarks); if (_referralPatientService.hasError) { error = _referralPatientService.error; setState(ViewState.Error); diff --git a/lib/core/viewModel/patient-vital-sign-viewmodel.dart b/lib/core/viewModel/patient-vital-sign-viewmodel.dart index e58ad089..f53def7b 100644 --- a/lib/core/viewModel/patient-vital-sign-viewmodel.dart +++ b/lib/core/viewModel/patient-vital-sign-viewmodel.dart @@ -16,17 +16,17 @@ class VitalSignsViewModel extends BaseViewModel { VitalSignData get patientVitalSigns => _vitalSignService.patientVitalSigns; - Future getPatientArrivalList(String date, PatiantInformtion patient, + /*Future getPatientArrivalList(String date, PatiantInformtion patient, {String fromDate}) async { // TODO when arrival list work un comment below lines - /* setState(ViewState.Busy); + *//* setState(ViewState.Busy); await _vitalSignService.getPatientArrivalList(date, fromDate: fromDate); if (_vitalSignService.hasError) { error = _vitalSignService.error; setState(ViewState.Error); } else { await getPatientVitalSign(patient); - }*/ + }*//* makeVitalSignDemoData(); } @@ -43,27 +43,18 @@ class VitalSignsViewModel extends BaseViewModel { // print("patient index: $index"); } return null; - } + }*/ Future getPatientVitalSign(PatiantInformtion patient) async { setState(ViewState.Busy); - PatientArrivalEntity patientArrivalEntity = - getPatientAppointmentEntity(patient); - if (patientArrivalEntity == null) { - _vitalSignService.hasError = true; - error = "There is no appointments for this patient"; - setState(ViewState.Error); - return; - } - await _vitalSignService.getPatientVitalSign(patientArrivalEntity); - // TODO remove (not) from below condition - if (!_vitalSignService.hasError) { + await _vitalSignService.getPatientVitalSign(patient); + if (_vitalSignService.hasError) { error = _vitalSignService.error; setState(ViewState.Error); } else { - if (patientVitalSigns == null) { - makeVitalSignDemoData(); - } + // if (patientVitalSigns == null) { + // makeVitalSignDemoData(); + // } setState(ViewState.Idle); } } diff --git a/lib/routes.dart b/lib/routes.dart index 962df032..e57b56a7 100644 --- a/lib/routes.dart +++ b/lib/routes.dart @@ -1,6 +1,7 @@ import 'package:doctor_app_flutter/config/config.dart'; import 'package:doctor_app_flutter/root_page.dart'; import 'package:doctor_app_flutter/screens/medical-file/medical_file_page.dart'; +import 'package:doctor_app_flutter/screens/patients/profile/UCAF/UCAF-detail-screen.dart'; import 'package:doctor_app_flutter/screens/patients/profile/UCAF/UCAF-input-screen.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'; @@ -91,6 +92,7 @@ const String PATIENT_ADMISSION_REQUEST = 'patients/admission-request'; const String PATIENT_ADMISSION_REQUEST_2 = 'patients/admission-request-second'; const String PATIENT_ADMISSION_REQUEST_3 = 'patients/admission-request-third'; const String PATIENT_UCAF_REQUEST = 'patients/ucaf'; +const String PATIENT_UCAF_DETAIL = 'patients/ucaf/detail'; const String BODY_MEASUREMENTS = 'patients/body-measurements'; const String IN_PATIENT_PRESCRIPTIONS_DETAILS = 'patients/prescription-details'; @@ -155,4 +157,5 @@ var routes = { // LIVECARE_END_DIALOG: (_) => EndCallDialogBox() MY_REFERRAL_DETAIL: (_) => MyReferralDetailScreen(), PATIENT_UCAF_REQUEST: (_) => UCAFInputScreen(), + PATIENT_UCAF_DETAIL: (_) => UcafDetailScreen(), }; diff --git a/lib/screens/patients/profile/UCAF/UCAF-detail-screen.dart b/lib/screens/patients/profile/UCAF/UCAF-detail-screen.dart new file mode 100644 index 00000000..7fc16bfb --- /dev/null +++ b/lib/screens/patients/profile/UCAF/UCAF-detail-screen.dart @@ -0,0 +1,107 @@ +import 'package:doctor_app_flutter/core/viewModel/patient-ucaf-viewmodel.dart'; +import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; +import 'package:doctor_app_flutter/screens/base/base_view.dart'; +import 'package:doctor_app_flutter/util/helpers.dart'; +import 'package:doctor_app_flutter/util/translations_delegate_base.dart'; +import 'package:doctor_app_flutter/widgets/patients/profile/PatientHeaderWidgetNoAvatar.dart'; +import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart'; +import 'package:flutter/material.dart'; +import 'package:hexcolor/hexcolor.dart'; + +class UcafDetailScreen extends StatefulWidget { + @override + _UcafDetailScreenState createState() => _UcafDetailScreenState(); +} + +class _UcafDetailScreenState extends State { + + int _activeTap = 1; + + @override + Widget build(BuildContext context) { + final routeArgs = ModalRoute.of(context).settings.arguments as Map; + PatiantInformtion patient = routeArgs['patient']; + final screenSize = MediaQuery.of(context).size; + + return BaseView( + builder: (_, model, w) => AppScaffold( + baseViewModel: model, + appBarTitle: TranslationBase.of(context).ucaf, + body: Container( + child: SingleChildScrollView( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + PatientHeaderWidgetNoAvatar(patient), + SizedBox( + height: 10, + ), + Container( + margin: + EdgeInsets.symmetric(vertical: 16, horizontal: 16), + child: Column( + children: [ + treatmentStepsBar(context, screenSize), + SizedBox( + height: 16, + ), + ], + ), + ), + ], + ), + ), + ), + )); + } + + Widget treatmentStepsBar(BuildContext _context, Size screenSize) { + List __treatmentSteps = [ + TranslationBase.of(context).diagnosis.toUpperCase(), + TranslationBase.of(context).medications.toUpperCase(), + TranslationBase.of(context).procedures.toUpperCase(), + ]; + return Container( + height: screenSize.height * 0.070, + decoration: + Helpers.containerBorderDecoration(Color(0Xffffffff), Color(0xFFCCCCCC)), + child: Row( + mainAxisSize: MainAxisSize.max, + crossAxisAlignment: CrossAxisAlignment.center, + children: __treatmentSteps.map((item) { + bool _isActive = __treatmentSteps[_activeTap] == item ? true : false; + return Expanded( + child: InkWell( + child: Center( + child: Container( + height: screenSize.height * 0.070, + decoration: Helpers.containerBorderDecoration( + _isActive ? HexColor("#B8382B") : Colors.white, + _isActive ? HexColor("#B8382B") : Colors.white), + child: Center( + child: Text( + item, + style: TextStyle( + fontSize: 12, + color: _isActive + ? Colors.white + : Colors.black, //Colors.black, + fontWeight: FontWeight.bold, + ), + ), + )), + ), + onTap: () { + print(__treatmentSteps.indexOf(item)); + setState(() { + _activeTap = __treatmentSteps.indexOf(item); + }); + }, + ), + ); + }).toList(), + ), + ); + } + +} diff --git a/lib/screens/patients/profile/UCAF/UCAF-input-screen.dart b/lib/screens/patients/profile/UCAF/UCAF-input-screen.dart index 82b01144..e0c2f9a7 100644 --- a/lib/screens/patients/profile/UCAF/UCAF-input-screen.dart +++ b/lib/screens/patients/profile/UCAF/UCAF-input-screen.dart @@ -5,6 +5,7 @@ import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; import 'package:doctor_app_flutter/screens/base/base_view.dart'; import 'package:doctor_app_flutter/util/helpers.dart'; import 'package:doctor_app_flutter/util/translations_delegate_base.dart'; +import 'package:doctor_app_flutter/widgets/patients/profile/PatientHeaderWidgetNoAvatar.dart'; import 'package:doctor_app_flutter/widgets/shared/app_buttons_widget.dart'; import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart'; import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart'; @@ -12,6 +13,8 @@ import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; import 'package:hexcolor/hexcolor.dart'; +import '../../../../routes.dart'; + class UCAFInputScreen extends StatefulWidget { @override _UCAFInputScreenState createState() => _UCAFInputScreenState(); @@ -58,7 +61,7 @@ class _UCAFInputScreenState extends State { body: SingleChildScrollView( child: Column( children: [ - PatientHeaderWidget(patient), + PatientHeaderWidgetNoAvatar(patient), Container( margin: EdgeInsets.symmetric(vertical: 16, horizontal: 16), child: Column( @@ -349,7 +352,7 @@ class _UCAFInputScreenState extends State { title: TranslationBase.of(context).next, color: HexColor("#B8382B"), onPressed: (){ - // Navigator.of(context).pushNamed(PATIENT_ADMISSION_REQUEST_3, arguments: {'patient': patient}); + Navigator.of(context).pushNamed(PATIENT_UCAF_DETAIL, arguments: {'patient': patient}); }, ), ], @@ -362,72 +365,3 @@ class _UCAFInputScreenState extends State { ); } } - -class PatientHeaderWidget extends StatelessWidget { - final PatiantInformtion patient; - - PatientHeaderWidget(this.patient); - - @override - Widget build(BuildContext context) { - return Column( - children: [ - Container( - margin: EdgeInsets.all(16), - child: Row( - children: [ - Expanded( - child: Column( - crossAxisAlignment: CrossAxisAlignment.start, - children: [ - AppText( - patient.firstName + ' ' + patient.lastName, - fontWeight: FontWeight.bold, - fontSize: SizeConfig.textMultiplier * 2.2, - ), - Row( - children: [ - AppText( - "VIP", - fontWeight: FontWeight.bold, - fontSize: SizeConfig.textMultiplier * 2.2, - ), - SizedBox( - width: 8, - ), - AppText( - " ${patient.age}", - fontWeight: FontWeight.normal, - fontSize: SizeConfig.textMultiplier * 2.0, - ), - ], - ), - AppText( - "NEW VISIT", - fontWeight: FontWeight.bold, - fontSize: SizeConfig.textMultiplier * 2.0, - ), - AppText( - "${patient.companyName}", - fontWeight: FontWeight.bold, - fontSize: SizeConfig.textMultiplier * 2.0, - ), - ], - ), - ), - Icon( - Icons.info_outline, - color: Colors.black, - ), - ], - ), - ), - Container( - width: double.infinity, - height: 1, - color: Color(0xffCCCCCC), - ), - ], - ); - } -} diff --git a/lib/screens/patients/profile/referral/refer-patient-screen.dart b/lib/screens/patients/profile/referral/refer-patient-screen.dart index 7a210b98..1ffd7150 100644 --- a/lib/screens/patients/profile/referral/refer-patient-screen.dart +++ b/lib/screens/patients/profile/referral/refer-patient-screen.dart @@ -1,4 +1,5 @@ import 'package:doctor_app_flutter/config/config.dart'; +import 'package:doctor_app_flutter/core/enum/master_lookup_key.dart'; import 'package:doctor_app_flutter/core/enum/viewstate.dart'; import 'package:doctor_app_flutter/core/viewModel/patient-referral-viewmodel.dart'; import 'package:doctor_app_flutter/models/patient/PatientArrivalEntity.dart'; @@ -19,7 +20,7 @@ import 'package:hexcolor/hexcolor.dart'; import '../../../QR_reader_screen.dart'; class PatientMakeReferralScreen extends StatefulWidget { - // previous design page is: MyReferralPatient + // previous design page is: ReferPatientScreen @override _PatientMakeReferralScreenState createState() => _PatientMakeReferralScreenState(); @@ -34,7 +35,6 @@ class _PatientMakeReferralScreenState extends State { dynamic _selectedDoctor; DateTime appointmentDate; final _remarksController = TextEditingController(); - PatientArrivalEntity _selectedPatientArrivalEntity; @override void initState() { @@ -55,7 +55,7 @@ class _PatientMakeReferralScreenState extends State { final screenSize = MediaQuery.of(context).size; return BaseView( - onModelReady: (model) => model.getBranches(), + onModelReady: (model) => model.getMasterLookup(MasterKeysService.physiotherapyGoals), builder: (_, model, w) => AppScaffold( baseViewModel: model, appBarTitle: TranslationBase.of(context).referPatient, @@ -284,8 +284,8 @@ class _PatientMakeReferralScreenState extends State { decoration: textFieldSelectorDecoration( TranslationBase.of(context) .chooseAppointment, - _selectedPatientArrivalEntity != null - ? "${TranslationBase.of(context).appointmentNo} ${_selectedPatientArrivalEntity.appointmentNo}" + appointmentDate != null + ? "${DateUtils.convertDateToFormat(appointmentDate, "yyyy-MM-dd")}" : null, true, suffixIcon: Icon( @@ -326,14 +326,14 @@ class _PatientMakeReferralScreenState extends State { title: TranslationBase.of(context).refer, color: HexColor("#B8382B"), onPressed: () { - if (_selectedPatientArrivalEntity == null || + if (appointmentDate == null || _selectedBranch == null || _selectedClinic == null || _selectedDoctor == null || _remarksController.text == null) return; model .makeReferral( - _selectedPatientArrivalEntity, + patient, appointmentDate.toIso8601String(), _selectedBranch['ID'], _selectedClinic['ClinicID'], @@ -362,8 +362,10 @@ class _PatientMakeReferralScreenState extends State { initialEntryMode: DatePickerEntryMode.calendar, ); if (picked != null && picked != appointmentDate) { - appointmentDate = picked; - model + setState(() { + appointmentDate = picked; + }); + /* model .getPatientArrivalList(DateUtils.convertStringToDateFormat( appointmentDate.toString(), "yyyy-MM-dd")) .then((_) { @@ -409,7 +411,7 @@ class _PatientMakeReferralScreenState extends State { DrAppToastMsg.showErrorToast( TranslationBase.of(context).noAppointmentsErrorMsg); } - }); + });*/ } } diff --git a/lib/screens/patients/profile/vital_sign/vital-signs-screen.dart b/lib/screens/patients/profile/vital_sign/vital-signs-screen.dart index 107e2e6b..c66555c1 100644 --- a/lib/screens/patients/profile/vital_sign/vital-signs-screen.dart +++ b/lib/screens/patients/profile/vital_sign/vital-signs-screen.dart @@ -11,6 +11,7 @@ import 'package:doctor_app_flutter/widgets/shared/app_scaffold_widget.dart'; import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart'; import 'package:doctor_app_flutter/widgets/shared/expandable-widget-header-body.dart'; import 'package:flutter/material.dart'; +import 'package:hexcolor/hexcolor.dart'; class PatientVitalSignScreen extends StatelessWidget { @override @@ -19,10 +20,7 @@ class PatientVitalSignScreen extends StatelessWidget { PatiantInformtion patient = routeArgs['patient']; return BaseView( - onModelReady: (model) => model.getPatientArrivalList( - DateUtils.convertDateToFormat(DateTime.now(), "yyyy-MM-dd"), patient, - fromDate: DateUtils.convertDateToFormat( - DateTime.now().subtract(Duration(days: 500)), "yyyy-MM-dd")), + onModelReady: (model) => model.getPatientVitalSign(patient), builder: (_, model, w) => AppScaffold( baseViewModel: model, appBarTitle: TranslationBase.of(context).vitalSign, @@ -213,10 +211,12 @@ class PatientVitalSignScreen extends StatelessWidget { Container( color: Colors.green, child: Padding( - padding: EdgeInsets.symmetric(vertical: 2, horizontal: 8), + padding: EdgeInsets.symmetric( + vertical: 2, horizontal: 8), child: AppText( "${model.getBMI(model.patientVitalSigns.bodyMassIndex)}", - fontSize: SizeConfig.textMultiplier * 2, + fontSize: + SizeConfig.textMultiplier * 2, color: Colors.white, fontWeight: FontWeight.bold, ), @@ -357,7 +357,14 @@ class PatientVitalSignScreen extends StatelessWidget { ), ), ) - : Container(), + : Center( + child: AppText( + "${TranslationBase.of(context).vitalSignEmptyMsg}", + fontSize: SizeConfig.textMultiplier * 2.5, + color: HexColor("#B8382B"), + fontWeight: FontWeight.normal, + ), + ), ), ); } @@ -485,7 +492,6 @@ class _TemperatureWidgetState extends State { } class PulseWidget extends StatefulWidget { - final VitalSignData vitalSign; PulseWidget(this.vitalSign); @@ -496,6 +502,7 @@ class PulseWidget extends StatefulWidget { class _PulseWidgetState extends State { bool isExpand = false; + @override Widget build(BuildContext context) { return Container( @@ -578,7 +585,6 @@ class _PulseWidgetState extends State { } class RespirationWidget extends StatefulWidget { - final VitalSignData vitalSign; RespirationWidget(this.vitalSign); @@ -672,7 +678,6 @@ class _RespirationWidgetState extends State { } class BloodPressureWidget extends StatefulWidget { - final VitalSignData vitalSign; BloodPressureWidget(this.vitalSign); @@ -812,7 +817,6 @@ class _BloodPressureWidgetState extends State { } class OxygenationWidget extends StatefulWidget { - final VitalSignData vitalSign; OxygenationWidget(this.vitalSign); @@ -906,7 +910,6 @@ class _OxygenationWidgetState extends State { } class PainScaleWidget extends StatefulWidget { - final VitalSignData vitalSign; PainScaleWidget(this.vitalSign); @@ -998,8 +1001,3 @@ class _PainScaleWidgetState extends State { ); } } - - - - - diff --git a/lib/util/translations_delegate_base.dart b/lib/util/translations_delegate_base.dart index 2cc38638..7070d252 100644 --- a/lib/util/translations_delegate_base.dart +++ b/lib/util/translations_delegate_base.dart @@ -507,6 +507,8 @@ class TranslationBase { String get createNew => localizedValues['createNew'][locale.languageCode]; String get episode => localizedValues['episode'][locale.languageCode]; + String get medications => localizedValues['medications'][locale.languageCode]; + String get procedures => localizedValues['procedures'][locale.languageCode]; String get chiefComplaints => localizedValues['chiefComplaints'][locale.languageCode]; @@ -530,6 +532,7 @@ class TranslationBase { localizedValues['selectAllergy'][locale.languageCode]; String get selectSeverity => localizedValues['selectSeverity'][locale.languageCode]; + String get vitalSignEmptyMsg => localizedValues['vitalSignEmptyMsg'][locale.languageCode]; } class TranslationBaseDelegate extends LocalizationsDelegate { diff --git a/lib/widgets/patients/profile/PatientHeaderWidgetNoAvatar.dart b/lib/widgets/patients/profile/PatientHeaderWidgetNoAvatar.dart new file mode 100644 index 00000000..25bc80e4 --- /dev/null +++ b/lib/widgets/patients/profile/PatientHeaderWidgetNoAvatar.dart @@ -0,0 +1,73 @@ +import 'package:doctor_app_flutter/config/size_config.dart'; +import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; +import 'package:doctor_app_flutter/widgets/shared/app_texts_widget.dart'; +import 'package:flutter/material.dart'; + +class PatientHeaderWidgetNoAvatar extends StatelessWidget { + final PatiantInformtion patient; + + PatientHeaderWidgetNoAvatar(this.patient); + + @override + Widget build(BuildContext context) { + return Column( + children: [ + Container( + margin: EdgeInsets.all(16), + child: Row( + children: [ + Expanded( + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + AppText( + patient.firstName + ' ' + patient.lastName, + fontWeight: FontWeight.bold, + fontSize: SizeConfig.textMultiplier * 2.2, + ), + Row( + children: [ + AppText( + "VIP", + fontWeight: FontWeight.bold, + fontSize: SizeConfig.textMultiplier * 2.2, + ), + SizedBox( + width: 8, + ), + AppText( + " ${patient.age}", + fontWeight: FontWeight.normal, + fontSize: SizeConfig.textMultiplier * 2.0, + ), + ], + ), + AppText( + "NEW VISIT", + fontWeight: FontWeight.bold, + fontSize: SizeConfig.textMultiplier * 2.0, + ), + AppText( + "${patient.companyName}", + fontWeight: FontWeight.bold, + fontSize: SizeConfig.textMultiplier * 2.0, + ), + ], + ), + ), + Icon( + Icons.info_outline, + color: Colors.black, + ), + ], + ), + ), + Container( + width: double.infinity, + height: 1, + color: Color(0xffCCCCCC), + ), + ], + ); + } +} diff --git a/pubspec.lock b/pubspec.lock index 7f1d8c1d..67028733 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -461,7 +461,7 @@ packages: name: js url: "https://pub.dartlang.org" source: hosted - version: "0.6.3-nullsafety.1" + version: "0.6.2" json_annotation: dependency: transitive description: