diff --git a/lib/client/base_app_client.dart b/lib/client/base_app_client.dart index 83dfad00..faef1fca 100644 --- a/lib/client/base_app_client.dart +++ b/lib/client/base_app_client.dart @@ -147,7 +147,7 @@ class BaseAppClient { : SETUP_ID; } - body['VersionID'] = 5.8; + body['VersionID'] = VERSION_ID; body['Channel'] = CHANNEL; body['LanguageID'] = languageID == 'ar' ? 1 : 2; diff --git a/lib/config/localized_values.dart b/lib/config/localized_values.dart index 53981e90..9aba36b8 100644 --- a/lib/config/localized_values.dart +++ b/lib/config/localized_values.dart @@ -276,8 +276,8 @@ const Map> localizedValues = { 'age2': {'en': 'Age: ', 'ar': 'العمر: '}, 'replySuccessfully': {'en': 'Reply Successfully', 'ar': 'تم الرد بنجاح'}, "sick-leaves": {"en": "Patient Sick Leave", "ar": "الاجازات المرضية"}, - "patient-sick": {"en": "Patient Sick", "ar": "المرضية"}, - "leave": {"en": "Leave", "ar": "غادر"}, + "patient-sick": {"en": "Patient Sick", "ar": "مرضية"}, + "leave": {"en": "Leave", "ar": "مغادره"}, "submit": {"en": "Submit", "ar": "ارسال"}, "doc-name": {"en": "Doctor Name", "ar": "اسم الطبيب"}, "clinicname": {"en": "Clinic Name", "ar": "اسم العيادة"}, @@ -819,7 +819,7 @@ const Map> localizedValues = { "add-reschedule": {"en": "Add reschedule", "ar": "أضف إعادة الجدولة"}, "update-reschedule": {"en": "Update reschedule", "ar": "تحديث إعادة الجدولة"}, - "sick_leave": {"en": "Sick Leave", "ar": "أجازة مرضية"}, + "sick_leave": {"en": "Sick Leave", "ar": "إجازة مرضية"}, "addSickLeaveRequest": { "en": "Add Sick Leave Request", "ar": "إضافة طلب إجازة مرضية" @@ -928,8 +928,8 @@ const Map> localizedValues = { "newRadiologyOrder": {"en": "New Radiology Order", "ar": "طلب الأشعة الجديد"}, "orderDate": {"en": "Order Date", "ar": "تاريخ الطلب"}, "examType": {"en": "Exam Type", "ar": "نوع الفحص"}, - "health": {"en": "Health", "ar": "التقرير"}, - "summary": {"en": "Summary", "ar": "الصحي"}, + "health": {"en": "Health", "ar": "الصحي"}, + "summary": {"en": "Summary", "ar": "التقرير"}, "applyForNewPrescriptionsOrder": { "en": "Apply for New Prescriptions Order", "ar": "التقدم بطلب للحصول على وصفات طبية جديدة " @@ -956,6 +956,11 @@ const Map> localizedValues = { 'noteAdd': {'en': 'Add ', 'ar': 'اضف '}, 'noteUpdateْْ': {'en': 'Update ', 'ar': 'تحديت'}, 'orderSheet': {'en': 'Order Sheet', 'ar': 'ورقة الطلب'}, + 'order': {'en': 'Order', 'ar': 'الطلب'}, + 'sheet': {'en': 'Sheet', 'ar': 'ورقة'}, + 'medical': {'en': 'Medical', 'ar': 'الطبي'}, + 'report': {'en': 'Report', 'ar': 'التقرير'}, + 'discharge': {'en': 'Discharge', 'ar': 'discharge'}, }; diff --git a/lib/routes.dart b/lib/routes.dart index 97f842f6..44613100 100644 --- a/lib/routes.dart +++ b/lib/routes.dart @@ -1,5 +1,5 @@ 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/medical-file/health_summary_page.dart'; import 'package:doctor_app_flutter/screens/patients/ECGPage.dart'; import 'package:doctor_app_flutter/screens/patients/insurance_approval_screen_patient.dart'; import 'package:doctor_app_flutter/screens/patients/profile/UCAF/UCAF-detail-screen.dart'; @@ -37,7 +37,7 @@ const String PATIENTS = 'patients/patients'; const String PATIENTS_PROFILE = 'patients/patients-profile'; const String IN_PATIENTS_PROFILE = 'inpatients/patients-profile'; const String LAB_RESULT = 'patients/lab_result'; -const String MEDICAL_FILE = 'patients/radiology'; +const String HEALTH_SUMMARY = 'patients/health-summary'; const String PROGRESS_NOTE = 'patients/progress-note'; const String ORDER_NOTE = 'patients/order-note'; @@ -70,7 +70,7 @@ var routes = { VERIFICATION_METHODS: (_) => VerificationMethodsScreen(), PATIENTS_PROFILE: (_) => PatientProfileScreen(), LAB_RESULT: (_) => LabsHomePage(), - MEDICAL_FILE: (_) => MedicalFilePage(), + HEALTH_SUMMARY: (_) => HealthSummaryPage(), PROGRESS_NOTE: (_) => ProgressNoteScreen(visitType: 5,), ORDER_NOTE: (_) => ProgressNoteScreen(visitType: 3,), REFER_PATIENT_TO_DOCTOR: (_) => PatientMakeReferralScreen(), diff --git a/lib/screens/medical-file/medical_file_page.dart b/lib/screens/medical-file/health_summary_page.dart similarity index 98% rename from lib/screens/medical-file/medical_file_page.dart rename to lib/screens/medical-file/health_summary_page.dart index b2590296..3096e775 100644 --- a/lib/screens/medical-file/medical_file_page.dart +++ b/lib/screens/medical-file/health_summary_page.dart @@ -11,12 +11,12 @@ import 'package:doctor_app_flutter/widgets/shared/doctor_card.dart'; import 'package:doctor_app_flutter/widgets/shared/network_base_view.dart'; import 'package:flutter/material.dart'; -class MedicalFilePage extends StatefulWidget { +class HealthSummaryPage extends StatefulWidget { @override - _MedicalFilePageState createState() => _MedicalFilePageState(); + _HealthSummaryPageState createState() => _HealthSummaryPageState(); } -class _MedicalFilePageState extends State { +class _HealthSummaryPageState extends State { PatiantInformtion patient; @override Widget build(BuildContext context) { diff --git a/lib/screens/patients/profile/in_patient_profile_screen.dart b/lib/screens/patients/profile/in_patient_profile_screen.dart index bce4c725..8b1c3b7e 100644 --- a/lib/screens/patients/profile/in_patient_profile_screen.dart +++ b/lib/screens/patients/profile/in_patient_profile_screen.dart @@ -141,7 +141,7 @@ class _InPatientProfileScreenState extends Statewith Sin patient: patient, patientType: patientType, arrivalType: arrivalType, - route: MEDICAL_FILE, + route: HEALTH_SUMMARY, nameLine1: "Health", //TranslationBase.of(context).medicalReport, nameLine2: "Summary", @@ -152,7 +152,7 @@ class _InPatientProfileScreenState extends Statewith Sin patientType: patientType, arrivalType: arrivalType, isDisable: true, - route: MEDICAL_FILE, + route: HEALTH_SUMMARY, nameLine1: "Medical", //Health //TranslationBase.of(context).medicalReport, nameLine2: "Report", //Report diff --git a/lib/screens/patients/profile/profile_screen/profile_gird_for_InPatient.dart b/lib/screens/patients/profile/profile_screen/profile_gird_for_InPatient.dart index 457fe04e..59b3dd2f 100644 --- a/lib/screens/patients/profile/profile_screen/profile_gird_for_InPatient.dart +++ b/lib/screens/patients/profile/profile_screen/profile_gird_for_InPatient.dart @@ -146,12 +146,9 @@ class ProfileGridForInPatient extends StatelessWidget { route: ORDER_NOTE, isDischargedPatient: isDischargedPatient, - nameLine1: - "Order", - //"Text", + nameLine1:TranslationBase.of(context).order, nameLine2: - "Sheet", - //TranslationBase.of(context).orders, + TranslationBase.of(context).sheet, icon: 'patient/Progress_notes.png'), PatientProfileButton( @@ -176,11 +173,11 @@ class ProfileGridForInPatient extends StatelessWidget { patient: patient, patientType: patientType, arrivalType: arrivalType, - route: MEDICAL_FILE, - nameLine1: "Health", + route: HEALTH_SUMMARY, + nameLine1: TranslationBase.of(context).health, + nameLine2: TranslationBase.of(context).summary, isInPatient: isInpatient, - nameLine2: "Summary", - //TranslationBase.of(context).summaryReport, + icon: 'patient/health_summary.png'), PatientProfileButton( @@ -188,15 +185,12 @@ class ProfileGridForInPatient extends StatelessWidget { patientType: patientType, arrivalType: arrivalType, isDisable: true, - route: MEDICAL_FILE, + route: HEALTH_SUMMARY, nameLine1: - "Medical", - //Health - isInPatient: isInpatient, + TranslationBase.of(context).medical, nameLine2: - "Report", - //Report - //TranslationBase.of(context).summaryReport, + TranslationBase.of(context).report, + isInPatient: isInpatient, icon: 'patient/health_summary.png'), PatientProfileButton( @@ -246,8 +240,8 @@ class ProfileGridForInPatient extends StatelessWidget { arrivalType: arrivalType, isDisable: true, route: null, - nameLine1: "Discharge", - nameLine2: "Summery", + nameLine1: TranslationBase.of(context).discharge, + nameLine2: TranslationBase.of(context).report, icon: 'patient/patient_sick_leave.png'), PatientProfileButton( diff --git a/lib/screens/patients/profile/profile_screen/profile_gird_for_other.dart b/lib/screens/patients/profile/profile_screen/profile_gird_for_other.dart index 5b7112d6..66894e11 100644 --- a/lib/screens/patients/profile/profile_screen/profile_gird_for_other.dart +++ b/lib/screens/patients/profile/profile_screen/profile_gird_for_other.dart @@ -131,11 +131,9 @@ class ProfileGridForOther extends StatelessWidget { patientType, arrivalType: arrivalType, - route: MEDICAL_FILE, - nameLine1: "Health", - //TranslationBase.of(context).medicalReport, - nameLine2: "Summary", - //TranslationBase.of(context).summaryReport, + route: HEALTH_SUMMARY, + nameLine1: TranslationBase.of(context).health, + nameLine2: TranslationBase.of(context).summary, icon: 'patient/health_summary.png'), PatientProfileButton( 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 ed3c4dfd..2d3679cf 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 @@ -80,11 +80,9 @@ class ProfileGridForSearch extends StatelessWidget { patient: patient, patientType: patientType, arrivalType: arrivalType, - route: MEDICAL_FILE, - nameLine1: "Health", - //TranslationBase.of(context).medicalReport, - nameLine2: "Summary", - //TranslationBase.of(context).summaryReport, + route: HEALTH_SUMMARY, + nameLine1: TranslationBase.of(context).health, + nameLine2: TranslationBase.of(context).summary, icon: 'patient/health_summary.png'), PatientProfileButton( isInPatient: isInpatient, diff --git a/lib/screens/sick-leave/add-sickleave.dart b/lib/screens/sick-leave/add-sickleave.dart index 6ee37745..a961c078 100644 --- a/lib/screens/sick-leave/add-sickleave.dart +++ b/lib/screens/sick-leave/add-sickleave.dart @@ -1,5 +1,6 @@ import 'package:doctor_app_flutter/config/size_config.dart'; import 'package:doctor_app_flutter/core/model/sick_leave_patient_model.dart'; +import 'package:doctor_app_flutter/core/viewModel/project_view_model.dart'; import 'package:doctor_app_flutter/core/viewModel/sick_leave_view_model.dart'; import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; import 'package:doctor_app_flutter/models/sickleave/get_all_sickleave_response.dart'; @@ -14,11 +15,15 @@ import 'package:doctor_app_flutter/widgets/shared/rounded_container_widget.dart' import 'package:doctor_app_flutter/widgets/transitions/fade_page.dart'; import 'package:flutter/material.dart'; import 'package:hexcolor/hexcolor.dart'; +import 'package:provider/provider.dart'; +// ignore: must_be_immutable class AddSickLeavScreen extends StatelessWidget { PatiantInformtion patient; @override Widget build(BuildContext context) { + ProjectViewModel projectsProvider = Provider.of(context); + final routeArgs = ModalRoute.of(context).settings.arguments as Map; patient = routeArgs['patient']; bool isInpatient = routeArgs['isInpatient']; @@ -37,8 +42,6 @@ class AddSickLeavScreen extends StatelessWidget { ), body: SingleChildScrollView( child: Column(children: [ - // PatientProfileHeaderNewDesign( - // patient, routeArgs['patientType'], routeArgs['arrivalType']), patient.patientStatusType == 43 ? Column( crossAxisAlignment: CrossAxisAlignment.start, @@ -48,6 +51,7 @@ class AddSickLeavScreen extends StatelessWidget { child: Column( crossAxisAlignment: CrossAxisAlignment.start, children: [ + if(!projectsProvider.isArabic) AppText( TranslationBase.of(context).patient, fontWeight: FontWeight.bold, diff --git a/lib/util/translations_delegate_base.dart b/lib/util/translations_delegate_base.dart index 0519d99e..8bf49397 100644 --- a/lib/util/translations_delegate_base.dart +++ b/lib/util/translations_delegate_base.dart @@ -1325,6 +1325,16 @@ class TranslationBase { String get orderSheet => localizedValues["orderSheet"][locale.languageCode]; + String get order => + localizedValues["order"][locale.languageCode]; + String get sheet => + localizedValues["sheet"][locale.languageCode]; + String get medical => + localizedValues["medical"][locale.languageCode]; + String get report => + localizedValues["report"][locale.languageCode]; + String get discharge => + localizedValues["discharge"][locale.languageCode]; } class TranslationBaseDelegate extends LocalizationsDelegate { diff --git a/lib/widgets/patients/profile/PatientProfileButton.dart b/lib/widgets/patients/profile/PatientProfileButton.dart index 9a027e36..f7c60623 100644 --- a/lib/widgets/patients/profile/PatientProfileButton.dart +++ b/lib/widgets/patients/profile/PatientProfileButton.dart @@ -77,7 +77,7 @@ class PatientProfileButton extends StatelessWidget { crossAxisAlignment: CrossAxisAlignment.start, children: [ AppText( - this.nameLine1, + !projectsProvider.isArabic?this.nameLine1: nameLine2, color: Colors.black, /*Color(0xFFB9382C),*/ fontWeight: FontWeight.w600, @@ -85,7 +85,7 @@ class PatientProfileButton extends StatelessWidget { fontSize: SizeConfig.textMultiplier * 1.5, ), AppText( - this.nameLine2, + !projectsProvider.isArabic? this.nameLine2:nameLine1, color: Colors.black, fontWeight: FontWeight.w600, textAlign: TextAlign.left, diff --git a/lib/widgets/patients/profile/profile_medical_info_widget.dart b/lib/widgets/patients/profile/profile_medical_info_widget.dart index a469138c..c5417d85 100644 --- a/lib/widgets/patients/profile/profile_medical_info_widget.dart +++ b/lib/widgets/patients/profile/profile_medical_info_widget.dart @@ -52,7 +52,7 @@ class ProfileMedicalInfoWidget extends StatelessWidget { patient: patient, patientType: patientType, arrivalType: arrivalType, - route: MEDICAL_FILE, + route: HEALTH_SUMMARY, nameLine1: "Health" ,//TranslationBase.of(context).medicalReport, nameLine2: "Summary",//TranslationBase.of(context).summaryReport, icon: 'patient/health_summary.png'), diff --git a/lib/widgets/patients/profile/profile_medical_info_widget_in_patient.dart b/lib/widgets/patients/profile/profile_medical_info_widget_in_patient.dart index eea3bfbb..17feaf0a 100644 --- a/lib/widgets/patients/profile/profile_medical_info_widget_in_patient.dart +++ b/lib/widgets/patients/profile/profile_medical_info_widget_in_patient.dart @@ -113,7 +113,7 @@ class ProfileMedicalInfoWidgetInPatient extends StatelessWidget { patient: patient, patientType: patientType, arrivalType: arrivalType, - route: MEDICAL_FILE, + route: HEALTH_SUMMARY, nameLine1: "Health", //TranslationBase.of(context).medicalReport, nameLine2: "Summary", @@ -125,7 +125,7 @@ class ProfileMedicalInfoWidgetInPatient extends StatelessWidget { patientType: patientType, arrivalType: arrivalType, isDisable: true, - route: MEDICAL_FILE, + route: HEALTH_SUMMARY, nameLine1: "Medical", //Health //TranslationBase.of(context).medicalReport, nameLine2: "Report", //Report diff --git a/lib/widgets/patients/profile/profile_medical_info_widget_search.dart b/lib/widgets/patients/profile/profile_medical_info_widget_search.dart index c03367bc..ac33eb82 100644 --- a/lib/widgets/patients/profile/profile_medical_info_widget_search.dart +++ b/lib/widgets/patients/profile/profile_medical_info_widget_search.dart @@ -173,7 +173,7 @@ class ProfileMedicalInfoWidgetSearch extends StatelessWidget { patient: patient, patientType: patientType, arrivalType: arrivalType, - route: MEDICAL_FILE, + route: HEALTH_SUMMARY, nameLine1: "Health", //TranslationBase.of(context).medicalReport, nameLine2: "Summary", @@ -185,7 +185,7 @@ class ProfileMedicalInfoWidgetSearch extends StatelessWidget { patientType: patientType, arrivalType: arrivalType, isDisable: true, - route: MEDICAL_FILE, + route: HEALTH_SUMMARY, nameLine1: "Medical", //Health //TranslationBase.of(context).medicalReport, nameLine2: "Report", //Report @@ -256,7 +256,7 @@ class ProfileMedicalInfoWidgetSearch extends StatelessWidget { patient: patient, patientType: patientType, arrivalType: arrivalType, - route: MEDICAL_FILE, + route: HEALTH_SUMMARY, nameLine1: "Health", //TranslationBase.of(context).medicalReport, nameLine2: