From 6fe3cecc9b4bd0150656be94a6e6ad72092832c9 Mon Sep 17 00:00:00 2001 From: Elham Rababh Date: Wed, 15 Dec 2021 19:47:03 +0200 Subject: [PATCH] reverting manully --- lib/UpdatePage.dart | 2 +- lib/client/base_app_client.dart | 129 +++----- lib/config/size_config.dart | 34 +- .../CheckActivationCodeModel.dart | 50 +-- .../CheckPatientForRegistrationModel.dart | 64 ++-- .../GetPatientInfoRequestModel.dart | 44 +-- .../GetPatientInfoResponseModel.dart | 262 +++++++-------- .../PatientRegistrationModel.dart | 152 ++++----- ...PNotificationTypeForRegistrationModel.dart | 92 +++--- .../model/Prescriptions/Prescriptions.dart | 147 ++++----- .../get_medication_for_inpatient_model.dart | 60 ++-- ...edication_for_inpatient_request_model.dart | 24 +- .../in_patient_prescription_model.dart | 2 +- .../Prescriptions/perscription_pharmacy.dart | 46 +-- .../post_prescrition_req_model.dart | 42 +-- .../prescription_in_patient.dart | 160 ++++----- .../Prescriptions/prescription_model.dart | 72 ++-- .../Prescriptions/prescription_report.dart | 84 ++--- .../prescription_report_enh.dart | 53 +-- .../Prescriptions/prescription_req_model.dart | 2 +- .../Prescriptions/prescriptions_order.dart | 34 +- ...t_get_list_pharmacy_for_prescriptions.dart | 48 +-- .../request_prescription_report.dart | 40 +-- .../request_prescription_report_enh.dart | 43 +-- .../admissionRequest/admission-request.dart | 105 +++--- .../model/admissionRequest/clinic-model.dart | 21 +- .../model/admissionRequest/ward-model.dart | 8 +- .../model/auth/activation_Code_req_model.dart | 16 +- ...on_code_for_verification_screen_model.dart | 29 +- ...on_code_for_doctor_app_response_model.dart | 78 ++--- .../check_activation_code_request_model.dart | 40 +-- lib/core/model/auth/imei_details.dart | 59 ++-- lib/core/model/auth/insert_imei_model.dart | 66 ++-- .../new_login_information_response_model.dart | 46 +-- ...on_code_for_doctor_app_response_model.dart | 8 +- .../model/calculate_box_request_model.dart | 10 +- .../model/diabetic_chart/DiabeticType.dart | 6 +- .../GetDiabeticChartValuesRequestModel.dart | 16 +- .../GetDiabeticChartValuesResponseModel.dart | 12 +- .../GetDiagnosisForInPatientRequestModel.dart | 10 +- ...GetDiagnosisForInPatientResponseModel.dart | 22 +- .../get_hospitals_request_model.dart | 18 +- .../get_hospitals_response_model.dart | 6 +- lib/core/model/hospitals_model.dart | 26 +- .../model/insurance/insurance_approval.dart | 66 ++-- .../insurance_approval_in_patient_model.dart | 118 +++---- lib/core/model/labs/LabOrderResult.dart | 30 +- lib/core/model/labs/LabResultHistory.dart | 48 +-- .../labs/all_special_lab_result_model.dart | 54 +-- .../labs/all_special_lab_result_request.dart | 28 +- lib/core/model/labs/lab_result.dart | 47 ++- lib/core/model/labs/patient_lab_orders.dart | 72 ++-- .../labs/patient_lab_special_result.dart | 10 +- .../labs/request_patient_lab_orders.dart | 26 +- .../request_patient_lab_special_result.dart | 36 +- .../labs/request_send_lab_report_email.dart | 50 +-- .../live_care/AlternativeServicesList.dart | 8 +- ...dingPatientERForDoctorAppRequestModel.dart | 6 +- ..._patient_to_doctor_list_request_model.dart | 10 +- .../live_care_login_reguest_model.dart | 10 +- .../medical_report/medical_file_model.dart | 258 +++++++-------- .../medical_file_request_model.dart | 6 +- lib/core/model/note/CreateNoteModel.dart | 38 +-- .../GetNursingProgressNoteRequestModel.dart | 16 +- .../GetNursingProgressNoteResposeModel.dart | 10 +- lib/core/model/note/note_model.dart | 40 +-- lib/core/model/note/update_note_model.dart | 34 +- .../patient_muse/PatientMuseResultsModel.dart | 24 +- .../PatientSearchRequestModel.dart | 30 +- lib/core/model/procedure/ControlsModel.dart | 4 +- .../Procedure_template_request_model.dart | 54 +-- .../model/procedure/categories_procedure.dart | 76 ++--- .../get_ordered_procedure_model.dart | 120 +++---- .../get_ordered_procedure_request_model.dart | 9 +- .../model/procedure/get_procedure_model.dart | 66 ++-- .../procedure/get_procedure_req_model.dart | 24 +- .../procedure/post_procedure_req_model.dart | 36 +- .../procedure_category_list_model.dart | 14 +- .../procedure/procedure_templateModel.dart | 18 +- .../procedure_template_details_model.dart | 106 +++--- ...cedure_template_details_request_model.dart | 56 ++-- .../procedure/procedure_valadate_model.dart | 14 +- .../procedure_valadate_request_model.dart | 10 +- .../update_procedure_request_model.dart | 28 +- lib/core/model/radiology/final_radiology.dart | 106 +++--- .../request_patient_rad_orders_details.dart | 40 +-- .../request_send_rad_report_email.dart | 58 ++-- .../referral/DischargeReferralPatient.dart | 308 ++++++------------ .../referral/MyReferralPatientModel.dart | 270 +++++++-------- .../MyReferralPatientRequestModel.dart | 46 +-- lib/core/model/referral/ReferralRequest.dart | 48 +-- .../add_referred_remarks_request.dart | 30 +- .../get_medication_response_model.dart | 18 +- .../search_drug/item_by_medicine_model.dart | 42 +-- .../item_by_medicine_request_model.dart | 4 +- .../model/search_drug/search_drug_model.dart | 10 +- .../search_drug_request_model.dart | 2 +- .../sick_leave_doctor_request_model.dart | 16 +- .../sick_leave/sick_leave_patient_model.dart | 10 +- .../sick_leave_patient_request_model.dart | 26 +- lib/core/service/VideoCallService.dart | 4 +- lib/core/service/base/base_service.dart | 60 +++- lib/core/service/home/dasboard_service.dart | 2 +- lib/core/service/home/scan_qr_service.dart | 8 +- .../service/hospitals/hospitals_service.dart | 3 +- .../patient/DischargedPatientService.dart | 14 +- .../patient/LiveCarePatientServices.dart | 19 +- .../patient/MyReferralPatientService.dart | 14 +- .../service/patient/PatientMuseService.dart | 2 +- lib/core/service/patient/ReferralService.dart | 8 +- .../patient-doctor-referral-service.dart | 10 +- .../patient/patientInPatientService.dart | 8 +- lib/core/service/patient/patient_service.dart | 12 +- .../profile/discharge_summary_servive.dart | 3 +- .../profile/operation_report_servive.dart | 19 +- .../insurance/InsuranceCardService.dart | 4 +- .../lab_order/labs_service.dart | 14 +- .../PatientMedicalReportService.dart | 4 +- .../medical_report/medical_file_service.dart | 2 +- .../prescription/prescription_service.dart | 4 +- .../prescription/prescriptions_service.dart | 14 +- .../procedure/procedure_service.dart | 14 +- .../radiology/radiology_service.dart | 2 +- .../sick_leave/sickleave_service.dart | 6 +- .../ucaf/patient-ucaf-service.dart | 6 +- lib/core/service/pending_order_service.dart | 4 +- .../viewModel/LiveCarePatientViewModel.dart | 18 +- .../viewModel/PatientSearchViewModel.dart | 6 +- lib/core/viewModel/SOAP_view_model.dart | 4 +- lib/core/viewModel/base_view_model.dart | 30 +- lib/core/viewModel/dashboard_view_model.dart | 4 +- .../viewModel/doctor_replay_view_model.dart | 4 +- lib/core/viewModel/labs_view_model.dart | 6 +- lib/core/viewModel/medicine_view_model.dart | 2 +- .../viewModel/patient-referral-viewmodel.dart | 2 +- .../viewModel/prescription_view_model.dart | 4 +- .../viewModel/prescriptions_view_model.dart | 6 +- lib/core/viewModel/procedure_View_model.dart | 16 +- lib/core/viewModel/project_view_model.dart | 2 +- lib/core/viewModel/radiology_view_model.dart | 4 +- lib/landing_page.dart | 2 +- .../doctor_replay/all_doctor_questions.dart | 2 +- .../doctor_replay/doctor_repaly_chat.dart | 6 +- .../doctor_replay/doctor_reply_screen.dart | 2 +- .../doctor_replay/doctor_reply_widget.dart | 2 +- .../home/dashboard_referral_patient.dart | 2 +- lib/screens/home/home_page_card.dart | 2 +- lib/screens/home/home_screen.dart | 4 +- lib/screens/home/label.dart | 2 +- .../live-care_transfer_to_admin.dart | 2 +- lib/screens/live_care/panding_list.dart | 2 +- .../medicine/pharmacies_list_screen.dart | 2 +- .../In_patient/in_patient_screen.dart | 2 +- .../In_patient/list_of_all_in_patient.dart | 4 +- ...t_patient_prescription_details_screen.dart | 2 +- .../patient_search/patient_search_screen.dart | 2 +- .../patients/patient_search/time_bar.dart | 2 +- .../profile/UCAF/ucaf_pager_screen.dart | 2 +- .../profile/diagnosis/diagnosis_screen.dart | 2 +- .../discharge_summary/discharge_summary.dart | 2 +- .../pending_discharge_summary.dart | 2 +- .../profile/lab_result/LabResultWidget.dart | 2 +- .../lab_result_chart_and_detials.dart | 2 +- .../lab_result_history_chart_and_detials.dart | 2 +- .../lab_result/lab_result_secreen.dart | 2 +- .../lab_result/laboratory_result_page.dart | 2 +- .../lab_result/laboratory_result_widget.dart | 2 +- .../special_lab_result_details_page.dart | 2 +- .../notes/note/progress_note_screen.dart | 8 +- .../profile/notes/note/update_note.dart | 4 +- .../operation_report/operation_report.dart | 2 +- .../update_operation_report.dart | 2 +- .../radiology/radiology_report_screen.dart | 2 +- .../refer-patient-screen-in-patient.dart | 2 +- .../referral/refer-patient-screen.dart | 2 +- .../assessment/add_assessment_details.dart | 4 +- .../assessment/update_assessment_page.dart | 4 +- .../objective/update_objective_page.dart | 8 +- .../soap_update/plan/update_plan_page.dart | 2 +- .../history/add_history_dialog.dart | 2 +- .../subjective/history/priority_bar.dart | 2 +- .../history/update_history_widget.dart | 2 +- .../subjective/update_subjective_page.dart | 6 +- .../soap_update/update_soap_index.dart | 6 +- ...al_sign_details_blood_pressurewideget.dart | 2 +- .../vital_sign_details_wideget.dart | 2 +- .../profile/vital_sign/vital_sign_item.dart | 2 +- .../vital_sing_chart_and_detials.dart | 2 +- .../vital_sing_chart_blood_pressure.dart | 2 +- .../prescription_checkout_screen.dart | 4 +- .../prescription_details_page.dart | 2 +- .../prescription_item_in_patient_page.dart | 2 +- .../prescription/prescription_items_page.dart | 2 +- .../update_prescription_form.dart | 4 +- .../procedures/ExpansionProcedure.dart | 2 +- lib/screens/procedures/ProcedureCard.dart | 2 +- .../procedures/add-favourite-procedure.dart | 4 +- .../procedures/add-procedure-page.dart | 6 +- .../base_add_procedure_tab_page.dart | 2 +- .../entity_list_checkbox_search_widget.dart | 12 +- .../procedures/entity_list_fav_procedure.dart | 14 +- .../procedures/procedure_checkout_screen.dart | 6 +- lib/screens/procedures/procedure_screen.dart | 2 +- lib/screens/procedures/update-procedure.dart | 4 +- lib/widgets/auth/method_type_card.dart | 4 +- .../auth/verification_methods_list.dart | 2 +- lib/widgets/charts/app_bar_chart.dart | 2 +- lib/widgets/charts/app_line_chart.dart | 2 +- lib/widgets/charts/app_time_series_chart.dart | 2 +- .../data_display/list/custom_Item.dart | 2 +- .../data_display/list/flexible_container.dart | 2 +- lib/widgets/doctor/lab_result_widget.dart | 2 +- .../doctor/my_referral_patient_widget.dart | 2 +- lib/widgets/doctor/my_schedule_widget.dart | 2 +- .../patients/clinic_list_dropdwon.dart | 2 +- .../patients/patient_card/PatientCard.dart | 2 +- .../patients/patient_card/ShowTimer.dart | 2 +- .../patients/patient_service_title.dart | 2 +- .../profile/PatientProfileButton.dart | 2 +- .../profile/Profile_general_info_Widget.dart | 2 +- .../profile/add-order/addNewOrder.dart | 2 +- .../patients/profile/large_avatar.dart | 2 +- .../prescription_in_patinets_widget.dart | 2 +- .../prescription_out_patinets_widget.dart | 2 +- .../profile/profile-welcome-widget.dart | 2 +- .../profile/profile_medical_info_widget.dart | 2 +- ...rofile_medical_info_widget_in_patient.dart | 2 +- .../profile_medical_info_widget_search.dart | 2 +- .../patients/vital_sign_details_wideget.dart | 2 +- lib/widgets/shared/StarRating.dart | 2 +- lib/widgets/shared/TextFields.dart | 2 +- lib/widgets/shared/app_drawer_widget.dart | 4 +- lib/widgets/shared/app_loader_widget.dart | 2 +- lib/widgets/shared/bottom_nav_bar.dart | 2 +- .../shared/buttons/secondary_button.dart | 2 +- lib/widgets/shared/charts/app_line_chart.dart | 2 +- .../shared/charts/app_time_series_chart.dart | 2 +- .../shared/dialogs/ShowImageDialog.dart | 2 +- .../shared/dialogs/dailog-list-select.dart | 6 +- .../shared/divider_with_spaces_around.dart | 2 +- .../dr_app_circular_progress_Indeicator.dart | 2 +- .../shared/errors/dr_app_embedded_error.dart | 2 +- lib/widgets/shared/errors/error_message.dart | 2 +- .../master_key_checkbox_search_widget.dart | 8 +- lib/widgets/shared/network_base_view.dart | 2 +- .../app_text_field_custom_serach.dart | 2 +- .../text_fields/auto_complete_text_field.dart | 2 +- .../text_fields/country_textfield_custom.dart | 2 +- .../shared/text_fields/new_text_Field.dart | 2 +- .../shared/text_fields/text_field_error.dart | 2 +- lib/widgets/shared/user-guid/CusomRow.dart | 2 +- .../shared/user-guid/app_showcase.dart | 2 +- .../user-guid/custom_validation_error.dart | 2 +- 253 files changed, 2806 insertions(+), 2906 deletions(-) diff --git a/lib/UpdatePage.dart b/lib/UpdatePage.dart index 16284ed1..ee866c64 100644 --- a/lib/UpdatePage.dart +++ b/lib/UpdatePage.dart @@ -14,7 +14,7 @@ class UpdatePage extends StatelessWidget { final String androidLink; final String iosLink; - const UpdatePage({Key key, this.message, this.androidLink, this.iosLink}) + const UpdatePage({Key ? key, this.message, this.androidLink, this.iosLink}) : super(key: key); @override diff --git a/lib/client/base_app_client.dart b/lib/client/base_app_client.dart index af4e6e97..15ae3382 100644 --- a/lib/client/base_app_client.dart +++ b/lib/client/base_app_client.dart @@ -22,9 +22,9 @@ Helpers helpers = new Helpers(); class BaseAppClient { //TODO change the post fun to nun static when you change all service post(String endPoint, - {Map body, - Function(dynamic response, int statusCode) onSuccess, - Function(String error, int statusCode) onFailure, + {required Map body, + required Function(dynamic response, int statusCode) onSuccess, + required Function(String error, int statusCode) onFailure, bool isAllowAny = false, bool isLiveCare = false, bool isFallLanguage = false}) async { @@ -36,30 +36,28 @@ class BaseAppClient { bool callLog = true; try { - Map profile = await sharedPref.getObj(DOCTOR_PROFILE); + Map? profile = await sharedPref.getObj(DOCTOR_PROFILE); String token = await sharedPref.getString(TOKEN); + DoctorProfileModel? doctorProfile; if (profile != null) { - DoctorProfileModel doctorProfile = DoctorProfileModel.fromJson(profile); - if (body['DoctorID'] == null) - body['DoctorID'] = doctorProfile?.doctorID; + doctorProfile = DoctorProfileModel.fromJson(profile); + if (body['DoctorID'] == null) body['DoctorID'] = doctorProfile!.doctorID; if (body['DoctorID'] == "") body['DoctorID'] = null; - if (body['EditedBy'] == null) - body['EditedBy'] = doctorProfile?.doctorID; + if (body['EditedBy'] == null) body['EditedBy'] = doctorProfile!.doctorID; if (body['ProjectID'] == null) { - body['ProjectID'] = doctorProfile?.projectID; + body['ProjectID'] = doctorProfile!.projectID; } - if (body['ClinicID'] == null) - body['ClinicID'] = doctorProfile?.clinicID; - } - if (body['DoctorID'] == '') { - body['DoctorID'] = null; - } - if (body['EditedBy'] == '') { - body.remove("EditedBy"); + if (body['ClinicID'] == null) body['ClinicID'] = doctorProfile!.clinicID; + if (body['DoctorID'] == '') { + body['DoctorID'] = null; + } + if (body['EditedBy'] == '') { + body.remove("EditedBy"); + } } if (body['TokenID'] == null) { - body['TokenID'] = token ?? ''; + body['TokenID'] = token; } // body['TokenID'] = "@dm!n" ?? ''; if (!isFallLanguage) { @@ -82,12 +80,10 @@ class BaseAppClient { body['IsLoginForDoctorApp'] = IS_LOGIN_FOR_DOCTOR_APP; body['PatientOutSA'] = body['PatientOutSA'] ?? 0; // PATIENT_OUT_SA; if (body['VidaAuthTokenID'] == null) { - body['VidaAuthTokenID'] = - await sharedPref.getString(VIDA_AUTH_TOKEN_ID); + body['VidaAuthTokenID'] = await sharedPref.getString(VIDA_AUTH_TOKEN_ID); } if (body['VidaRefreshTokenID'] == null) { - body['VidaRefreshTokenID'] = - await sharedPref.getString(VIDA_REFRESH_TOKEN_ID); + body['VidaRefreshTokenID'] = await sharedPref.getString(VIDA_REFRESH_TOKEN_ID); } int projectID = await sharedPref.getInt(PROJECT_ID); @@ -107,30 +103,22 @@ class BaseAppClient { var asd = json.encode(body); var asd2; if (await Helpers.checkConnection()) { - final response = await http.post(url, - body: json.encode(body), - headers: { - 'Content-Type': 'application/json', - 'Accept': 'application/json' - }); + final response = await http.post(Uri.parse(url), + body: json.encode(body), headers: {'Content-Type': 'application/json', 'Accept': 'application/json'}); final int statusCode = response.statusCode; if (statusCode < 200 || statusCode >= 400) { onFailure(Helpers.generateContactAdminMsg(), statusCode); } else { var parsed = json.decode(response.body.toString()); if (parsed['ErrorType'] == 4) { - helpers.navigateToUpdatePage(parsed['ErrorEndUserMessage'], - parsed['AndroidLink'], parsed['IOSLink']); + helpers.navigateToUpdatePage(parsed['ErrorEndUserMessage'], parsed['AndroidLink'], parsed['IOSLink']); } if (parsed['IsAuthenticated'] != null && !parsed['IsAuthenticated']) { if (body['OTP_SendType'] != null) { onFailure(getError(parsed), statusCode); } else if (!isAllowAny) { - await Provider.of(AppGlobal.CONTEX, - listen: false) - .logout(); - + await Provider.of(AppGlobal.CONTEX, listen: false).logout(); Helpers.showErrorToast('Your session expired Please login again'); locator().pushNamedAndRemoveUntil(ROOT); } @@ -156,22 +144,18 @@ class BaseAppClient { } postPatient(String endPoint, - {Map body, - Function(dynamic response, int statusCode) onSuccess, - Function(String error, int statusCode) onFailure, - @required PatiantInformtion patient, + {required Map body, + required Function(dynamic response, int statusCode) onSuccess, + required Function(String error, int statusCode) onFailure, + PatiantInformtion? patient, bool isExternal = false}) async { String url = BASE_URL + endPoint; try { - Map headers = { - 'Content-Type': 'application/json', - 'Accept': 'application/json' - }; + Map headers = {'Content-Type': 'application/json', 'Accept': 'application/json'}; String token = await sharedPref.getString(TOKEN); - var languageID = - await sharedPref.getStringWithDefaultValue(APP_Language, 'en'); + var languageID = await sharedPref.getStringWithDefaultValue(APP_Language, 'en'); body['SetupID'] = body.containsKey('SetupID') ? body['SetupID'] != null ? body['SetupID'] @@ -191,12 +175,11 @@ class BaseAppClient { : PATIENT_OUT_SA_PATIENT_REQ; if (body.containsKey('isDentalAllowedBackend')) { - body['isDentalAllowedBackend'] = - body.containsKey('isDentalAllowedBackend') - ? body['isDentalAllowedBackend'] != null - ? body['isDentalAllowedBackend'] - : IS_DENTAL_ALLOWED_BACKEND - : IS_DENTAL_ALLOWED_BACKEND; + body['isDentalAllowedBackend'] = body.containsKey('isDentalAllowedBackend') + ? body['isDentalAllowedBackend'] != null + ? body['isDentalAllowedBackend'] + : IS_DENTAL_ALLOWED_BACKEND + : IS_DENTAL_ALLOWED_BACKEND; } body['DeviceTypeID'] = Platform.isAndroid ? 1 : 2; @@ -204,7 +187,7 @@ class BaseAppClient { body['PatientType'] = body.containsKey('PatientType') ? body['PatientType'] != null ? body['PatientType'] - : patient.patientType != null + : patient!.patientType != null ? patient.patientType : PATIENT_TYPE : PATIENT_TYPE; @@ -212,15 +195,13 @@ class BaseAppClient { body['PatientTypeID'] = body.containsKey('PatientTypeID') ? body['PatientTypeID'] != null ? body['PatientTypeID'] - : patient.patientType != null + : patient!.patientType != null ? patient.patientType : PATIENT_TYPE_ID : PATIENT_TYPE_ID; body['TokenID'] = body.containsKey('TokenID') ? body['TokenID'] : token; - body['PatientID'] = body['PatientID'] != null - ? body['PatientID'] - : patient.patientId ?? patient.patientMRN; + body['PatientID'] = body['PatientID'] != null ? body['PatientID'] : patient!.patientId ?? patient.patientMRN; body['PatientOutSA'] = 0; //user['OutSA']; //TODO change it body['SessionID'] = SESSION_ID; //getSe @@ -236,8 +217,7 @@ class BaseAppClient { var asd = json.encode(body); var asd2; if (await Helpers.checkConnection()) { - final response = await http.post(url.trim(), - body: json.encode(body), headers: headers); + final response = await http.post(Uri.parse(url.trim()), body: json.encode(body), headers: headers); final int statusCode = response.statusCode; print("statusCode :$statusCode"); if (statusCode < 200 || statusCode >= 400 || json == null) { @@ -249,8 +229,7 @@ class BaseAppClient { onSuccess(parsed, statusCode); } else { if (parsed['ErrorType'] == 4) { - helpers.navigateToUpdatePage(parsed['ErrorEndUserMessage'], - parsed['AndroidLink'], parsed['IOSLink']); + helpers.navigateToUpdatePage(parsed['ErrorEndUserMessage'], parsed['AndroidLink'], parsed['IOSLink']); } if (parsed['IsAuthenticated'] == null) { if (parsed['isSMSSent'] == true) { @@ -266,28 +245,20 @@ class BaseAppClient { onFailure(getError(parsed), statusCode); } } - } else if (parsed['MessageStatus'] == 1 || - parsed['SMSLoginRequired'] == true) { + } else if (parsed['MessageStatus'] == 1 || parsed['SMSLoginRequired'] == true) { onSuccess(parsed, statusCode); - } else if (parsed['MessageStatus'] == 2 && - parsed['IsAuthenticated']) { + } else if (parsed['MessageStatus'] == 2 && parsed['IsAuthenticated']) { if (parsed['SameClinicApptList'] != null) { onSuccess(parsed, statusCode); } else { - if (parsed['message'] == null && - parsed['ErrorEndUserMessage'] == null) { + if (parsed['message'] == null && parsed['ErrorEndUserMessage'] == null) { if (parsed['ErrorSearchMsg'] == null) { - onFailure("Server Error found with no available message", - statusCode); + onFailure("Server Error found with no available message", statusCode); } else { onFailure(parsed['ErrorSearchMsg'], statusCode); } } else { - onFailure( - parsed['message'] ?? - parsed['ErrorEndUserMessage'] ?? - parsed['ErrorMessage'], - statusCode); + onFailure(parsed['message'] ?? parsed['ErrorEndUserMessage'] ?? parsed['ErrorMessage'], statusCode); } } } else { @@ -297,9 +268,7 @@ class BaseAppClient { if (parsed['message'] != null) { onFailure(parsed['message'] ?? parsed['message'], statusCode); } else { - onFailure( - parsed['ErrorEndUserMessage'] ?? parsed['ErrorMessage'], - statusCode); + onFailure(parsed['ErrorEndUserMessage'] ?? parsed['ErrorMessage'], statusCode); } } } @@ -322,12 +291,8 @@ class BaseAppClient { if (parsed["ValidationErrors"]["ValidationErrors"] != null && parsed["ValidationErrors"]["ValidationErrors"].length != 0) { - for (var i = 0; - i < parsed["ValidationErrors"]["ValidationErrors"].length; - i++) { - error = error + - parsed["ValidationErrors"]["ValidationErrors"][i]["Messages"][0] + - "\n"; + for (var i = 0; i < parsed["ValidationErrors"]["ValidationErrors"].length; i++) { + error = error + parsed["ValidationErrors"]["ValidationErrors"][i]["Messages"][0] + "\n"; } } } diff --git a/lib/config/size_config.dart b/lib/config/size_config.dart index 21859d3b..c6ec4fdd 100644 --- a/lib/config/size_config.dart +++ b/lib/config/size_config.dart @@ -5,15 +5,16 @@ class SizeConfig { static double _blockWidth = 0; static double _blockHeight = 0; - static double realScreenWidth; - static double realScreenHeight; - static double screenWidth; - static double screenHeight; - static double textMultiplier; - static double imageSizeMultiplier; - static double heightMultiplier; + static late double realScreenWidth; + static late double realScreenHeight; + static late double screenWidth; + static late double screenHeight; + static late double textMultiplier; + static late double imageSizeMultiplier; + static late double heightMultiplier; + static late double widthMultiplier; + static bool isPortrait = true; - static double widthMultiplier; static bool isMobilePortrait = false; static bool isMobile = false; static bool isHeightShort = false; @@ -24,6 +25,7 @@ class SizeConfig { void init(BoxConstraints constraints, Orientation orientation) { realScreenHeight = constraints.maxHeight; realScreenWidth = constraints.maxWidth; + if (constraints.maxWidth <= MAX_SMALL_SCREEN) { isMobile = true; } @@ -46,20 +48,16 @@ class SizeConfig { if (realScreenWidth < 450) { isMobilePortrait = true; } - // textMultiplier = _blockHeight; - // imageSizeMultiplier = _blockWidth; screenHeight = realScreenHeight; screenWidth = realScreenWidth; } else { isPortrait = false; isMobilePortrait = false; - // textMultiplier = _blockWidth; - // imageSizeMultiplier = _blockHeight; screenHeight = realScreenWidth; screenWidth = realScreenHeight; } - _blockWidth = screenWidth / 100; - _blockHeight = screenHeight / 100; + _blockWidth = (screenWidth / 100); + _blockHeight = (screenHeight / 100); textMultiplier = _blockHeight; imageSizeMultiplier = _blockWidth; @@ -74,9 +72,11 @@ class SizeConfig { print('widthMultiplier $widthMultiplier'); print('isPortrait $isPortrait'); print('isMobilePortrait $isMobilePortrait'); + + } - static getTextMultiplierBasedOnWidth({double width}) { + static getTextMultiplierBasedOnWidth({double? width}) { // TODO handel LandScape case if (width != null) { return width / 100; @@ -84,7 +84,7 @@ class SizeConfig { return widthMultiplier; } - static getWidthMultiplier({double width}) { +static getWidthMultiplier({double? width}) { // TODO handel LandScape case if (width != null) { return width / 100; @@ -92,7 +92,7 @@ class SizeConfig { return widthMultiplier; } - static getHeightMultiplier({double height}) { + static getHeightMultiplier({double? height}) { // TODO handel LandScape case if (height != null) { return height / 100; diff --git a/lib/core/model/PatientRegistration/CheckActivationCodeModel.dart b/lib/core/model/PatientRegistration/CheckActivationCodeModel.dart index 4b95c1b0..ff412db2 100644 --- a/lib/core/model/PatientRegistration/CheckActivationCodeModel.dart +++ b/lib/core/model/PatientRegistration/CheckActivationCodeModel.dart @@ -1,29 +1,29 @@ class CheckActivationCodeModel { - int patientMobileNumber; - String mobileNo; - int projectOutSA; - int loginType; - String zipCode; - bool isRegister; - String logInTokenID; - int searchType; - int patientID; - int nationalID; - int patientIdentificationID; - bool forRegisteration; - String activationCode; - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - Null sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - String dOB; - int isHijri; - String healthId; + int? patientMobileNumber; + String? mobileNo; + int? projectOutSA; + int? loginType; + String? zipCode; + bool? isRegister; + String? logInTokenID; + int? searchType; + int? patientID; + int? nationalID; + int? patientIdentificationID; + bool? forRegisteration; + String? activationCode; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; + Null? sessionID; + bool? isDentalAllowedBackend; + int ?deviceTypeID; + String? dOB; + int? isHijri; + String? healthId; CheckActivationCodeModel( {this.patientMobileNumber, diff --git a/lib/core/model/PatientRegistration/CheckPatientForRegistrationModel.dart b/lib/core/model/PatientRegistration/CheckPatientForRegistrationModel.dart index 3465cf8d..89e1bfd6 100644 --- a/lib/core/model/PatientRegistration/CheckPatientForRegistrationModel.dart +++ b/lib/core/model/PatientRegistration/CheckPatientForRegistrationModel.dart @@ -1,40 +1,40 @@ class CheckPatientForRegistrationModel { - int patientIdentificationID; - int patientMobileNumber; - String zipCode; - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; + int? patientIdentificationID; + int? patientMobileNumber; + String? zipCode; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; Null sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - String tokenID; - int patientID; - bool isRegister; - String dOB; - int isHijri; + bool? isDentalAllowedBackend; + int? deviceTypeID; + String? tokenID; + int? patientID; + bool? isRegister; + String? dOB; + int? isHijri; CheckPatientForRegistrationModel( {this.patientIdentificationID, - this.patientMobileNumber, - this.zipCode, - this.versionID, - this.channel, - this.languageID, - this.iPAdress, - this.generalid, - this.patientOutSA, - this.sessionID, - this.isDentalAllowedBackend, - this.deviceTypeID, - this.tokenID, - this.patientID, - this.isRegister, - this.dOB, - this.isHijri}); + this.patientMobileNumber, + this.zipCode, + this.versionID, + this.channel, + this.languageID, + this.iPAdress, + this.generalid, + this.patientOutSA, + this.sessionID, + this.isDentalAllowedBackend, + this.deviceTypeID, + this.tokenID, + this.patientID, + this.isRegister, + this.dOB, + this.isHijri}); CheckPatientForRegistrationModel.fromJson(Map json) { patientIdentificationID = json['PatientIdentificationID']; diff --git a/lib/core/model/PatientRegistration/GetPatientInfoRequestModel.dart b/lib/core/model/PatientRegistration/GetPatientInfoRequestModel.dart index f05131ef..1f00fba0 100644 --- a/lib/core/model/PatientRegistration/GetPatientInfoRequestModel.dart +++ b/lib/core/model/PatientRegistration/GetPatientInfoRequestModel.dart @@ -1,30 +1,30 @@ class GetPatientInfoRequestModel { - String patientIdentificationID; - String dOB; - int isHijri; - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; + String? patientIdentificationID; + String? dOB; + int? isHijri; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; Null sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; + bool? isDentalAllowedBackend; + int? deviceTypeID; GetPatientInfoRequestModel( {this.patientIdentificationID, - this.dOB, - this.isHijri, - this.versionID, - this.channel, - this.languageID, - this.iPAdress, - this.generalid, - this.patientOutSA, - this.sessionID, - this.isDentalAllowedBackend, - this.deviceTypeID}); + this.dOB, + this.isHijri, + this.versionID, + this.channel, + this.languageID, + this.iPAdress, + this.generalid, + this.patientOutSA, + this.sessionID, + this.isDentalAllowedBackend, + this.deviceTypeID}); GetPatientInfoRequestModel.fromJson(Map json) { patientIdentificationID = json['PatientIdentificationID']; diff --git a/lib/core/model/PatientRegistration/GetPatientInfoResponseModel.dart b/lib/core/model/PatientRegistration/GetPatientInfoResponseModel.dart index 158bd1e2..0aeb5660 100644 --- a/lib/core/model/PatientRegistration/GetPatientInfoResponseModel.dart +++ b/lib/core/model/PatientRegistration/GetPatientInfoResponseModel.dart @@ -1,78 +1,78 @@ class GetPatientInfoResponseModel { dynamic date; - int languageID; - int serviceName; + int? languageID; + int? serviceName; dynamic time; dynamic androidLink; dynamic authenticationTokenID; dynamic data; - bool dataw; - int dietType; + bool? dataw; + int? dietType; dynamic errorCode; dynamic errorEndUserMessage; dynamic errorEndUserMessageN; dynamic errorMessage; - int errorType; - int foodCategory; + int? errorType; + int? foodCategory; dynamic iOSLink; - bool isAuthenticated; - int mealOrderStatus; - int mealType; - int messageStatus; - int numberOfResultRecords; + bool? isAuthenticated; + int? mealOrderStatus; + int? mealType; + int? messageStatus; + int? numberOfResultRecords; dynamic patientBlodType; dynamic successMsg; dynamic successMsgN; dynamic vidaUpdatedResponse; dynamic accessTokenObject; - int age; + int? age; dynamic clientIdentifierId; - int createdBy; - String dateOfBirth; - String firstNameAr; - String firstNameEn; - String gender; + int? createdBy; + String? dateOfBirth; + String? firstNameAr; + String? firstNameEn; + String? gender; dynamic genderAr; dynamic genderEn; - String healthId; - String idNumber; - String idType; - bool isHijri; - int isInstertedOrUpdated; - int isNull; - int isPatientExistNHIC; - bool isRecordLockedByCurrentUser; - String lastNameAr; - String lastNameEn; + String? healthId; + String? idNumber; + String? idType; + bool? isHijri; + int? isInstertedOrUpdated; + int? isNull; + int? isPatientExistNHIC; + bool? isRecordLockedByCurrentUser; + String? lastNameAr; + String? lastNameEn; dynamic listActiveAccessToken; - String maritalStatus; - String maritalStatusCode; - String nationalDateOfBirth; - String nationality; - String nationalityCode; - String occupation; + String? maritalStatus; + String? maritalStatusCode; + String? nationalDateOfBirth; + String? nationality; + String? nationalityCode; + String? occupation; dynamic pCDTransactionDataResultList; dynamic pCDGetVidaPatientForManualVerificationList; dynamic pCDNHICHMGPatientDetailsMatchCalulationList; - int pCDReturnValue; - String patientStatus; - String placeofBirth; + int? pCDReturnValue; + String? patientStatus; + String? placeofBirth; dynamic practitionerStatusCode; dynamic practitionerStatusDescAr; dynamic practitionerStatusDescEn; - int rowCount; - String secondNameAr; - String secondNameEn; - String thirdNameAr; - String thirdNameEn; + int? rowCount; + String? secondNameAr; + String? secondNameEn; + String? thirdNameAr; + String? thirdNameEn; dynamic yakeenVidaPatientDataStatisticsByPatientIdList; dynamic yakeenVidaPatientDataStatisticsList; dynamic yakeenVidaPatientDataStatisticsPrefferedList; dynamic accessToken; - int categoryCode; + int? categoryCode; dynamic categoryNameAr; dynamic categoryNameEn; - int constraintCode; + int? constraintCode; dynamic constraintNameAr; dynamic constraintNameEn; dynamic content; @@ -84,99 +84,99 @@ class GetPatientInfoResponseModel { dynamic licenseStatusDescEn; dynamic organizations; dynamic registrationNumber; - int specialtyCode; + int? specialtyCode; dynamic specialtyNameAr; dynamic specialtyNameEn; GetPatientInfoResponseModel( {this.date, - this.languageID, - this.serviceName, - this.time, - this.androidLink, - this.authenticationTokenID, - this.data, - this.dataw, - this.dietType, - this.errorCode, - this.errorEndUserMessage, - this.errorEndUserMessageN, - this.errorMessage, - this.errorType, - this.foodCategory, - this.iOSLink, - this.isAuthenticated, - this.mealOrderStatus, - this.mealType, - this.messageStatus, - this.numberOfResultRecords, - this.patientBlodType, - this.successMsg, - this.successMsgN, - this.vidaUpdatedResponse, - this.accessTokenObject, - this.age, - this.clientIdentifierId, - this.createdBy, - this.dateOfBirth, - this.firstNameAr, - this.firstNameEn, - this.gender, - this.genderAr, - this.genderEn, - this.healthId, - this.idNumber, - this.idType, - this.isHijri, - this.isInstertedOrUpdated, - this.isNull, - this.isPatientExistNHIC, - this.isRecordLockedByCurrentUser, - this.lastNameAr, - this.lastNameEn, - this.listActiveAccessToken, - this.maritalStatus, - this.maritalStatusCode, - this.nationalDateOfBirth, - this.nationality, - this.nationalityCode, - this.occupation, - this.pCDTransactionDataResultList, - this.pCDGetVidaPatientForManualVerificationList, - this.pCDNHICHMGPatientDetailsMatchCalulationList, - this.pCDReturnValue, - this.patientStatus, - this.placeofBirth, - this.practitionerStatusCode, - this.practitionerStatusDescAr, - this.practitionerStatusDescEn, - this.rowCount, - this.secondNameAr, - this.secondNameEn, - this.thirdNameAr, - this.thirdNameEn, - this.yakeenVidaPatientDataStatisticsByPatientIdList, - this.yakeenVidaPatientDataStatisticsList, - this.yakeenVidaPatientDataStatisticsPrefferedList, - this.accessToken, - this.categoryCode, - this.categoryNameAr, - this.categoryNameEn, - this.constraintCode, - this.constraintNameAr, - this.constraintNameEn, - this.content, - this.errorList, - this.licenseExpiryDate, - this.licenseIssuedDate, - this.licenseStatusCode, - this.licenseStatusDescAr, - this.licenseStatusDescEn, - this.organizations, - this.registrationNumber, - this.specialtyCode, - this.specialtyNameAr, - this.specialtyNameEn}); + this.languageID, + this.serviceName, + this.time, + this.androidLink, + this.authenticationTokenID, + this.data, + this.dataw, + this.dietType, + this.errorCode, + this.errorEndUserMessage, + this.errorEndUserMessageN, + this.errorMessage, + this.errorType, + this.foodCategory, + this.iOSLink, + this.isAuthenticated, + this.mealOrderStatus, + this.mealType, + this.messageStatus, + this.numberOfResultRecords, + this.patientBlodType, + this.successMsg, + this.successMsgN, + this.vidaUpdatedResponse, + this.accessTokenObject, + this.age, + this.clientIdentifierId, + this.createdBy, + this.dateOfBirth, + this.firstNameAr, + this.firstNameEn, + this.gender, + this.genderAr, + this.genderEn, + this.healthId, + this.idNumber, + this.idType, + this.isHijri, + this.isInstertedOrUpdated, + this.isNull, + this.isPatientExistNHIC, + this.isRecordLockedByCurrentUser, + this.lastNameAr, + this.lastNameEn, + this.listActiveAccessToken, + this.maritalStatus, + this.maritalStatusCode, + this.nationalDateOfBirth, + this.nationality, + this.nationalityCode, + this.occupation, + this.pCDTransactionDataResultList, + this.pCDGetVidaPatientForManualVerificationList, + this.pCDNHICHMGPatientDetailsMatchCalulationList, + this.pCDReturnValue, + this.patientStatus, + this.placeofBirth, + this.practitionerStatusCode, + this.practitionerStatusDescAr, + this.practitionerStatusDescEn, + this.rowCount, + this.secondNameAr, + this.secondNameEn, + this.thirdNameAr, + this.thirdNameEn, + this.yakeenVidaPatientDataStatisticsByPatientIdList, + this.yakeenVidaPatientDataStatisticsList, + this.yakeenVidaPatientDataStatisticsPrefferedList, + this.accessToken, + this.categoryCode, + this.categoryNameAr, + this.categoryNameEn, + this.constraintCode, + this.constraintNameAr, + this.constraintNameEn, + this.content, + this.errorList, + this.licenseExpiryDate, + this.licenseIssuedDate, + this.licenseStatusCode, + this.licenseStatusDescAr, + this.licenseStatusDescEn, + this.organizations, + this.registrationNumber, + this.specialtyCode, + this.specialtyNameAr, + this.specialtyNameEn}); GetPatientInfoResponseModel.fromJson(Map json) { date = json['Date']; diff --git a/lib/core/model/PatientRegistration/PatientRegistrationModel.dart b/lib/core/model/PatientRegistration/PatientRegistrationModel.dart index 83ff53d7..a73ecb0b 100644 --- a/lib/core/model/PatientRegistration/PatientRegistrationModel.dart +++ b/lib/core/model/PatientRegistration/PatientRegistrationModel.dart @@ -1,42 +1,42 @@ class PatientRegistrationModel { - Patientobject patientobject; - String patientIdentificationID; - String patientMobileNumber; - String logInTokenID; - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; + Patientobject? patientobject; + String? patientIdentificationID; + String? patientMobileNumber; + String? logInTokenID; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; Null sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - String tokenID; - String dOB; - int isHijri; - String healthId; - String zipCode; + bool? isDentalAllowedBackend; + int? deviceTypeID; + String? tokenID; + String? dOB; + int? isHijri; + String? healthId; + String? zipCode; PatientRegistrationModel( {this.patientobject, - this.patientIdentificationID, - this.patientMobileNumber, - this.logInTokenID, - this.versionID, - this.channel, - this.languageID, - this.iPAdress, - this.generalid, - this.patientOutSA, - this.sessionID, - this.isDentalAllowedBackend, - this.deviceTypeID, - this.tokenID, - this.dOB, - this.isHijri, - this.healthId, - this.zipCode}); + this.patientIdentificationID, + this.patientMobileNumber, + this.logInTokenID, + this.versionID, + this.channel, + this.languageID, + this.iPAdress, + this.generalid, + this.patientOutSA, + this.sessionID, + this.isDentalAllowedBackend, + this.deviceTypeID, + this.tokenID, + this.dOB, + this.isHijri, + this.healthId, + this.zipCode}); PatientRegistrationModel.fromJson(Map json) { patientobject = json['Patientobject'] != null @@ -64,7 +64,7 @@ class PatientRegistrationModel { Map toJson() { final Map data = new Map(); if (this.patientobject != null) { - data['Patientobject'] = this.patientobject.toJson(); + data['Patientobject'] = this.patientobject!.toJson(); } data['PatientIdentificationID'] = this.patientIdentificationID; data['PatientMobileNumber'] = this.patientMobileNumber; @@ -88,50 +88,50 @@ class PatientRegistrationModel { } class Patientobject { - bool tempValue; - int patientIdentificationType; - String patientIdentificationNo; - int mobileNumber; - int patientOutSA; - String firstNameN; - String middleNameN; - String lastNameN; - String firstName; - String middleName; - String lastName; - String strDateofBirth; - String dateofBirth; - int gender; - String nationalityID; - String dateofBirthN; - String emailAddress; - String sourceType; - String preferredLanguage; - String marital; - String eHealthIDField; + bool? tempValue; + int? patientIdentificationType; + String? patientIdentificationNo; + int? mobileNumber; + int? patientOutSA; + String? firstNameN; + String? middleNameN; + String? lastNameN; + String? firstName; + String? middleName; + String? lastName; + String? strDateofBirth; + String? dateofBirth; + int? gender; + String? nationalityID; + String? dateofBirthN; + String? emailAddress; + String? sourceType; + String? preferredLanguage; + String? marital; + String? eHealthIDField; Patientobject( {this.tempValue, - this.patientIdentificationType, - this.patientIdentificationNo, - this.mobileNumber, - this.patientOutSA, - this.firstNameN, - this.middleNameN, - this.lastNameN, - this.firstName, - this.middleName, - this.lastName, - this.strDateofBirth, - this.dateofBirth, - this.gender, - this.nationalityID, - this.dateofBirthN, - this.emailAddress, - this.sourceType, - this.preferredLanguage, - this.marital, - this.eHealthIDField}); + this.patientIdentificationType, + this.patientIdentificationNo, + this.mobileNumber, + this.patientOutSA, + this.firstNameN, + this.middleNameN, + this.lastNameN, + this.firstName, + this.middleName, + this.lastName, + this.strDateofBirth, + this.dateofBirth, + this.gender, + this.nationalityID, + this.dateofBirthN, + this.emailAddress, + this.sourceType, + this.preferredLanguage, + this.marital, + this.eHealthIDField}); Patientobject.fromJson(Map json) { tempValue = json['TempValue']; diff --git a/lib/core/model/PatientRegistration/SendActivationCodebyOTPNotificationTypeForRegistrationModel.dart b/lib/core/model/PatientRegistration/SendActivationCodebyOTPNotificationTypeForRegistrationModel.dart index 8244a95f..af08661f 100644 --- a/lib/core/model/PatientRegistration/SendActivationCodebyOTPNotificationTypeForRegistrationModel.dart +++ b/lib/core/model/PatientRegistration/SendActivationCodebyOTPNotificationTypeForRegistrationModel.dart @@ -1,54 +1,54 @@ class SendActivationCodeByOTPNotificationTypeForRegistrationModel { - int patientMobileNumber; - String mobileNo; - int projectOutSA; - int loginType; - String zipCode; - bool isRegister; - String logInTokenID; - int searchType; - int patientID; - int nationalID; - int patientIdentificationID; - int oTPSendType; - int languageID; - double versionID; - int channel; - String iPAdress; - String generalid; - int patientOutSA; + int? patientMobileNumber; + String? mobileNo; + int? projectOutSA; + int? loginType; + String? zipCode; + bool? isRegister; + String? logInTokenID; + int? searchType; + int? patientID; + int? nationalID; + int? patientIdentificationID; + int? oTPSendType; + int? languageID; + double? versionID; + int? channel; + String? iPAdress; + String? generalid; + int? patientOutSA; Null sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - String dOB; - int isHijri; - String healthId; + bool? isDentalAllowedBackend; + int? deviceTypeID; + String? dOB; + int? isHijri; + String? healthId; SendActivationCodeByOTPNotificationTypeForRegistrationModel( {this.patientMobileNumber, - this.mobileNo, - this.projectOutSA, - this.loginType, - this.zipCode, - this.isRegister, - this.logInTokenID, - this.searchType, - this.patientID, - this.nationalID, - this.patientIdentificationID, - this.oTPSendType, - this.languageID, - this.versionID, - this.channel, - this.iPAdress, - this.generalid, - this.patientOutSA, - this.sessionID, - this.isDentalAllowedBackend, - this.deviceTypeID, - this.dOB, - this.isHijri, - this.healthId}); + this.mobileNo, + this.projectOutSA, + this.loginType, + this.zipCode, + this.isRegister, + this.logInTokenID, + this.searchType, + this.patientID, + this.nationalID, + this.patientIdentificationID, + this.oTPSendType, + this.languageID, + this.versionID, + this.channel, + this.iPAdress, + this.generalid, + this.patientOutSA, + this.sessionID, + this.isDentalAllowedBackend, + this.deviceTypeID, + this.dOB, + this.isHijri, + this.healthId}); SendActivationCodeByOTPNotificationTypeForRegistrationModel.fromJson( Map json) { diff --git a/lib/core/model/Prescriptions/Prescriptions.dart b/lib/core/model/Prescriptions/Prescriptions.dart index c47a813a..af893503 100644 --- a/lib/core/model/Prescriptions/Prescriptions.dart +++ b/lib/core/model/Prescriptions/Prescriptions.dart @@ -1,77 +1,78 @@ import 'package:doctor_app_flutter/util/date-utils.dart'; class Prescriptions { - String setupID; - int projectID; - int patientID; - int appointmentNo; - String appointmentDate; - String doctorName; - String clinicDescription; - String name; - int episodeID; - int actualDoctorRate; - int admission; - int clinicID; - String companyName; - String despensedStatus; - DateTime dischargeDate; - int dischargeNo; - int doctorID; - String doctorImageURL; - int doctorRate; - String doctorTitle; - int gender; - String genderDescription; - bool isActiveDoctorProfile; - bool isDoctorAllowVedioCall; - bool isExecludeDoctor; - bool isInOutPatient; - bool isLiveCareAppointment; - String isInOutPatientDescription; - String isInOutPatientDescriptionN; - bool isInsurancePatient; - String nationalityFlagURL; - int noOfPatientsRate; - String qR; - List speciality; + String? setupID; + int? projectID; + int? patientID; + int? appointmentNo; + String? appointmentDate; + String? doctorName; + String? clinicDescription; + String? name; + int? episodeID; + int? actualDoctorRate; + int? admission; + int? clinicID; + String? companyName; + String? despensedStatus; + DateTime? dischargeDate; + int? dischargeNo; + int? doctorID; + String? doctorImageURL; + int? doctorRate; + String? doctorTitle; + int? gender; + String? genderDescription; + bool? isActiveDoctorProfile; + bool? isDoctorAllowVedioCall; + bool? isExecludeDoctor; + bool? isInOutPatient; + bool? isLiveCareAppointment; + String? isInOutPatientDescription; + String? isInOutPatientDescriptionN; + bool? isInsurancePatient; + String? nationalityFlagURL; + int? noOfPatientsRate; + String? qR; + List? speciality; Prescriptions( {this.setupID, - this.projectID, - this.patientID, - this.appointmentNo, - this.appointmentDate, - this.doctorName, - this.clinicDescription, - this.name, - this.episodeID, - this.actualDoctorRate, - this.admission, - this.clinicID, - this.companyName, - this.despensedStatus, - this.dischargeDate, - this.dischargeNo, - this.doctorID, - this.doctorImageURL, - this.doctorRate, - this.doctorTitle, - this.gender, - this.genderDescription, - this.isActiveDoctorProfile, - this.isDoctorAllowVedioCall, - this.isExecludeDoctor, - this.isInOutPatient, - this.isInOutPatientDescription, - this.isInOutPatientDescriptionN, - this.isInsurancePatient, - this.nationalityFlagURL, - this.noOfPatientsRate, - this.qR, - this.speciality,this.isLiveCareAppointment}); + this.projectID, + this.patientID, + this.appointmentNo, + this.appointmentDate, + this.doctorName, + this.clinicDescription, + this.name, + this.episodeID, + this.actualDoctorRate, + this.admission, + this.clinicID, + this.companyName, + this.despensedStatus, + this.dischargeDate, + this.dischargeNo, + this.doctorID, + this.doctorImageURL, + this.doctorRate, + this.doctorTitle, + this.gender, + this.genderDescription, + this.isActiveDoctorProfile, + this.isDoctorAllowVedioCall, + this.isExecludeDoctor, + this.isInOutPatient, + this.isInOutPatientDescription, + this.isInOutPatientDescriptionN, + this.isInsurancePatient, + this.nationalityFlagURL, + this.noOfPatientsRate, + this.qR, + this.speciality, + this.isLiveCareAppointment}); - Prescriptions.fromJson(Map json) { + Prescriptions.fromJson(Map json) { setupID = json['SetupID']; projectID = json['ProjectID']; patientID = json['PatientID']; @@ -105,11 +106,11 @@ class Prescriptions { noOfPatientsRate = json['NoOfPatientsRate']; qR = json['QR']; isLiveCareAppointment = json['IsLiveCareAppointment']; - // speciality = json['Speciality'].cast(); + // speciality = json['Speciality'].cast(); } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); data['SetupID'] = this.setupID; data['ProjectID'] = this.projectID; data['PatientID'] = this.patientID; @@ -149,10 +150,10 @@ class Prescriptions { } class PrescriptionsList { - String filterName = ""; - List prescriptionsList = List(); + String? filterName = ""; + List prescriptionsList =[]; - PrescriptionsList({this.filterName, Prescriptions prescriptions}) { + PrescriptionsList({this.filterName, required Prescriptions prescriptions}) { prescriptionsList.add(prescriptions); } } diff --git a/lib/core/model/Prescriptions/get_medication_for_inpatient_model.dart b/lib/core/model/Prescriptions/get_medication_for_inpatient_model.dart index 8ba07f2a..4644131e 100644 --- a/lib/core/model/Prescriptions/get_medication_for_inpatient_model.dart +++ b/lib/core/model/Prescriptions/get_medication_for_inpatient_model.dart @@ -1,40 +1,40 @@ class GetMedicationForInPatientModel { - String setupID; - int projectID; - int admissionNo; - int patientID; - int orderNo; - int prescriptionNo; - int lineItemNo; - String prescriptionDatetime; - int itemID; - int directionID; - int refillID; - String dose; - int unitofMeasurement; - String startDatetime; - String stopDatetime; - int noOfDoses; - int routeId; - String comments; - int reviewedPharmacist; + String? setupID; + int? projectID; + int? admissionNo; + int? patientID; + int? orderNo; + int? prescriptionNo; + int? lineItemNo; + String? prescriptionDatetime; + int? itemID; + int? directionID; + int? refillID; + String? dose; + int? unitofMeasurement; + String? startDatetime; + String? stopDatetime; + int? noOfDoses; + int? routeId; + String? comments; + int? reviewedPharmacist; dynamic reviewedPharmacistDatetime; dynamic discountinueDatetime; dynamic rescheduleDatetime; - int status; - String statusDescription; - int createdBy; - String createdOn; + int? status; + String? statusDescription; + int? createdBy; + String? createdOn; dynamic editedBy; dynamic editedOn; dynamic strength; - String pHRItemDescription; - String pHRItemDescriptionN; - String doctorName; - String uomDescription; - String routeDescription; - String directionDescription; - String refillDescription; + String? pHRItemDescription; + String? pHRItemDescriptionN; + String? doctorName; + String? uomDescription; + String? routeDescription; + String? directionDescription; + String? refillDescription; GetMedicationForInPatientModel( {this.setupID, diff --git a/lib/core/model/Prescriptions/get_medication_for_inpatient_request_model.dart b/lib/core/model/Prescriptions/get_medication_for_inpatient_request_model.dart index 7c906643..71c1305a 100644 --- a/lib/core/model/Prescriptions/get_medication_for_inpatient_request_model.dart +++ b/lib/core/model/Prescriptions/get_medication_for_inpatient_request_model.dart @@ -1,16 +1,16 @@ class GetMedicationForInPatientRequestModel { - bool isDentalAllowedBackend; - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int deviceTypeID; - String tokenID; - int patientID; - int admissionNo; - String sessionID; - int projectID; + bool? isDentalAllowedBackend; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? deviceTypeID; + String? tokenID; + int? patientID; + int? admissionNo; + String? sessionID; + int? projectID; GetMedicationForInPatientRequestModel( {this.isDentalAllowedBackend, diff --git a/lib/core/model/Prescriptions/in_patient_prescription_model.dart b/lib/core/model/Prescriptions/in_patient_prescription_model.dart index f6e88bf7..3f67e659 100644 --- a/lib/core/model/Prescriptions/in_patient_prescription_model.dart +++ b/lib/core/model/Prescriptions/in_patient_prescription_model.dart @@ -1,5 +1,5 @@ class InPatientPrescriptionRequestModel { - String vidaAuthTokenID; + String? vidaAuthTokenID; dynamic patientMRN; dynamic appNo; dynamic admissionNo; diff --git a/lib/core/model/Prescriptions/perscription_pharmacy.dart b/lib/core/model/Prescriptions/perscription_pharmacy.dart index 3adaef7e..c6b013d3 100644 --- a/lib/core/model/Prescriptions/perscription_pharmacy.dart +++ b/lib/core/model/Prescriptions/perscription_pharmacy.dart @@ -1,28 +1,28 @@ class PharmacyPrescriptions { - String expiryDate; + String? expiryDate; dynamic sellingPrice; - int quantity; - int itemID; - int locationID; - int projectID; - String setupID; - String locationDescription; - Null locationDescriptionN; - String itemDescription; - Null itemDescriptionN; - String alias; - int locationTypeID; - int barcode; - Null companybarcode; - int cityID; - String cityName; - int distanceInKilometers; - String latitude; - int locationType; - String longitude; - String phoneNumber; - String projectImageURL; - Null sortOrder; + int?quantity; + int?itemID; + int?locationID; + int?projectID; + String ?setupID; + String ?locationDescription; + dynamic locationDescriptionN; + String ? itemDescription; + dynamic itemDescriptionN; + String ? alias; + int ? locationTypeID; + int ? barcode; + dynamic companybarcode; + int ? cityID; + String? cityName; + int ? distanceInKilometers; + String? latitude; + int ?locationType; + String? longitude; + String ?phoneNumber; + String ? projectImageURL; + dynamic sortOrder; PharmacyPrescriptions( {this.expiryDate, diff --git a/lib/core/model/Prescriptions/post_prescrition_req_model.dart b/lib/core/model/Prescriptions/post_prescrition_req_model.dart index 06a524ed..9609a0df 100644 --- a/lib/core/model/Prescriptions/post_prescrition_req_model.dart +++ b/lib/core/model/Prescriptions/post_prescrition_req_model.dart @@ -1,10 +1,10 @@ class PostPrescriptionReqModel { - String vidaAuthTokenID; - int clinicID; - int episodeID; - int appointmentNo; - int patientMRN; - List prescriptionRequestModel; + String ?vidaAuthTokenID; + int? clinicID; + int? episodeID; + int? appointmentNo; + int? patientMRN; + List ?prescriptionRequestModel; PostPrescriptionReqModel( {this.vidaAuthTokenID, @@ -21,9 +21,9 @@ class PostPrescriptionReqModel { appointmentNo = json['AppointmentNo']; patientMRN = json['PatientMRN']; if (json['prescriptionRequestModel'] != null) { - prescriptionRequestModel = new List(); + prescriptionRequestModel =[]; json['prescriptionRequestModel'].forEach((v) { - prescriptionRequestModel.add(new PrescriptionRequestModel.fromJson(v)); + prescriptionRequestModel!.add(new PrescriptionRequestModel.fromJson(v)); }); } } @@ -37,25 +37,25 @@ class PostPrescriptionReqModel { data['PatientMRN'] = this.patientMRN; if (this.prescriptionRequestModel != null) { data['prescriptionRequestModel'] = - this.prescriptionRequestModel.map((v) => v.toJson()).toList(); + this.prescriptionRequestModel!.map((v) => v.toJson()).toList(); } return data; } } class PrescriptionRequestModel { - int itemId; - String doseStartDate; - int duration; - double dose; - int doseUnitId; - int route; - int frequency; - int doseTime; - bool covered; - bool approvalRequired; - String remarks; - String icdcode10Id; + int ? itemId; + String? doseStartDate; + int ?duration; + double? dose; + int ?doseUnitId; + int ?route; + int ?frequency; + int ?doseTime; + bool ?covered; + bool ?approvalRequired; + String ?remarks; + String ?icdcode10Id; PrescriptionRequestModel({ this.itemId, diff --git a/lib/core/model/Prescriptions/prescription_in_patient.dart b/lib/core/model/Prescriptions/prescription_in_patient.dart index c66bc8a4..0a3352a2 100644 --- a/lib/core/model/Prescriptions/prescription_in_patient.dart +++ b/lib/core/model/Prescriptions/prescription_in_patient.dart @@ -1,100 +1,100 @@ class PrescriotionInPatient { - int admissionNo; - int authorizedBy; + int ?admissionNo; + int ?authorizedBy; dynamic bedNo; - String comments; - int createdBy; - String createdByName; + String? comments; + int ?createdBy; + String ?createdByName; dynamic createdByNameN; - String createdOn; - String direction; - int directionID; + String ?createdOn; + String ?direction; + int ?directionID; dynamic directionN; - String dose; - int editedBy; + String ?dose; + int ?editedBy; dynamic iVDiluentLine; - int iVDiluentType; + int ?iVDiluentType; dynamic iVDiluentVolume; dynamic iVRate; dynamic iVStability; - String itemDescription; - int itemID; - int lineItemNo; - int locationId; - int noOfDoses; - int orderNo; - int patientID; - String pharmacyRemarks; - String prescriptionDatetime; - int prescriptionNo; - String processedBy; - int projectID; - int refillID; - String refillType; + String? itemDescription; + int? itemID; + int? lineItemNo; + int? locationId; + int? noOfDoses; + int? orderNo; + int? patientID; + String ?pharmacyRemarks; + String ?prescriptionDatetime; + int ?prescriptionNo; + String? processedBy; + int ?projectID; + int ?refillID; + String ?refillType; dynamic refillTypeN; - int reviewedPharmacist; + int ?reviewedPharmacist; dynamic roomId; - String route; - int routeId; + String ?route; + int ?routeId; dynamic routeN; dynamic setupID; - String startDatetime; - int status; - String statusDescription; + String ?startDatetime; + int ?status; + String ?statusDescription; dynamic statusDescriptionN; - String stopDatetime; - int unitofMeasurement; - String unitofMeasurementDescription; + String ?stopDatetime; + int ?unitofMeasurement; + String? unitofMeasurementDescription; dynamic unitofMeasurementDescriptionN; PrescriotionInPatient( {this.admissionNo, - this.authorizedBy, - this.bedNo, - this.comments, - this.createdBy, - this.createdByName, - this.createdByNameN, - this.createdOn, - this.direction, - this.directionID, - this.directionN, - this.dose, - this.editedBy, - this.iVDiluentLine, - this.iVDiluentType, - this.iVDiluentVolume, - this.iVRate, - this.iVStability, - this.itemDescription, - this.itemID, - this.lineItemNo, - this.locationId, - this.noOfDoses, - this.orderNo, - this.patientID, - this.pharmacyRemarks, - this.prescriptionDatetime, - this.prescriptionNo, - this.processedBy, - this.projectID, - this.refillID, - this.refillType, - this.refillTypeN, - this.reviewedPharmacist, - this.roomId, - this.route, - this.routeId, - this.routeN, - this.setupID, - this.startDatetime, - this.status, - this.statusDescription, - this.statusDescriptionN, - this.stopDatetime, - this.unitofMeasurement, - this.unitofMeasurementDescription, - this.unitofMeasurementDescriptionN}); + this.authorizedBy, + this.bedNo, + this.comments, + this.createdBy, + this.createdByName, + this.createdByNameN, + this.createdOn, + this.direction, + this.directionID, + this.directionN, + this.dose, + this.editedBy, + this.iVDiluentLine, + this.iVDiluentType, + this.iVDiluentVolume, + this.iVRate, + this.iVStability, + this.itemDescription, + this.itemID, + this.lineItemNo, + this.locationId, + this.noOfDoses, + this.orderNo, + this.patientID, + this.pharmacyRemarks, + this.prescriptionDatetime, + this.prescriptionNo, + this.processedBy, + this.projectID, + this.refillID, + this.refillType, + this.refillTypeN, + this.reviewedPharmacist, + this.roomId, + this.route, + this.routeId, + this.routeN, + this.setupID, + this.startDatetime, + this.status, + this.statusDescription, + this.statusDescriptionN, + this.stopDatetime, + this.unitofMeasurement, + this.unitofMeasurementDescription, + this.unitofMeasurementDescriptionN}); PrescriotionInPatient.fromJson(Map json) { admissionNo = json['AdmissionNo']; diff --git a/lib/core/model/Prescriptions/prescription_model.dart b/lib/core/model/Prescriptions/prescription_model.dart index 92574c66..99fe4532 100644 --- a/lib/core/model/Prescriptions/prescription_model.dart +++ b/lib/core/model/Prescriptions/prescription_model.dart @@ -1,5 +1,5 @@ class PrescriptionModel { - List entityList; + List? entityList; dynamic rowcount; dynamic statusMessage; @@ -7,9 +7,9 @@ class PrescriptionModel { PrescriptionModel.fromJson(Map json) { if (json['entityList'] != null) { - entityList = new List(); + entityList = []; json['entityList'].forEach((v) { - entityList.add(new EntityList.fromJson(v)); + entityList!.add(new EntityList.fromJson(v)); }); } rowcount = json['rowcount']; @@ -19,7 +19,7 @@ class PrescriptionModel { Map toJson() { final Map data = new Map(); if (this.entityList != null) { - data['entityList'] = this.entityList.map((v) => v.toJson()).toList(); + data['entityList'] = this.entityList!.map((v) => v.toJson()).toList(); } data['rowcount'] = this.rowcount; data['statusMessage'] = this.statusMessage; @@ -63,38 +63,38 @@ class EntityList { dynamic mediSpanGPICode; EntityList( {this.appointmentNo, - this.clinicName, - this.createdBy, - this.createdOn, - this.doctorName, - this.doseDailyQuantity, - this.doseDailyUnitID, - this.doseDetail, - this.doseDurationDays, - this.doseTimingID, - this.episodeID, - this.frequencyID, - this.icdCode10ID, - this.indication, - this.isDispensed, - this.isMedicineCovered, - this.isSIG, - this.medicationName, - this.medicationPrice, - this.medicineCode, - this.orderTypeDescription, - this.qty, - this.quantity, - this.remarks, - this.routeID, - this.startDate, - this.status, - this.stopDate, - this.uom, - this.pharmacistRemarks, - this.mediSpanGPICode, - this.pharmacyInervention, - this.refill}); + this.clinicName, + this.createdBy, + this.createdOn, + this.doctorName, + this.doseDailyQuantity, + this.doseDailyUnitID, + this.doseDetail, + this.doseDurationDays, + this.doseTimingID, + this.episodeID, + this.frequencyID, + this.icdCode10ID, + this.indication, + this.isDispensed, + this.isMedicineCovered, + this.isSIG, + this.medicationName, + this.medicationPrice, + this.medicineCode, + this.orderTypeDescription, + this.qty, + this.quantity, + this.remarks, + this.routeID, + this.startDate, + this.status, + this.stopDate, + this.uom, + this.pharmacistRemarks, + this.mediSpanGPICode, + this.pharmacyInervention, + this.refill}); EntityList.fromJson(Map json) { appointmentNo = json['appointmentNo']; diff --git a/lib/core/model/Prescriptions/prescription_report.dart b/lib/core/model/Prescriptions/prescription_report.dart index 006a6fad..4b5d574a 100644 --- a/lib/core/model/Prescriptions/prescription_report.dart +++ b/lib/core/model/Prescriptions/prescription_report.dart @@ -1,48 +1,48 @@ class PrescriptionReport { - String address; - dynamic appodynamicmentNo; - String clinic; - String companyName; - dynamic days; - String doctorName; + String? address; + dynamic? appodynamicmentNo; + String? clinic; + String? companyName; + dynamic? days; + String? doctorName; var doseDailyQuantity; - String frequency; - dynamic frequencyNumber; - String image; - String imageExtension; - String imageSRCUrl; - String imageString; - String imageThumbUrl; - String isCovered; - String itemDescription; - dynamic itemID; - String orderDate; - dynamic patientID; - String patientName; - String phoneOffice1; - String prescriptionQR; - dynamic prescriptionTimes; - String productImage; - String productImageBase64; - String productImageString; - dynamic projectID; - String projectName; - String remarks; - String route; - String sKU; - dynamic scaleOffset; - String startDate; + String? frequency; + dynamic? frequencyNumber; + String? image; + String? imageExtension; + String? imageSRCUrl; + String? imageString; + String? imageThumbUrl; + String? isCovered; + String? itemDescription; + dynamic? itemID; + String? orderDate; + dynamic? patientID; + String? patientName; + String? phoneOffice1; + String? prescriptionQR; + dynamic? prescriptionTimes; + String? productImage; + String? productImageBase64; + String? productImageString; + dynamic? projectID; + String? projectName; + String? remarks; + String? route; + String? sKU; + dynamic? scaleOffset; + String? startDate; - String patientAge; - String patientGender; - String phoneOffice; - dynamic doseTimingID; - dynamic frequencyID; - dynamic routeID; - String name; - String itemDescriptionN; - String routeN; - String frequencyN; + String? patientAge; + String? patientGender; + String? phoneOffice; + dynamic? doseTimingID; + dynamic? frequencyID; + dynamic? routeID; + String? name; + String? itemDescriptionN; + String? routeN; + String? frequencyN; PrescriptionReport({ this.address, diff --git a/lib/core/model/Prescriptions/prescription_report_enh.dart b/lib/core/model/Prescriptions/prescription_report_enh.dart index 01b9a5c9..96f811de 100644 --- a/lib/core/model/Prescriptions/prescription_report_enh.dart +++ b/lib/core/model/Prescriptions/prescription_report_enh.dart @@ -1,37 +1,38 @@ class PrescriptionReportEnh { - String address; + String ? address; dynamic appodynamicmentNo; - String clinic; + int ? appointmentNo; + String ? clinic; dynamic companyName; - dynamic days; - String doctorName; - dynamic doseDailyQuantity; - String frequency; - dynamic frequencyNumber; + int ? days; + String ? doctorName; + int ? doseDailyQuantity; + String ? frequency; + int ? frequencyNumber; dynamic image; dynamic imageExtension; - String imageSRCUrl; - dynamic imageString; - String imageThumbUrl; - String isCovered; - String itemDescription; - dynamic itemID; - String orderDate; - dynamic patientID; - String patientName; - String phoneOffice1; + String ? imageSRCUrl; + dynamic imageString ; + String ? imageThumbUrl; + String ? isCovered; + String ? itemDescription; + dynamic ? itemID; + String ? orderDate; + dynamic ? patientID; + String ? patientName; + String ? phoneOffice1; dynamic prescriptionQR; - dynamic prescriptionTimes; + dynamic ? prescriptionTimes; dynamic productImage; dynamic productImageBase64; - String productImageString; - dynamic projectID; - String projectName; - String remarks; - String route; - String sKU; - dynamic scaleOffset; - String startDate; + String ? productImageString; + dynamic ? projectID; + String ? projectName; + String ? remarks; + String ? route; + String ? sKU; + dynamic ? scaleOffset; + String ? startDate; PrescriptionReportEnh( {this.address, diff --git a/lib/core/model/Prescriptions/prescription_req_model.dart b/lib/core/model/Prescriptions/prescription_req_model.dart index a45878d8..1177431d 100644 --- a/lib/core/model/Prescriptions/prescription_req_model.dart +++ b/lib/core/model/Prescriptions/prescription_req_model.dart @@ -1,5 +1,5 @@ class PrescriptionReqModel { - String vidaAuthTokenID; + String ?vidaAuthTokenID; dynamic patientMRN; dynamic appNo; dynamic admissionNo; diff --git a/lib/core/model/Prescriptions/prescriptions_order.dart b/lib/core/model/Prescriptions/prescriptions_order.dart index f51420ec..0f69ffe5 100644 --- a/lib/core/model/Prescriptions/prescriptions_order.dart +++ b/lib/core/model/Prescriptions/prescriptions_order.dart @@ -1,32 +1,32 @@ import 'package:doctor_app_flutter/util/date-utils.dart'; class PrescriptionsOrder { - int iD; + int? iD; dynamic patientID; - bool patientOutSA; - bool isOutPatient; - int projectID; - int nearestProjectID; - double longitude; - double latitude; + bool? patientOutSA; + bool? isOutPatient; + int? projectID; + int? nearestProjectID; + double? longitude; + double? latitude; dynamic appointmentNo; dynamic dischargeID; - int lineItemNo; - int status; + int? lineItemNo; + int? status; dynamic description; dynamic descriptionN; - DateTime createdOn; - int serviceID; - int createdBy; - DateTime editedOn; - int editedBy; - int channel; + DateTime? createdOn; + int? serviceID; + int? createdBy; + DateTime? editedOn; + int? editedBy; + int? channel; dynamic clientRequestID; - bool returnedToQueue; + bool? returnedToQueue; dynamic pickupDateTime; dynamic pickupLocationName; dynamic dropoffLocationName; - int realRRTHaveTransactions; + int? realRRTHaveTransactions; dynamic nearestProjectDescription; dynamic nearestProjectDescriptionN; dynamic projectDescription; diff --git a/lib/core/model/Prescriptions/request_get_list_pharmacy_for_prescriptions.dart b/lib/core/model/Prescriptions/request_get_list_pharmacy_for_prescriptions.dart index 739bb838..7b453b9b 100644 --- a/lib/core/model/Prescriptions/request_get_list_pharmacy_for_prescriptions.dart +++ b/lib/core/model/Prescriptions/request_get_list_pharmacy_for_prescriptions.dart @@ -1,32 +1,32 @@ class RequestGetListPharmacyForPrescriptions { - int latitude; - int longitude; - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - String sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - int itemID; + int? latitude; + int? longitude; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; + String? sessionID; + bool? isDentalAllowedBackend; + int? deviceTypeID; + int? itemID; RequestGetListPharmacyForPrescriptions( {this.latitude, - this.longitude, - this.versionID, - this.channel, - this.languageID, - this.iPAdress, - this.generalid, - this.patientOutSA, - this.sessionID, - this.isDentalAllowedBackend, - this.deviceTypeID, - this.itemID}); + this.longitude, + this.versionID, + this.channel, + this.languageID, + this.iPAdress, + this.generalid, + this.patientOutSA, + this.sessionID, + this.isDentalAllowedBackend, + this.deviceTypeID, + this.itemID}); - RequestGetListPharmacyForPrescriptions.fromJson(Map json) { + RequestGetListPharmacyForPrescriptions.fromJson(Map json) { latitude = json['Latitude']; longitude = json['Longitude']; versionID = json['VersionID']; diff --git a/lib/core/model/Prescriptions/request_prescription_report.dart b/lib/core/model/Prescriptions/request_prescription_report.dart index c8323740..91e49e3c 100644 --- a/lib/core/model/Prescriptions/request_prescription_report.dart +++ b/lib/core/model/Prescriptions/request_prescription_report.dart @@ -1,23 +1,23 @@ class RequestPrescriptionReport { - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - String sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - int patientID; - String tokenID; - int patientTypeID; - int patientType; - int appointmentNo; - String setupID; - int episodeID; - int clinicID; - int projectID; - int dischargeNo; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; + String? sessionID; + bool? isDentalAllowedBackend; + int? deviceTypeID; + int? patientID; + String? tokenID; + int? patientTypeID; + int? patientType; + int? appointmentNo; + String? setupID; + int? episodeID; + int? clinicID; + int? projectID; + int? dischargeNo; RequestPrescriptionReport( {this.versionID, @@ -40,7 +40,7 @@ class RequestPrescriptionReport { this.projectID, this.dischargeNo}); - RequestPrescriptionReport.fromJson(Map json) { + RequestPrescriptionReport.fromJson(Map json) { versionID = json['VersionID']; channel = json['Channel']; languageID = json['LanguageID']; diff --git a/lib/core/model/Prescriptions/request_prescription_report_enh.dart b/lib/core/model/Prescriptions/request_prescription_report_enh.dart index 4905fc2a..07297648 100644 --- a/lib/core/model/Prescriptions/request_prescription_report_enh.dart +++ b/lib/core/model/Prescriptions/request_prescription_report_enh.dart @@ -1,23 +1,23 @@ class RequestPrescriptionReportEnh { - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - String sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - int patientID; - String tokenID; - int patientTypeID; - int patientType; - int appointmentNo; - String setupID; - int dischargeNo; - int episodeID; - int clinicID; - int projectID; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; + String? sessionID; + bool? isDentalAllowedBackend; + int? deviceTypeID; + int? patientID; + String? tokenID; + int? patientTypeID; + int? patientType; + int? appointmentNo; + String? setupID; + int? dischargeNo; + int? episodeID; + int? clinicID; + int? projectID; RequestPrescriptionReportEnh( {this.versionID, @@ -37,9 +37,10 @@ class RequestPrescriptionReportEnh { this.setupID, this.episodeID, this.clinicID, - this.projectID,this.dischargeNo}); + this.projectID, + this.dischargeNo}); - RequestPrescriptionReportEnh.fromJson(Map json) { + RequestPrescriptionReportEnh.fromJson(Map json) { versionID = json['VersionID']; channel = json['Channel']; languageID = json['LanguageID']; diff --git a/lib/core/model/admissionRequest/admission-request.dart b/lib/core/model/admissionRequest/admission-request.dart index 1ab5a990..94fe46cc 100644 --- a/lib/core/model/admissionRequest/admission-request.dart +++ b/lib/core/model/admissionRequest/admission-request.dart @@ -1,45 +1,45 @@ class AdmissionRequest { - int patientMRN; - int admitToClinic; - bool isPregnant; - int pregnancyWeeks; - int pregnancyType; - int noOfBabies; - int mrpDoctorID; - String admissionDate; - int expectedDays; - int admissionType; - int admissionLocationID; - int roomCategoryID; - int wardID; - bool isSickLeaveRequired; - String sickLeaveComments; - bool isTransport; - String transportComments; - bool isPhysioAppointmentNeeded; - String physioAppointmentComments; - bool isOPDFollowupAppointmentNeeded; - String opdFollowUpComments; - bool isDietType; - int dietType; - String dietRemarks; - bool isPhysicalActivityModification; - String physicalActivityModificationComments; - int orStatus; - String mainLineOfTreatment; - int estimatedCost; - String elementsForImprovement; - bool isPackagePatient; - String complications; - String otherDepartmentInterventions; - String otherProcedures; - String pastMedicalHistory; - String pastSurgicalHistory; - List admissionRequestDiagnoses; - List admissionRequestProcedures; - int appointmentNo; - int episodeID; - int admissionRequestNo; + late int? patientMRN; + late int? admitToClinic; + late bool? isPregnant; + late int pregnancyWeeks; + late int pregnancyType; + late int noOfBabies; + late int? mrpDoctorID; + late String? admissionDate; + late int? expectedDays; + late int? admissionType; + late int admissionLocationID; + late int roomCategoryID; + late int? wardID; + late bool? isSickLeaveRequired; + late String sickLeaveComments; + late bool isTransport; + late String transportComments; + late bool isPhysioAppointmentNeeded; + late String physioAppointmentComments; + late bool isOPDFollowupAppointmentNeeded; + late String opdFollowUpComments; + late bool? isDietType; + late int? dietType; + late String? dietRemarks; + late bool isPhysicalActivityModification; + late String physicalActivityModificationComments; + late int orStatus; + late String? mainLineOfTreatment; + late int? estimatedCost; + late String? elementsForImprovement; + late bool isPackagePatient; + late String complications; + late String otherDepartmentInterventions; + late String otherProcedures; + late String pastMedicalHistory; + late String pastSurgicalHistory; + late List? admissionRequestDiagnoses; + late List? admissionRequestProcedures; + late int? appointmentNo; + late int? episodeID; + late int? admissionRequestNo; AdmissionRequest( {this.patientMRN, @@ -110,8 +110,7 @@ class AdmissionRequest { dietType = json['dietType']; dietRemarks = json['dietRemarks']; isPhysicalActivityModification = json['isPhysicalActivityModification']; - physicalActivityModificationComments = - json['physicalActivityModificationComments']; + physicalActivityModificationComments = json['physicalActivityModificationComments']; orStatus = json['orStatus']; mainLineOfTreatment = json['mainLineOfTreatment']; estimatedCost = json['estimatedCost']; @@ -123,17 +122,17 @@ class AdmissionRequest { pastMedicalHistory = json['pastMedicalHistory']; pastSurgicalHistory = json['pastSurgicalHistory']; if (json['admissionRequestDiagnoses'] != null) { - admissionRequestDiagnoses = new List(); + admissionRequestDiagnoses = []; json['admissionRequestDiagnoses'].forEach((v) { - admissionRequestDiagnoses.add(v); + admissionRequestDiagnoses!.add(v); // admissionRequestDiagnoses // .add(new AdmissionRequestDiagnoses.fromJson(v)); }); } if (json['admissionRequestProcedures'] != null) { - admissionRequestProcedures = new List(); + admissionRequestProcedures = []; json['admissionRequestProcedures'].forEach((v) { - admissionRequestProcedures.add(v); + admissionRequestProcedures!.add(v); // admissionRequestProcedures // .add(new AdmissionRequestProcedures.fromJson(v)); }); @@ -164,16 +163,13 @@ class AdmissionRequest { data['transportComments'] = this.transportComments; data['isPhysioAppointmentNeeded'] = this.isPhysioAppointmentNeeded; data['physioAppointmentComments'] = this.physioAppointmentComments; - data['isOPDFollowupAppointmentNeeded'] = - this.isOPDFollowupAppointmentNeeded; + data['isOPDFollowupAppointmentNeeded'] = this.isOPDFollowupAppointmentNeeded; data['opdFollowUpComments'] = this.opdFollowUpComments; data['isDietType'] = this.isDietType; data['dietType'] = this.dietType; data['dietRemarks'] = this.dietRemarks; - data['isPhysicalActivityModification'] = - this.isPhysicalActivityModification; - data['physicalActivityModificationComments'] = - this.physicalActivityModificationComments; + data['isPhysicalActivityModification'] = this.isPhysicalActivityModification; + data['physicalActivityModificationComments'] = this.physicalActivityModificationComments; data['orStatus'] = this.orStatus; data['mainLineOfTreatment'] = this.mainLineOfTreatment; data['estimatedCost'] = this.estimatedCost; @@ -189,8 +185,7 @@ class AdmissionRequest { // this.admissionRequestDiagnoses.map((v) => v.toJson()).toList(); } if (this.admissionRequestProcedures != null) { - data['admissionRequestProcedures'] = - this.admissionRequestProcedures.map((v) => v.toJson()).toList(); + data['admissionRequestProcedures'] = this.admissionRequestProcedures!.map((v) => v.toJson()).toList(); } data['appointmentNo'] = this.appointmentNo; data['episodeID'] = this.episodeID; diff --git a/lib/core/model/admissionRequest/clinic-model.dart b/lib/core/model/admissionRequest/clinic-model.dart index 05d34645..e5a03264 100644 --- a/lib/core/model/admissionRequest/clinic-model.dart +++ b/lib/core/model/admissionRequest/clinic-model.dart @@ -1,16 +1,16 @@ class Clinic { - int clinicGroupID; - String clinicGroupName; - int clinicID; - String clinicNameArabic; - String clinicNameEnglish; + late int? clinicGroupID; + late String? clinicGroupName; + late int? clinicID; + late String? clinicNameArabic; + late String? clinicNameEnglish; Clinic( {this.clinicGroupID, - this.clinicGroupName, - this.clinicID, - this.clinicNameArabic, - this.clinicNameEnglish}); + this.clinicGroupName, + this.clinicID, + this.clinicNameArabic, + this.clinicNameEnglish}); Clinic.fromJson(Map json) { clinicGroupID = json['clinicGroupID']; @@ -29,5 +29,4 @@ class Clinic { data['clinicNameEnglish'] = this.clinicNameEnglish; return data; } - -} \ No newline at end of file +} diff --git a/lib/core/model/admissionRequest/ward-model.dart b/lib/core/model/admissionRequest/ward-model.dart index 606758d3..8f7b9fe5 100644 --- a/lib/core/model/admissionRequest/ward-model.dart +++ b/lib/core/model/admissionRequest/ward-model.dart @@ -1,9 +1,9 @@ class WardModel{ - String description; - String descriptionN; - int floorID; - bool isActive; + late String ? description; + late String ? descriptionN; + late int ? floorID; + late bool ? isActive; WardModel( {this.description, this.descriptionN, this.floorID, this.isActive}); diff --git a/lib/core/model/auth/activation_Code_req_model.dart b/lib/core/model/auth/activation_Code_req_model.dart index 85d7f1d3..13d64f6a 100644 --- a/lib/core/model/auth/activation_Code_req_model.dart +++ b/lib/core/model/auth/activation_Code_req_model.dart @@ -1,12 +1,12 @@ class ActivationCodeModel { - int channel; - int languageID; - int loginDoctorID; - double versionID; - int memberID; - int facilityId; - String generalid; - String otpSendType; + late int? channel; + late int? loginDoctorID; + late int? languageID; + late double? versionID; + late int? memberID; + late int? facilityId; + late String? generalid; + late String? otpSendType; ActivationCodeModel( {this.channel, diff --git a/lib/core/model/auth/activation_code_for_verification_screen_model.dart b/lib/core/model/auth/activation_code_for_verification_screen_model.dart index dae31f8c..51fb5ab3 100644 --- a/lib/core/model/auth/activation_code_for_verification_screen_model.dart +++ b/lib/core/model/auth/activation_code_for_verification_screen_model.dart @@ -1,18 +1,19 @@ class ActivationCodeForVerificationScreenModel { - int oTPSendType; - String mobileNumber; - String zipCode; - int channel; - int loginDoctorID; - int languageID; - double versionID; - int memberID; - int facilityId; - String generalid; - int isMobileFingerPrint; - String vidaAuthTokenID; - String vidaRefreshTokenID; - String iMEI; + late int? oTPSendType; + late String? mobileNumber; + late String? zipCode; + late int? channel; + late int? loginDoctorID; + late int? languageID; + late double? versionID; + late int? memberID; + late int? facilityId; + late String? generalid; + late int? isMobileFingerPrint; + late String? vidaAuthTokenID; + late String? vidaRefreshTokenID; + late String? iMEI; + ActivationCodeForVerificationScreenModel( {this.oTPSendType, this.mobileNumber, diff --git a/lib/core/model/auth/check_activation_code_for_doctor_app_response_model.dart b/lib/core/model/auth/check_activation_code_for_doctor_app_response_model.dart index e39518e6..3fa2f69b 100644 --- a/lib/core/model/auth/check_activation_code_for_doctor_app_response_model.dart +++ b/lib/core/model/auth/check_activation_code_for_doctor_app_response_model.dart @@ -1,12 +1,12 @@ import 'package:doctor_app_flutter/models/doctor/doctor_profile_model.dart'; class CheckActivationCodeForDoctorAppResponseModel { - String authenticationTokenID; - List listDoctorsClinic; - List listDoctorProfile; - MemberInformation memberInformation; - String vidaAuthTokenID; - String vidaRefreshTokenID; + late String? authenticationTokenID; + late List? listDoctorsClinic; + List? listDoctorProfile; + late MemberInformation? memberInformation; + String? vidaAuthTokenID; + String? vidaRefreshTokenID; CheckActivationCodeForDoctorAppResponseModel( {this.authenticationTokenID, @@ -20,16 +20,16 @@ class CheckActivationCodeForDoctorAppResponseModel { Map json) { authenticationTokenID = json['AuthenticationTokenID']; if (json['List_DoctorsClinic'] != null) { - listDoctorsClinic = new List(); + listDoctorsClinic = []; json['List_DoctorsClinic'].forEach((v) { - listDoctorsClinic.add(new ListDoctorsClinic.fromJson(v)); + listDoctorsClinic!.add(new ListDoctorsClinic.fromJson(v)); }); } if (json['List_DoctorProfile'] != null) { - listDoctorProfile = new List(); + listDoctorProfile = []; json['List_DoctorProfile'].forEach((v) { - listDoctorProfile.add(new DoctorProfileModel.fromJson(v)); + listDoctorProfile!.add(new DoctorProfileModel.fromJson(v)); }); } vidaAuthTokenID = json['VidaAuthTokenID']; @@ -45,27 +45,27 @@ class CheckActivationCodeForDoctorAppResponseModel { data['AuthenticationTokenID'] = this.authenticationTokenID; if (this.listDoctorsClinic != null) { data['List_DoctorsClinic'] = - this.listDoctorsClinic.map((v) => v.toJson()).toList(); + this.listDoctorsClinic!.map((v) => v.toJson()).toList(); } if (this.listDoctorProfile != null) { data['List_DoctorProfile'] = - this.listDoctorProfile.map((v) => v.toJson()).toList(); + this.listDoctorProfile!.map((v) => v.toJson()).toList(); } if (this.memberInformation != null) { - data['memberInformation'] = this.memberInformation.toJson(); + data['memberInformation'] = this.memberInformation!.toJson(); } return data; } } class ListDoctorsClinic { - Null setupID; - int projectID; - int doctorID; - int clinicID; - bool isActive; - String clinicName; + late dynamic setupID; + late int? projectID; + late int? doctorID; + late int? clinicID; + late bool? isActive; + late String? clinicName; ListDoctorsClinic( {this.setupID, @@ -97,15 +97,15 @@ class ListDoctorsClinic { } class MemberInformation { - List clinics; - int doctorId; - String email; - int employeeId; - int memberId; - Null memberName; - Null memberNameArabic; - String preferredLanguage; - List roles; + late List? clinics; + late int? doctorId; + late String? email; + late int? employeeId; + late int? memberId; + late dynamic memberName; + late dynamic memberNameArabic; + late String? preferredLanguage; + late List? roles; MemberInformation( {this.clinics, @@ -120,9 +120,9 @@ class MemberInformation { MemberInformation.fromJson(Map json) { if (json['clinics'] != null) { - clinics = new List(); + clinics = []; json['clinics'].forEach((v) { - clinics.add(new Clinics.fromJson(v)); + clinics!.add(new Clinics.fromJson(v)); }); } doctorId = json['doctorId']; @@ -133,9 +133,9 @@ class MemberInformation { memberNameArabic = json['memberNameArabic']; preferredLanguage = json['preferredLanguage']; if (json['roles'] != null) { - roles = new List(); + roles = []; json['roles'].forEach((v) { - roles.add(new Roles.fromJson(v)); + roles!.add(new Roles.fromJson(v)); }); } } @@ -143,7 +143,7 @@ class MemberInformation { Map toJson() { final Map data = new Map(); if (this.clinics != null) { - data['clinics'] = this.clinics.map((v) => v.toJson()).toList(); + data['clinics'] = this.clinics!.map((v) => v.toJson()).toList(); } data['doctorId'] = this.doctorId; data['email'] = this.email; @@ -153,16 +153,16 @@ class MemberInformation { data['memberNameArabic'] = this.memberNameArabic; data['preferredLanguage'] = this.preferredLanguage; if (this.roles != null) { - data['roles'] = this.roles.map((v) => v.toJson()).toList(); + data['roles'] = this.roles!.map((v) => v.toJson()).toList(); } return data; } } class Clinics { - bool defaultClinic; - int id; - String name; + late bool? defaultClinic; + late int? id; + late String? name; Clinics({this.defaultClinic, this.id, this.name}); @@ -182,8 +182,8 @@ class Clinics { } class Roles { - String name; - int roleId; + late String? name; + late int? roleId; Roles({this.name, this.roleId}); diff --git a/lib/core/model/auth/check_activation_code_request_model.dart b/lib/core/model/auth/check_activation_code_request_model.dart index 94502a71..fee596fe 100644 --- a/lib/core/model/auth/check_activation_code_request_model.dart +++ b/lib/core/model/auth/check_activation_code_request_model.dart @@ -1,24 +1,24 @@ class CheckActivationCodeRequestModel { - String mobileNumber; - String zipCode; - int doctorID; - int memberID; - int loginDoctorID; - String password; - String facilityId; - String iPAdress; - int channel; - int languageID; - int projectID; - double versionID; - String generalid; - String logInTokenID; - String activationCode; - String vidaAuthTokenID; - String vidaRefreshTokenID; - String iMEI; - bool isForSilentLogin; - int oTPSendType; + String? mobileNumber; + String? zipCode; + int? doctorID; + int? memberID; + int? loginDoctorID; + String? password; + String? facilityId; + String? iPAdress; + int? channel; + int? languageID; + int? projectID; + double? versionID; + String? generalid; + String? logInTokenID; + String? activationCode; + String? vidaAuthTokenID; + String? vidaRefreshTokenID; + String? iMEI; + bool? isForSilentLogin; + int? oTPSendType; CheckActivationCodeRequestModel( {this.mobileNumber, this.zipCode, diff --git a/lib/core/model/auth/imei_details.dart b/lib/core/model/auth/imei_details.dart index eb37e736..95ff1e74 100644 --- a/lib/core/model/auth/imei_details.dart +++ b/lib/core/model/auth/imei_details.dart @@ -1,33 +1,34 @@ class GetIMEIDetailsModel { - int iD; - String iMEI; - int logInTypeID; - bool outSA; - String mobile; - dynamic identificationNo; - int doctorID; - String doctorName; - String doctorNameN; - int clinicID; - String clinicDescription; - dynamic clinicDescriptionN; - int projectID; - String projectName; - String genderDescription; - dynamic genderDescriptionN; - String titleDescription; - dynamic titleDescriptionN; - dynamic zipCode; - String createdOn; - dynamic createdBy; - String editedOn; - dynamic editedBy; - bool biometricEnabled; - dynamic preferredLanguage; - bool isActive; - String vidaAuthTokenID; - String vidaRefreshTokenID; - String password; + late int? iD; + late String? iMEI; + late int? logInTypeID; + late bool? outSA; + late String? mobile; + late dynamic identificationNo; + late int? doctorID; + late String? doctorName; + late String? doctorNameN; + late int? clinicID; + late String? clinicDescription; + late dynamic clinicDescriptionN; + late int? projectID; + late String? projectName; + late String? genderDescription; + late dynamic genderDescriptionN; + late String? titleDescription; + late dynamic titleDescriptionN; + late dynamic zipCode; + late String? createdOn; + late dynamic createdBy; + late String? editedOn; + late dynamic editedBy; + late bool? biometricEnabled; + late dynamic preferredLanguage; + late bool? isActive; + late String? vidaAuthTokenID; + late String? vidaRefreshTokenID; + late String? password; + GetIMEIDetailsModel( {this.iD, this.iMEI, diff --git a/lib/core/model/auth/insert_imei_model.dart b/lib/core/model/auth/insert_imei_model.dart index 25e22b7a..5e54b127 100644 --- a/lib/core/model/auth/insert_imei_model.dart +++ b/lib/core/model/auth/insert_imei_model.dart @@ -1,37 +1,37 @@ class InsertIMEIDetailsModel { - String iMEI; - int logInTypeID; - dynamic outSA; - String mobile; - dynamic identificationNo; - int doctorID; - String doctorName; - String doctorNameN; - int clinicID; - String clinicDescription; - Null clinicDescriptionN; - String projectName; - String genderDescription; - Null genderDescriptionN; - String titleDescription; - Null titleDescriptionN; - bool bioMetricEnabled; - Null preferredLanguage; - bool isActive; - int editedBy; - int projectID; - String tokenID; - int languageID; - String stamp; - String iPAdress; - double versionID; - int channel; - String sessionID; - bool isLoginForDoctorApp; - int patientOutSA; - String vidaAuthTokenID; - String vidaRefreshTokenID; - dynamic password; + late String? iMEI; + late int ?logInTypeID; + late dynamic outSA; + late String? mobile; + late dynamic identificationNo; + late int ?doctorID; + late String? doctorName; + late String ?doctorNameN; + late int ?clinicID; + late String ?clinicDescription; + late dynamic clinicDescriptionN; + late String ?projectName; + late String ?genderDescription; + late dynamic genderDescriptionN; + late String ?titleDescription; + late dynamic titleDescriptionN; + late bool ?bioMetricEnabled; + late dynamic preferredLanguage; + late bool ?isActive; + late int ?editedBy; + late int ?projectID; + late String ?tokenID; + late int ?languageID; + late String ?stamp; + late String ?iPAdress; + late double ?versionID; + late int ?channel; + late String ?sessionID; + late bool ?isLoginForDoctorApp; + late int ?patientOutSA; + late String ?vidaAuthTokenID; + late String ?vidaRefreshTokenID; + late dynamic password; InsertIMEIDetailsModel( {this.iMEI, this.logInTypeID, diff --git a/lib/core/model/auth/new_login_information_response_model.dart b/lib/core/model/auth/new_login_information_response_model.dart index 117060e4..c834580b 100644 --- a/lib/core/model/auth/new_login_information_response_model.dart +++ b/lib/core/model/auth/new_login_information_response_model.dart @@ -1,13 +1,13 @@ class NewLoginInformationModel { - int doctorID; - List listMemberInformation; - String logInTokenID; - String mobileNumber; - Null sELECTDeviceIMEIbyIMEIList; - int userID; - String zipCode; - bool isActiveCode; - bool isSMSSent; + late int? doctorID; + late List? listMemberInformation; + late String ?logInTokenID; + late String ?mobileNumber; + late dynamic sELECTDeviceIMEIbyIMEIList; + late int ?userID; + late String ?zipCode; + late bool ?isActiveCode; + late bool ?isSMSSent; NewLoginInformationModel( {this.doctorID, @@ -23,9 +23,9 @@ class NewLoginInformationModel { NewLoginInformationModel.fromJson(Map json) { doctorID = json['DoctorID']; if (json['List_MemberInformation'] != null) { - listMemberInformation = new List(); + listMemberInformation = []; json['List_MemberInformation'].forEach((v) { - listMemberInformation.add(new ListMemberInformation.fromJson(v)); + listMemberInformation!.add(new ListMemberInformation.fromJson(v)); }); } logInTokenID = json['LogInTokenID']; @@ -42,7 +42,7 @@ class NewLoginInformationModel { data['DoctorID'] = this.doctorID; if (this.listMemberInformation != null) { data['List_MemberInformation'] = - this.listMemberInformation.map((v) => v.toJson()).toList(); + this.listMemberInformation!.map((v) => v.toJson()).toList(); } data['LogInTokenID'] = this.logInTokenID; data['MobileNumber'] = this.mobileNumber; @@ -56,17 +56,17 @@ class NewLoginInformationModel { } class ListMemberInformation { - Null setupID; - int memberID; - String memberName; - Null memberNameN; - String preferredLang; - String pIN; - String saltHash; - int referenceID; - int employeeID; - int roleID; - int projectid; + late dynamic setupID; + late int ? memberID; + late String ? memberName; + late dynamic memberNameN; + late String ? preferredLang; + late String ? pIN; + late String ? saltHash; + late int ? referenceID; + late int ? employeeID; + late int ? roleID; + late int ? projectid; ListMemberInformation( {this.setupID, diff --git a/lib/core/model/auth/send_activation_code_for_doctor_app_response_model.dart b/lib/core/model/auth/send_activation_code_for_doctor_app_response_model.dart index ceaf4c65..db971954 100644 --- a/lib/core/model/auth/send_activation_code_for_doctor_app_response_model.dart +++ b/lib/core/model/auth/send_activation_code_for_doctor_app_response_model.dart @@ -1,8 +1,8 @@ class SendActivationCodeForDoctorAppResponseModel { - String logInTokenID; - String verificationCode; - String vidaAuthTokenID; - String vidaRefreshTokenID; + String? logInTokenID; + String? verificationCode; + String? vidaAuthTokenID; + String? vidaRefreshTokenID; SendActivationCodeForDoctorAppResponseModel( {this.logInTokenID, diff --git a/lib/core/model/calculate_box_request_model.dart b/lib/core/model/calculate_box_request_model.dart index 80281854..24e75bb7 100644 --- a/lib/core/model/calculate_box_request_model.dart +++ b/lib/core/model/calculate_box_request_model.dart @@ -1,9 +1,9 @@ class CalculateBoxQuantityRequestModel { - int itemCode; - double strength; - int frequency; - int duration; - String vidaAuthTokenID; + int? itemCode; + double? strength; + int? frequency; + int? duration; + String? vidaAuthTokenID; CalculateBoxQuantityRequestModel( {this.itemCode, diff --git a/lib/core/model/diabetic_chart/DiabeticType.dart b/lib/core/model/diabetic_chart/DiabeticType.dart index 26641e61..8a9cfbe1 100644 --- a/lib/core/model/diabetic_chart/DiabeticType.dart +++ b/lib/core/model/diabetic_chart/DiabeticType.dart @@ -1,7 +1,7 @@ class DiabeticType { - int value; - String nameEn; - String nameAr; + int? value; + String? nameEn; + String? nameAr; DiabeticType({this.value, this.nameEn, this.nameAr}); diff --git a/lib/core/model/diabetic_chart/GetDiabeticChartValuesRequestModel.dart b/lib/core/model/diabetic_chart/GetDiabeticChartValuesRequestModel.dart index 7fad3106..3adc2761 100644 --- a/lib/core/model/diabetic_chart/GetDiabeticChartValuesRequestModel.dart +++ b/lib/core/model/diabetic_chart/GetDiabeticChartValuesRequestModel.dart @@ -1,12 +1,12 @@ class GetDiabeticChartValuesRequestModel { - int deviceTypeID; - int patientID; - int resultType; - int admissionNo; - String setupID; - bool patientOutSA; - int patientType; - int patientTypeID; + int? deviceTypeID; + int? patientID; + int? resultType; + int? admissionNo; + String? setupID; + bool? patientOutSA; + int? patientType; + int? patientTypeID; GetDiabeticChartValuesRequestModel( {this.deviceTypeID, diff --git a/lib/core/model/diabetic_chart/GetDiabeticChartValuesResponseModel.dart b/lib/core/model/diabetic_chart/GetDiabeticChartValuesResponseModel.dart index fa2c1ca2..82c10f5e 100644 --- a/lib/core/model/diabetic_chart/GetDiabeticChartValuesResponseModel.dart +++ b/lib/core/model/diabetic_chart/GetDiabeticChartValuesResponseModel.dart @@ -1,10 +1,10 @@ class GetDiabeticChartValuesResponseModel { - String resultType; - int admissionNo; - String dateChart; - int resultValue; - int createdBy; - String createdOn; + String? resultType; + int? admissionNo; + String? dateChart; + int? resultValue; + int? createdBy; + String? createdOn; GetDiabeticChartValuesResponseModel( {this.resultType, diff --git a/lib/core/model/diagnosis/GetDiagnosisForInPatientRequestModel.dart b/lib/core/model/diagnosis/GetDiagnosisForInPatientRequestModel.dart index 310cfb50..c164d634 100644 --- a/lib/core/model/diagnosis/GetDiagnosisForInPatientRequestModel.dart +++ b/lib/core/model/diagnosis/GetDiagnosisForInPatientRequestModel.dart @@ -1,9 +1,9 @@ class GetDiagnosisForInPatientRequestModel { - int patientID; - int admissionNo; - String setupID; - int patientType; - int patientTypeID; + int? patientID; + int? admissionNo; + String? setupID; + int? patientType; + int? patientTypeID; GetDiagnosisForInPatientRequestModel( {this.patientID, diff --git a/lib/core/model/diagnosis/GetDiagnosisForInPatientResponseModel.dart b/lib/core/model/diagnosis/GetDiagnosisForInPatientResponseModel.dart index 1ec48964..1996fd6a 100644 --- a/lib/core/model/diagnosis/GetDiagnosisForInPatientResponseModel.dart +++ b/lib/core/model/diagnosis/GetDiagnosisForInPatientResponseModel.dart @@ -1,15 +1,15 @@ class GetDiagnosisForInPatientResponseModel { - String iCDCode10ID; - int diagnosisTypeID; - int conditionID; - bool complexDiagnosis; - String asciiDesc; - int createdBy; - String createdOn; - int editedBy; - String editedOn; - String createdByName; - String editedByName; + String? iCDCode10ID; + int? diagnosisTypeID; + int? conditionID; + bool? complexDiagnosis; + String? asciiDesc; + int? createdBy; + String? createdOn; + int? editedBy; + String? editedOn; + String? createdByName; + String? editedByName; GetDiagnosisForInPatientResponseModel( {this.iCDCode10ID, diff --git a/lib/core/model/hospitals/get_hospitals_request_model.dart b/lib/core/model/hospitals/get_hospitals_request_model.dart index 8a5f1bc1..550f8ca8 100644 --- a/lib/core/model/hospitals/get_hospitals_request_model.dart +++ b/lib/core/model/hospitals/get_hospitals_request_model.dart @@ -1,13 +1,13 @@ class GetHospitalsRequestModel { - int languageID; - String stamp; - String iPAdress; - double versionID; - int channel; - String tokenID; - String sessionID; - bool isLoginForDoctorApp; - String memberID; + int ?languageID; + String? stamp; + String? iPAdress; + double? versionID; + int ?channel; + String? tokenID; + String? sessionID; + bool ?isLoginForDoctorApp; + String ?memberID; GetHospitalsRequestModel( {this.languageID, diff --git a/lib/core/model/hospitals/get_hospitals_response_model.dart b/lib/core/model/hospitals/get_hospitals_response_model.dart index edbc3fe5..1109b58b 100644 --- a/lib/core/model/hospitals/get_hospitals_response_model.dart +++ b/lib/core/model/hospitals/get_hospitals_response_model.dart @@ -1,7 +1,7 @@ class GetHospitalsResponseModel { - String facilityGroupId; - int facilityId; - String facilityName; + String? facilityGroupId; + int ?facilityId; + String ?facilityName; GetHospitalsResponseModel( {this.facilityGroupId, this.facilityId, this.facilityName}); diff --git a/lib/core/model/hospitals_model.dart b/lib/core/model/hospitals_model.dart index b09807d6..d896b939 100644 --- a/lib/core/model/hospitals_model.dart +++ b/lib/core/model/hospitals_model.dart @@ -1,20 +1,20 @@ class HospitalsModel { - String desciption; + String? desciption; dynamic desciptionN; - int iD; - String legalName; - String legalNameN; - String name; + int? iD; + String? legalName; + String? legalNameN; + String? name; dynamic nameN; - String phoneNumber; - String setupID; - int distanceInKilometers; - bool isActive; - String latitude; - String longitude; - int mainProjectID; + String? phoneNumber; + String? setupID; + int? distanceInKilometers; + bool ?isActive; + String? latitude; + String? longitude; + int? mainProjectID; dynamic projectOutSA; - bool usingInDoctorApp; + bool ?usingInDoctorApp; HospitalsModel({this.desciption, this.desciptionN, diff --git a/lib/core/model/insurance/insurance_approval.dart b/lib/core/model/insurance/insurance_approval.dart index a3717c42..69e88a2e 100644 --- a/lib/core/model/insurance/insurance_approval.dart +++ b/lib/core/model/insurance/insurance_approval.dart @@ -1,11 +1,11 @@ class ApporvalDetails { - int approvalNo; + int? approvalNo; - String procedureName; + String? procedureName; //String procedureNameN; - String status; + String ?status; - String isInvoicedDesc; + String ?isInvoicedDesc; ApporvalDetails( {this.approvalNo, this.procedureName, this.status, this.isInvoicedDesc}); @@ -35,35 +35,35 @@ class ApporvalDetails { } class InsuranceApprovalModel { - List apporvalDetails; - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - String sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - int patientID; - String tokenID; - int patientTypeID; - int patientType; - int eXuldAPPNO; - int projectID; - String doctorName; - String clinicName; - String patientDescription; - int approvalNo; - String approvalStatusDescption; - int unUsedCount; - String doctorImage; - String projectName; + List ?apporvalDetails; + double ?versionID; + int ? channel; + int ? languageID; + String ? iPAdress; + String ? generalid; + int ? patientOutSA; + String ? sessionID; + bool ? isDentalAllowedBackend; + int ? deviceTypeID; + int ? patientID; + String ? tokenID; + int ? patientTypeID; + int ? patientType; + int ? eXuldAPPNO; + int ? projectID; + String ? doctorName; + String ? clinicName; + String ? patientDescription; + int ? approvalNo; + String ?approvalStatusDescption; + int ? unUsedCount; + String ? doctorImage; + String ? projectName; //String companyName; - String expiryDate; - String rceiptOn; - int appointmentNo; + String ? expiryDate; + String ? rceiptOn; + int ?appointmentNo; InsuranceApprovalModel( {this.versionID, @@ -126,9 +126,9 @@ class InsuranceApprovalModel { doctorImage = json['DoctorImageURL']; clinicName = json['ClinicName']; if (json['ApporvalDetails'] != null) { - apporvalDetails = new List(); + apporvalDetails =[]; json['ApporvalDetails'].forEach((v) { - apporvalDetails.add(new ApporvalDetails.fromJson(v)); + apporvalDetails!.add(new ApporvalDetails.fromJson(v)); }); } appointmentNo = json['AppointmentNo']; diff --git a/lib/core/model/insurance/insurance_approval_in_patient_model.dart b/lib/core/model/insurance/insurance_approval_in_patient_model.dart index f185a8bf..722d34c7 100644 --- a/lib/core/model/insurance/insurance_approval_in_patient_model.dart +++ b/lib/core/model/insurance/insurance_approval_in_patient_model.dart @@ -1,36 +1,36 @@ class InsuranceApprovalInPatientModel { - String setupID; - int projectID; - int approvalNo; - int status; - String approvalDate; - int patientType; - int patientID; - int companyID; - bool subCategoryID; - int doctorID; - int clinicID; - int approvalType; - int inpatientApprovalSubType; + String? setupID; + int? projectID; + int? approvalNo; + int? status; + String? approvalDate; + int? patientType; + int? patientID; + int? companyID; + bool? subCategoryID; + int? doctorID; + int? clinicID; + int? approvalType; + int? inpatientApprovalSubType; dynamic isApprovalOnGross; - String companyApprovalNo; + String? companyApprovalNo; dynamic progNoteOrderNo; - String submitOn; - String receiptOn; - String expiryDate; - int admissionNo; - int admissionRequestNo; - String approvalStatusDescption; + String? submitOn; + String? receiptOn; + String? expiryDate; + int? admissionNo; + int? admissionRequestNo; + String? approvalStatusDescption; dynamic approvalStatusDescptionN; dynamic remarks; - List apporvalDetails; - String clinicName; + List? apporvalDetails; + String? clinicName; dynamic companyName; - String doctorName; - String projectName; - int totaUnUsedCount; - int unUsedCount; - String doctorImage; + String? doctorName; + String? projectName; + int? totaUnUsedCount; + int? unUsedCount; + String? doctorImage; InsuranceApprovalInPatientModel( {this.setupID, @@ -93,9 +93,9 @@ class InsuranceApprovalInPatientModel { approvalStatusDescptionN = json['ApprovalStatusDescptionN']; remarks = json['Remarks']; if (json['ApporvalDetails'] != null) { - apporvalDetails = new List(); + apporvalDetails = []; json['ApporvalDetails'].forEach((v) { - apporvalDetails.add(new ApporvalDetails.fromJson(v)); + apporvalDetails!.add(new ApporvalDetails.fromJson(v)); }); } clinicName = json['ClinicName']; @@ -135,7 +135,7 @@ class InsuranceApprovalInPatientModel { data['Remarks'] = this.remarks; if (this.apporvalDetails != null) { data['ApporvalDetails'] = - this.apporvalDetails.map((v) => v.toJson()).toList(); + this.apporvalDetails!.map((v) => v.toJson()).toList(); } data['ClinicName'] = this.clinicName; data['CompanyName'] = this.companyName; @@ -148,35 +148,35 @@ class InsuranceApprovalInPatientModel { } class ApporvalDetails { - Null setupID; - Null projectID; - int approvalNo; - Null lineItemNo; - Null orderType; - Null procedureID; - Null toothNo; - Null price; - Null approvedAmount; - Null unapprovedPatientShare; - Null waivedAmount; - Null discountType; - Null discountValue; - Null shareType; - Null patientShareTypeValue; - Null companyShareTypeValue; - Null patientShare; - Null companyShare; - Null deductableAmount; - String disapprovedRemarks; - Null progNoteOrderNo; - Null progNoteLineItemNo; - Null invoiceTransactionType; - Null invoiceNo; - String procedureName; - String procedureNameN; - String status; - Null isInvoiced; - String isInvoicedDesc; + dynamic setupID; + dynamic projectID; + int? approvalNo; + dynamic lineItemNo; + dynamic orderType; + dynamic procedureID; + dynamic toothNo; + dynamic price; + dynamic approvedAmount; + dynamic unapprovedPatientShare; + dynamic waivedAmount; + dynamic discountType; + dynamic discountValue; + dynamic shareType; + dynamic patientShareTypeValue; + dynamic companyShareTypeValue; + dynamic patientShare; + dynamic companyShare; + dynamic deductableAmount; + String? disapprovedRemarks; + dynamic progNoteOrderNo; + dynamic progNoteLineItemNo; + dynamic invoiceTransactionType; + dynamic invoiceNo; + String? procedureName; + String? procedureNameN; + String? status; + dynamic isInvoiced; + String? isInvoicedDesc; ApporvalDetails( {this.setupID, diff --git a/lib/core/model/labs/LabOrderResult.dart b/lib/core/model/labs/LabOrderResult.dart index ecb4ae65..7fc4432f 100644 --- a/lib/core/model/labs/LabOrderResult.dart +++ b/lib/core/model/labs/LabOrderResult.dart @@ -1,23 +1,23 @@ class LabOrderResult { - String description; + String? description; dynamic femaleInterpretativeData; - int gender; - int lineItemNo; + int ?gender; + int? lineItemNo; dynamic maleInterpretativeData; dynamic notes; - String packageID; - int patientID; - String projectID; - String referanceRange; - String resultValue; - String sampleCollectedOn; - String sampleReceivedOn; - String setupID; + String ?packageID; + int ?patientID; + String ? projectID; + String ? referanceRange; + String ? resultValue; + String ? sampleCollectedOn; + String ? sampleReceivedOn; + String ? setupID; dynamic superVerifiedOn; - String testCode; - String uOM; - String verifiedOn; - String verifiedOnDateTime; + String? testCode; + String? uOM; + String? verifiedOn; + String? verifiedOnDateTime; LabOrderResult( {this.description, diff --git a/lib/core/model/labs/LabResultHistory.dart b/lib/core/model/labs/LabResultHistory.dart index 7c4221ca..9c023da7 100644 --- a/lib/core/model/labs/LabResultHistory.dart +++ b/lib/core/model/labs/LabResultHistory.dart @@ -1,28 +1,28 @@ class LabResultHistory { - String description; - String femaleInterpretativeData; - int gender; - bool isCertificateAllowed; - int lineItemNo; - String maleInterpretativeData; - String notes; - int orderLineItemNo; - int orderNo; - String packageID; - int patientID; - String projectID; - String referanceRange; - String resultValue; - int resultValueBasedLineItemNo; - String resultValueFlag; - String sampleCollectedOn; - String sampleReceivedOn; - String setupID; - String superVerifiedOn; - String testCode; - String uOM; - String verifiedOn; - String verifiedOnDateTime; + String? description; + String? femaleInterpretativeData; + int? gender; + bool? isCertificateAllowed; + int? lineItemNo; + String? maleInterpretativeData; + String? notes; + int? orderLineItemNo; + int? orderNo; + String? packageID; + int? patientID; + String? projectID; + String? referanceRange; + String? resultValue; + int? resultValueBasedLineItemNo; + String? resultValueFlag; + String? sampleCollectedOn; + String? sampleReceivedOn; + String? setupID; + String? superVerifiedOn; + String? testCode; + String? uOM; + String? verifiedOn; + String? verifiedOnDateTime; LabResultHistory( {this.description, diff --git a/lib/core/model/labs/all_special_lab_result_model.dart b/lib/core/model/labs/all_special_lab_result_model.dart index ffdc5ee5..a177e16e 100644 --- a/lib/core/model/labs/all_special_lab_result_model.dart +++ b/lib/core/model/labs/all_special_lab_result_model.dart @@ -5,51 +5,51 @@ class AllSpecialLabResultModel { dynamic appointmentDate; dynamic appointmentNo; dynamic appointmentTime; - String clinicDescription; - String clinicDescriptionEnglish; + String? clinicDescription; + String? clinicDescriptionEnglish; dynamic clinicDescriptionN; dynamic clinicID; dynamic createdOn; - double decimalDoctorRate; + double? decimalDoctorRate; dynamic doctorID; - String doctorImageURL; - String doctorName; - String doctorNameEnglish; + String? doctorImageURL; + String? doctorName; + String? doctorNameEnglish; dynamic doctorNameN; dynamic doctorRate; dynamic doctorStarsRate; - String doctorTitle; + String? doctorTitle; dynamic gender; - String genderDescription; - bool inOutPatient; - String invoiceNo; - bool isActiveDoctorProfile; - bool isDoctorAllowVedioCall; - bool isExecludeDoctor; - bool isInOutPatient; + String? genderDescription; + bool? inOutPatient; + String? invoiceNo; + bool? isActiveDoctorProfile; + bool? isDoctorAllowVedioCall; + bool? isExecludeDoctor; + bool? isInOutPatient; dynamic isInOutPatientDescription; dynamic isInOutPatientDescriptionN; - bool isLiveCareAppointment; - bool isRead; - bool isSendEmail; - String moduleID; - String nationalityFlagURL; + bool? isLiveCareAppointment; + bool? isRead; + bool? isSendEmail; + String? moduleID; + String? nationalityFlagURL; dynamic noOfPatientsRate; dynamic orderDate; - String orderNo; + String? orderNo; dynamic patientID; - String projectID; - String projectName; + String? projectID; + String? projectName; dynamic projectNameN; - String qR; - String resultData; - String resultDataHTML; + String? qR; + String? resultData; + String? resultDataHTML; dynamic resultDataTxt; - String setupID; + String? setupID; //List speciality; dynamic status; dynamic statusDesc; - String strOrderDate; + String? strOrderDate; AllSpecialLabResultModel( {this.actualDoctorRate, diff --git a/lib/core/model/labs/all_special_lab_result_request.dart b/lib/core/model/labs/all_special_lab_result_request.dart index d5df1405..950f0e96 100644 --- a/lib/core/model/labs/all_special_lab_result_request.dart +++ b/lib/core/model/labs/all_special_lab_result_request.dart @@ -1,18 +1,18 @@ class AllSpecialLabResultRequestModel { - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - String sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - String tokenID; - int patientTypeID; - int patientType; - int patientID; - int projectID; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; + String? sessionID; + bool? isDentalAllowedBackend; + int? deviceTypeID; + String? tokenID; + int? patientTypeID; + int? patientType; + int? patientID; + int? projectID; AllSpecialLabResultRequestModel( {this.versionID, diff --git a/lib/core/model/labs/lab_result.dart b/lib/core/model/labs/lab_result.dart index ee9f981d..0cc48aef 100644 --- a/lib/core/model/labs/lab_result.dart +++ b/lib/core/model/labs/lab_result.dart @@ -1,24 +1,24 @@ class LabResult { - String description; + String? description; dynamic femaleInterpretativeData; - int gender; - int lineItemNo; + int? gender; + int? lineItemNo; dynamic maleInterpretativeData; - String notes; - String packageID; - int patientID; - String projectID; - String referanceRange; - String resultValue; - String maxValue; - String minValue; - String sampleCollectedOn; - String sampleReceivedOn; - String setupID; + String? notes; + String? packageID; + int? patientID; + String? projectID; + String? referanceRange; + String? resultValue; + String? sampleCollectedOn; + String? sampleReceivedOn; + String? setupID; + String? maxValue; + String? minValue; dynamic superVerifiedOn; - String testCode; - String uOM; - String verifiedOn; + String? testCode; + String? uOM; + String? verifiedOn; dynamic verifiedOnDateTime; LabResult( @@ -96,9 +96,9 @@ class LabResult { int checkResultStatus() { try { - var max = double.tryParse(maxValue) ?? null; - var min = double.tryParse(minValue) ?? null; - var result = double.tryParse(resultValue) ?? null; + var max = double.tryParse(maxValue!) ?? null; + var min = double.tryParse(minValue!) ?? null; + var result = double.tryParse(resultValue!) ?? null; if (max != null && min != null && result != null) { if (result > max) { return 1; @@ -110,18 +110,17 @@ class LabResult { } else { return 0; } - }catch (e){ + } catch (e) { return 0; } - } } class LabResultList { String filterName = ""; - List patientLabResultList = List(); + List patientLabResultList = []; - LabResultList({this.filterName, LabResult lab}) { + LabResultList({required this.filterName, required LabResult lab}) { patientLabResultList.add(lab); } } diff --git a/lib/core/model/labs/patient_lab_orders.dart b/lib/core/model/labs/patient_lab_orders.dart index af60f86f..08f81f16 100644 --- a/lib/core/model/labs/patient_lab_orders.dart +++ b/lib/core/model/labs/patient_lab_orders.dart @@ -1,40 +1,40 @@ import 'package:doctor_app_flutter/util/date-utils.dart'; class PatientLabOrders { - int actualDoctorRate; - String clinicDescription; - String clinicDescriptionEnglish; - Null clinicDescriptionN; - int clinicID; - int doctorID; - String doctorImageURL; - String doctorName; - String doctorNameEnglish; - Null doctorNameN; - int doctorRate; - String doctorTitle; - int gender; - String genderDescription; - String invoiceNo; - bool isActiveDoctorProfile; - bool isDoctorAllowVedioCall; - bool isExecludeDoctor; - bool isInOutPatient; - String isInOutPatientDescription; - String isInOutPatientDescriptionN; - bool isRead; - String nationalityFlagURL; - int noOfPatientsRate; - DateTime orderDate; - String orderNo; - String patientID; - String projectID; - String projectName; - Null projectNameN; - String qR; - String setupID; - List speciality; - bool isLiveCareAppointment; + int ?actualDoctorRate; + String ?clinicDescription; + String ?clinicDescriptionEnglish; + dynamic clinicDescriptionN; + int ?clinicID; + int ?doctorID; + String? doctorImageURL; + String ?doctorName; + String ?doctorNameEnglish; + dynamic doctorNameN; + int ?doctorRate; + String ?doctorTitle; + int ?gender; + String ?genderDescription; + String ?invoiceNo; + bool ?isActiveDoctorProfile; + bool ?isDoctorAllowVedioCall; + bool ?isExecludeDoctor; + bool ?isInOutPatient; + String ?isInOutPatientDescription; + String ?isInOutPatientDescriptionN; + bool ?isRead; + String ?nationalityFlagURL; + int ?noOfPatientsRate; + DateTime? orderDate; + String ?orderNo; + String ?patientID; + String ?projectID; + String ?projectName; + dynamic projectNameN; + String ?qR; + String ?setupID; + List ?speciality; + bool ?isLiveCareAppointment; PatientLabOrders( {this.actualDoctorRate, this.clinicDescription, @@ -149,10 +149,10 @@ class PatientLabOrders { class PatientLabOrdersList { String filterName = ""; - List patientLabOrdersList = List(); + List patientLabOrdersList = []; PatientLabOrdersList( - {this.filterName, PatientLabOrders patientDoctorAppointment}) { + {required this.filterName, required PatientLabOrders patientDoctorAppointment}) { patientLabOrdersList.add(patientDoctorAppointment); } } diff --git a/lib/core/model/labs/patient_lab_special_result.dart b/lib/core/model/labs/patient_lab_special_result.dart index 2fbcb832..f86dd56f 100644 --- a/lib/core/model/labs/patient_lab_special_result.dart +++ b/lib/core/model/labs/patient_lab_special_result.dart @@ -1,9 +1,9 @@ class PatientLabSpecialResult { - String invoiceNo; - String moduleID; - String resultData; - String resultDataHTML; - Null resultDataTxt; + String ?invoiceNo; + String ?moduleID; + String ? resultData; + String ? resultDataHTML; + dynamic resultDataTxt; PatientLabSpecialResult( {this.invoiceNo, diff --git a/lib/core/model/labs/request_patient_lab_orders.dart b/lib/core/model/labs/request_patient_lab_orders.dart index ce9263ef..4f746277 100644 --- a/lib/core/model/labs/request_patient_lab_orders.dart +++ b/lib/core/model/labs/request_patient_lab_orders.dart @@ -1,17 +1,17 @@ class RequestPatientLabOrders { - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - String sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - int patientID; - String tokenID; - int patientTypeID; - int patientType; + double? versionID; + int ?channel; + int ?languageID; + String? iPAdress; + String ?generalid; + int? patientOutSA; + String? sessionID; + bool ?isDentalAllowedBackend; + int ?deviceTypeID; + int ?patientID; + String ?tokenID; + int ?patientTypeID; + int ?patientType; RequestPatientLabOrders( {this.versionID, diff --git a/lib/core/model/labs/request_patient_lab_special_result.dart b/lib/core/model/labs/request_patient_lab_special_result.dart index b48cf0e1..100f92b5 100644 --- a/lib/core/model/labs/request_patient_lab_special_result.dart +++ b/lib/core/model/labs/request_patient_lab_special_result.dart @@ -1,22 +1,22 @@ class RequestPatientLabSpecialResult { - String invoiceNo; - String orderNo; - String setupID; - String projectID; - int clinicID; - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - String sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - int patientID; - String tokenID; - int patientTypeID; - int patientType; + String? invoiceNo; + String? orderNo; + String? setupID; + String? projectID; + int ?clinicID; + double? versionID; + int ?channel; + int ?languageID; + String? iPAdress; + String ?generalid; + int ?patientOutSA; + String ?sessionID; + bool ?isDentalAllowedBackend; + int ?deviceTypeID; + int ?patientID; + String? tokenID; + int ?patientTypeID; + int ?patientType; RequestPatientLabSpecialResult( {this.invoiceNo, diff --git a/lib/core/model/labs/request_send_lab_report_email.dart b/lib/core/model/labs/request_send_lab_report_email.dart index 118da906..699ddafb 100644 --- a/lib/core/model/labs/request_send_lab_report_email.dart +++ b/lib/core/model/labs/request_send_lab_report_email.dart @@ -1,29 +1,29 @@ class RequestSendLabReportEmail { - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - String sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - int patientID; - String tokenID; - int patientTypeID; - int patientType; - String to; - String dateofBirth; - String patientIditificationNum; - String patientMobileNumber; - String patientName; - String setupID; - String projectName; - String clinicName; - String doctorName; - String projectID; - String invoiceNo; - String orderDate; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; + String? sessionID; + bool? isDentalAllowedBackend; + int? deviceTypeID; + int? patientID; + String? tokenID; + int? patientTypeID; + int? patientType; + String? to; + String? dateofBirth; + String? patientIditificationNum; + String? patientMobileNumber; + String? patientName; + String? setupID; + String? projectName; + String? clinicName; + String? doctorName; + String? projectID; + String? invoiceNo; + String? orderDate; RequestSendLabReportEmail( {this.versionID, diff --git a/lib/core/model/live_care/AlternativeServicesList.dart b/lib/core/model/live_care/AlternativeServicesList.dart index 11f27b95..28d70805 100644 --- a/lib/core/model/live_care/AlternativeServicesList.dart +++ b/lib/core/model/live_care/AlternativeServicesList.dart @@ -1,9 +1,9 @@ import 'package:flutter/material.dart'; class AlternativeService { - int serviceID; - String serviceName; - bool isSelected; + int? serviceID; + String? serviceName; + bool? isSelected; AlternativeService( {this.serviceID, this.serviceName, this.isSelected = false}); @@ -23,7 +23,7 @@ class AlternativeService { } class AlternativeServicesList with ChangeNotifier { - List _alternativeServicesList; + late List _alternativeServicesList; getServicesList(){ return _alternativeServicesList; diff --git a/lib/core/model/live_care/PendingPatientERForDoctorAppRequestModel.dart b/lib/core/model/live_care/PendingPatientERForDoctorAppRequestModel.dart index dc1f25b3..a99c9649 100644 --- a/lib/core/model/live_care/PendingPatientERForDoctorAppRequestModel.dart +++ b/lib/core/model/live_care/PendingPatientERForDoctorAppRequestModel.dart @@ -1,7 +1,7 @@ class PendingPatientERForDoctorAppRequestModel { - bool outSA; - int doctorID; - String sErServiceID; + bool ? outSA; + int ? doctorID; + String ? sErServiceID; PendingPatientERForDoctorAppRequestModel( {this.outSA, this.doctorID, this.sErServiceID}); diff --git a/lib/core/model/live_care/add_patient_to_doctor_list_request_model.dart b/lib/core/model/live_care/add_patient_to_doctor_list_request_model.dart index 1d63e885..a7589c08 100644 --- a/lib/core/model/live_care/add_patient_to_doctor_list_request_model.dart +++ b/lib/core/model/live_care/add_patient_to_doctor_list_request_model.dart @@ -1,9 +1,9 @@ class AddPatientToDoctorListRequestModel { - int vCID; - String tokenID; - String generalid; - int doctorId; - bool isOutKsa; + int? vCID; + String? tokenID; + String? generalid; + int? doctorId; + bool? isOutKsa; AddPatientToDoctorListRequestModel({this.vCID, this.tokenID, this.generalid, this.doctorId, this.isOutKsa}); diff --git a/lib/core/model/live_care/live_care_login_reguest_model.dart b/lib/core/model/live_care/live_care_login_reguest_model.dart index e14d4223..90ea0ff1 100644 --- a/lib/core/model/live_care/live_care_login_reguest_model.dart +++ b/lib/core/model/live_care/live_care_login_reguest_model.dart @@ -1,9 +1,9 @@ class LiveCareUserLoginRequestModel { - String tokenID; - String generalid; - int doctorId; - int isOutKsa; - int isLogin; + String? tokenID; + String? generalid; + int? doctorId; + int? isOutKsa; + int? isLogin; LiveCareUserLoginRequestModel({this.tokenID, this.generalid, this.doctorId, this.isOutKsa, this.isLogin}); diff --git a/lib/core/model/medical_report/medical_file_model.dart b/lib/core/model/medical_report/medical_file_model.dart index deebb2af..53737499 100644 --- a/lib/core/model/medical_report/medical_file_model.dart +++ b/lib/core/model/medical_report/medical_file_model.dart @@ -1,14 +1,14 @@ class MedicalFileModel { - List entityList; + List? entityList; dynamic statusMessage; MedicalFileModel({this.entityList, this.statusMessage}); MedicalFileModel.fromJson(Map json) { if (json['entityList'] != null) { - entityList = new List(); + entityList = []; json['entityList'].forEach((v) { - entityList.add(new EntityList.fromJson(v)); + entityList!.add(new EntityList.fromJson(v)); }); } statusMessage = json['statusMessage']; @@ -17,7 +17,7 @@ class MedicalFileModel { Map toJson() { final Map data = new Map(); if (this.entityList != null) { - data['entityList'] = this.entityList.map((v) => v.toJson()).toList(); + data['entityList'] = this.entityList!.map((v) => v.toJson()).toList(); } data['statusMessage'] = this.statusMessage; return data; @@ -25,15 +25,15 @@ class MedicalFileModel { } class EntityList { - List timelines; + List? timelines; EntityList({this.timelines}); EntityList.fromJson(Map json) { if (json['Timelines'] != null) { - timelines = new List(); + timelines = []; json['Timelines'].forEach((v) { - timelines.add(new Timelines.fromJson(v)); + timelines!.add(new Timelines.fromJson(v)); }); } } @@ -41,25 +41,25 @@ class EntityList { Map toJson() { final Map data = new Map(); if (this.timelines != null) { - data['Timelines'] = this.timelines.map((v) => v.toJson()).toList(); + data['Timelines'] = this.timelines!.map((v) => v.toJson()).toList(); } return data; } } class Timelines { - int clinicId; - String clinicName; - String date; - int doctorId; - String doctorImage; - String doctorName; - int encounterNumber; - String encounterType; - int projectID; - String projectName; - String setupID; - List timeLineEvents; + int? clinicId; + String? clinicName; + String? date; + int? doctorId; + String? doctorImage; + String? doctorName; + int? encounterNumber; + String? encounterType; + int? projectID; + String? projectName; + String? setupID; + List? timeLineEvents; Timelines( {this.clinicId, @@ -88,9 +88,9 @@ class Timelines { projectName = json['ProjectName']; setupID = json['SetupID']; if (json['TimeLineEvents'] != null) { - timeLineEvents = new List(); + timeLineEvents = []; json['TimeLineEvents'].forEach((v) { - timeLineEvents.add(new TimeLineEvents.fromJson(v)); + timeLineEvents!.add(new TimeLineEvents.fromJson(v)); }); } } @@ -110,25 +110,25 @@ class Timelines { data['SetupID'] = this.setupID; if (this.timeLineEvents != null) { data['TimeLineEvents'] = - this.timeLineEvents.map((v) => v.toJson()).toList(); + this.timeLineEvents!.map((v) => v.toJson()).toList(); } return data; } } class TimeLineEvents { - List admissions; - String colorClass; - List consulations; + List? admissions; + String? colorClass; + List? consulations; TimeLineEvents({this.admissions, this.colorClass, this.consulations}); TimeLineEvents.fromJson(Map json) { colorClass = json['ColorClass']; if (json['Consulations'] != null) { - consulations = new List(); + consulations = []; json['Consulations'].forEach((v) { - consulations.add(new Consulations.fromJson(v)); + consulations!.add(new Consulations.fromJson(v)); }); } } @@ -138,38 +138,38 @@ class TimeLineEvents { data['ColorClass'] = this.colorClass; if (this.consulations != null) { - data['Consulations'] = this.consulations.map((v) => v.toJson()).toList(); + data['Consulations'] = this.consulations!.map((v) => v.toJson()).toList(); } return data; } } class Consulations { - int admissionNo; - String appointmentDate; - int appointmentNo; - String appointmentType; - String clinicID; - String clinicName; - int doctorID; - String doctorName; - String endTime; - String episodeDate; - int episodeID; - int patientID; - int projectID; - String projectName; - String remarks; - String setupID; - String startTime; - String visitFor; - String visitType; - String dispalyName; - List lstAssessments; - List lstPhysicalExam; - List lstProcedure; - List lstMedicalHistory; - List lstCheifComplaint; + int? admissionNo; + String? appointmentDate; + int? appointmentNo; + String? appointmentType; + String? clinicID; + String? clinicName; + int? doctorID; + String? doctorName; + String? endTime; + String? episodeDate; + int? episodeID; + int? patientID; + int? projectID; + String? projectName; + String? remarks; + String? setupID; + String? startTime; + String? visitFor; + String? visitType; + String? dispalyName; + List? lstAssessments; + List? lstPhysicalExam; + List? lstProcedure; + List? lstMedicalHistory; + List? lstCheifComplaint; Consulations( {this.admissionNo, @@ -220,33 +220,33 @@ class Consulations { visitType = json['VisitType']; dispalyName = json['dispalyName']; if (json['lstAssessments'] != null) { - lstAssessments = new List(); + lstAssessments = []; json['lstAssessments'].forEach((v) { - lstAssessments.add(new LstAssessments.fromJson(v)); + lstAssessments!.add(new LstAssessments.fromJson(v)); }); } if (json['lstCheifComplaint'] != null) { - lstCheifComplaint = new List(); + lstCheifComplaint = []; json['lstCheifComplaint'].forEach((v) { - lstCheifComplaint.add(new LstCheifComplaint.fromJson(v)); + lstCheifComplaint!.add(new LstCheifComplaint.fromJson(v)); }); } if (json['lstPhysicalExam'] != null) { - lstPhysicalExam = new List(); + lstPhysicalExam = []; json['lstPhysicalExam'].forEach((v) { - lstPhysicalExam.add(new LstPhysicalExam.fromJson(v)); + lstPhysicalExam!.add(new LstPhysicalExam.fromJson(v)); }); } if (json['lstProcedure'] != null) { - lstProcedure = new List(); + lstProcedure = []; json['lstProcedure'].forEach((v) { - lstProcedure.add(new LstProcedure.fromJson(v)); + lstProcedure!.add(new LstProcedure.fromJson(v)); }); } if (json['lstMedicalHistory'] != null) { - lstMedicalHistory = new List(); + lstMedicalHistory = []; json['lstMedicalHistory'].forEach((v) { - lstMedicalHistory.add(new LstMedicalHistory.fromJson(v)); + lstMedicalHistory!.add(new LstMedicalHistory.fromJson(v)); }); } } @@ -275,40 +275,40 @@ class Consulations { data['dispalyName'] = this.dispalyName; if (this.lstAssessments != null) { data['lstAssessments'] = - this.lstAssessments.map((v) => v.toJson()).toList(); + this.lstAssessments!.map((v) => v.toJson()).toList(); } if (this.lstCheifComplaint != null) { data['lstCheifComplaint'] = - this.lstCheifComplaint.map((v) => v.toJson()).toList(); + this.lstCheifComplaint!.map((v) => v.toJson()).toList(); } if (this.lstPhysicalExam != null) { data['lstPhysicalExam'] = - this.lstPhysicalExam.map((v) => v.toJson()).toList(); + this.lstPhysicalExam!.map((v) => v.toJson()).toList(); } if (this.lstProcedure != null) { - data['lstProcedure'] = this.lstProcedure.map((v) => v.toJson()).toList(); + data['lstProcedure'] = this.lstProcedure!.map((v) => v.toJson()).toList(); } if (this.lstMedicalHistory != null) { data['lstMedicalHistory'] = - this.lstMedicalHistory.map((v) => v.toJson()).toList(); + this.lstMedicalHistory!.map((v) => v.toJson()).toList(); } return data; } } class LstCheifComplaint { - int appointmentNo; - String cCDate; - String chiefComplaint; - String currentMedication; - int episodeID; - String hOPI; - int patientID; - String patientType; - int projectID; - String projectName; - String setupID; - String dispalyName; + int? appointmentNo; + String? cCDate; + String? chiefComplaint; + String? currentMedication; + int? episodeID; + String? hOPI; + int? patientID; + String? patientType; + int? projectID; + String? projectName; + String? setupID; + String? dispalyName; LstCheifComplaint( {this.appointmentNo, @@ -358,19 +358,19 @@ class LstCheifComplaint { } class LstAssessments { - int appointmentNo; - String condition; - String description; - int episodeID; - String iCD10; - int patientID; - String patientType; - int projectID; - String projectName; - String remarks; - String setupID; - String type; - String dispalyName; + int? appointmentNo; + String? condition; + String? description; + int? episodeID; + String? iCD10; + int? patientID; + String? patientType; + int? projectID; + String? projectName; + String? remarks; + String? setupID; + String? type; + String? dispalyName; LstAssessments( {this.appointmentNo, @@ -423,19 +423,19 @@ class LstAssessments { } class LstPhysicalExam { - String abnormal; - int appointmentNo; - int episodeID; - String examDesc; - String examID; - String examType; - int patientID; - String patientType; - int projectID; - String projectName; - String remarks; - String setupID; - String dispalyName; + String? abnormal; + int? appointmentNo; + int? episodeID; + String? examDesc; + String? examID; + String? examType; + int? patientID; + String? patientType; + int? projectID; + String? projectName; + String? remarks; + String? setupID; + String? dispalyName; LstPhysicalExam( {this.abnormal, @@ -488,17 +488,17 @@ class LstPhysicalExam { } class LstProcedure { - int appointmentNo; - int episodeID; - String orderDate; - int patientID; - String patientType; - String procName; - String procedureId; - int projectID; - String projectName; - String setupID; - String dispalyName; + int? appointmentNo; + int? episodeID; + String? orderDate; + int? patientID; + String? patientType; + String? procName; + String? procedureId; + int? projectID; + String? projectName; + String? setupID; + String? dispalyName; LstProcedure( {this.appointmentNo, @@ -545,17 +545,17 @@ class LstProcedure { } class LstMedicalHistory { - int appointmentNo; - String checked; - int episodeID; - String history; - int patientID; - String patientType; - int projectID; - String projectName; - String remarks; - String setupID; - String dispalyName; + int? appointmentNo; + String? checked; + int? episodeID; + String? history; + int? patientID; + String? patientType; + int? projectID; + String? projectName; + String? remarks; + String? setupID; + String? dispalyName; LstMedicalHistory( {this.appointmentNo, diff --git a/lib/core/model/medical_report/medical_file_request_model.dart b/lib/core/model/medical_report/medical_file_request_model.dart index 8703141a..01a2abf2 100644 --- a/lib/core/model/medical_report/medical_file_request_model.dart +++ b/lib/core/model/medical_report/medical_file_request_model.dart @@ -1,7 +1,7 @@ class MedicalFileRequestModel { - int patientMRN; - String vidaAuthTokenID; - String iPAdress; + int ?patientMRN; + String ?vidaAuthTokenID; + String ?iPAdress; MedicalFileRequestModel({this.patientMRN, this.vidaAuthTokenID,this.iPAdress}); diff --git a/lib/core/model/note/CreateNoteModel.dart b/lib/core/model/note/CreateNoteModel.dart index ce076705..5d1709ca 100644 --- a/lib/core/model/note/CreateNoteModel.dart +++ b/lib/core/model/note/CreateNoteModel.dart @@ -1,23 +1,23 @@ class CreateNoteModel { - int visitType; - int admissionNo; - int projectID; - int patientTypeID; - int patientID; - int clinicID; - String notes; - int createdBy; - int editedBy; - String nursingRemarks; - int languageID; - String stamp; - String iPAdress; - double versionID; - int channel; - String tokenID; - String sessionID; - bool isLoginForDoctorApp; - bool patientOutSA; + int? visitType; + int? admissionNo; + int? projectID; + int? patientTypeID; + int? patientID; + int? clinicID; + String? notes; + int ?createdBy; + int ?editedBy; + String ?nursingRemarks; + int ?languageID; + String? stamp; + String ?iPAdress; + double ?versionID; + int ?channel; + String ?tokenID; + String? sessionID; + bool ?isLoginForDoctorApp; + bool ?patientOutSA; CreateNoteModel( {this.visitType, diff --git a/lib/core/model/note/GetNursingProgressNoteRequestModel.dart b/lib/core/model/note/GetNursingProgressNoteRequestModel.dart index 4335053c..b7fd7aa5 100644 --- a/lib/core/model/note/GetNursingProgressNoteRequestModel.dart +++ b/lib/core/model/note/GetNursingProgressNoteRequestModel.dart @@ -1,14 +1,18 @@ import 'package:doctor_app_flutter/config/config.dart'; class GetNursingProgressNoteRequestModel { - int patientID; - int admissionNo; - int patientTypeID; - int patientType; - String setupID; + int? patientID; + int? admissionNo; + int? patientTypeID; + int? patientType; + String? setupID; GetNursingProgressNoteRequestModel( - {this.patientID, this.admissionNo, this.patientTypeID = 1, this.patientType = 1, this.setupID }); + {this.patientID, + this.admissionNo, + this.patientTypeID = 1, + this.patientType = 1, + this.setupID}); GetNursingProgressNoteRequestModel.fromJson(Map json) { patientID = json['PatientID']; diff --git a/lib/core/model/note/GetNursingProgressNoteResposeModel.dart b/lib/core/model/note/GetNursingProgressNoteResposeModel.dart index fb7fbcec..aaf9c7ab 100644 --- a/lib/core/model/note/GetNursingProgressNoteResposeModel.dart +++ b/lib/core/model/note/GetNursingProgressNoteResposeModel.dart @@ -1,14 +1,14 @@ class GetNursingProgressNoteResposeModel { - String notes; + String? notes; dynamic conditionType; - int createdBy; - String createdOn; + int? createdBy; + String? createdOn; dynamic editedBy; dynamic editedOn; - String createdByName; + String? createdByName; - String editedByName; + String? editedByName; GetNursingProgressNoteResposeModel( {this.notes, diff --git a/lib/core/model/note/note_model.dart b/lib/core/model/note/note_model.dart index 797f9b6d..713de924 100644 --- a/lib/core/model/note/note_model.dart +++ b/lib/core/model/note/note_model.dart @@ -1,24 +1,24 @@ class NoteModel { - String setupID; - int projectID; - int patientID; - int patientType; - String admissionNo; - int lineItemNo; - int visitType; - String notes; - String assessmentDate; - String visitTime; - int status; - String nursingRemarks; - String createdOn; - String editedOn; - int createdBy; - int admissionClinicID; - String admissionClinicName; - Null doctorClinicName; - String doctorName; - String visitTypeDesc; + String? setupID; + int ?projectID; + int ?patientID; + int ?patientType; + String ?admissionNo; + int ?lineItemNo; + int ?visitType; + String ?notes; + String ?assessmentDate; + String ?visitTime; + int ?status; + String ?nursingRemarks; + String ?createdOn; + String ?editedOn; + int ?createdBy; + int ?admissionClinicID; + String ?admissionClinicName; + dynamic doctorClinicName; + String ?doctorName; + String ?visitTypeDesc; NoteModel( {this.setupID, diff --git a/lib/core/model/note/update_note_model.dart b/lib/core/model/note/update_note_model.dart index 20fd4b86..5c59cc77 100644 --- a/lib/core/model/note/update_note_model.dart +++ b/lib/core/model/note/update_note_model.dart @@ -1,21 +1,21 @@ class UpdateNoteReqModel { - int projectID; - int createdBy; - int admissionNo; - int lineItemNo; - String notes; - bool verifiedNote; - bool cancelledNote; - int languageID; - String stamp; - String iPAdress; - double versionID; - int channel; - String tokenID; - String sessionID; - bool isLoginForDoctorApp; - bool patientOutSA; - int patientTypeID; + int? projectID; + int? createdBy; + int? admissionNo; + int? lineItemNo; + String? notes; + bool? verifiedNote; + bool? cancelledNote; + int? languageID; + String? stamp; + String? iPAdress; + double? versionID; + int? channel; + String? tokenID; + String? sessionID; + bool? isLoginForDoctorApp; + bool? patientOutSA; + int? patientTypeID; UpdateNoteReqModel( {this.projectID, diff --git a/lib/core/model/patient_muse/PatientMuseResultsModel.dart b/lib/core/model/patient_muse/PatientMuseResultsModel.dart index 401fd1a7..970d48cb 100644 --- a/lib/core/model/patient_muse/PatientMuseResultsModel.dart +++ b/lib/core/model/patient_muse/PatientMuseResultsModel.dart @@ -1,19 +1,19 @@ import 'package:doctor_app_flutter/util/date-utils.dart'; class PatientMuseResultsModel { - int rowID; - String setupID; - int projectID; - String orderNo; - int lineItemNo; - int patientType; - int patientID; - String procedureID; + int ?rowID; + String? setupID; + int ?projectID; + String? orderNo; + int? lineItemNo; + int? patientType; + int? patientID; + String ?procedureID; dynamic reportData; - String imageURL; - String createdBy; - String createdOn; - DateTime createdOnDateTime; + String? imageURL; + String? createdBy; + String? createdOn; + DateTime? createdOnDateTime; PatientMuseResultsModel( {this.rowID, diff --git a/lib/core/model/patient_muse/PatientSearchRequestModel.dart b/lib/core/model/patient_muse/PatientSearchRequestModel.dart index dcb9b31c..c2c1bab8 100644 --- a/lib/core/model/patient_muse/PatientSearchRequestModel.dart +++ b/lib/core/model/patient_muse/PatientSearchRequestModel.dart @@ -1,19 +1,19 @@ class PatientSearchRequestModel { - int doctorID; - String firstName; - String middleName; - String lastName; - String patientMobileNumber; - String patientIdentificationID; - int patientID; - String from; - String to; - int searchType; - int projectID; - String mobileNo; - String identificationNo; - int nursingStationID; - int clinicID = 0; + int? doctorID; + String? firstName; + String? middleName; + String? lastName; + String? patientMobileNumber; + String? patientIdentificationID; + int? patientID; + String? from; + String? to; + int? searchType; + int? projectID; + String? mobileNo; + String? identificationNo; + int? nursingStationID; + int? clinicID = 0; PatientSearchRequestModel( {this.doctorID, diff --git a/lib/core/model/procedure/ControlsModel.dart b/lib/core/model/procedure/ControlsModel.dart index b3e8ae9c..e14c7768 100644 --- a/lib/core/model/procedure/ControlsModel.dart +++ b/lib/core/model/procedure/ControlsModel.dart @@ -1,6 +1,6 @@ class Controls { - String code; - String controlValue; + String ?code; + String ?controlValue; Controls({this.code, this.controlValue}); diff --git a/lib/core/model/procedure/Procedure_template_request_model.dart b/lib/core/model/procedure/Procedure_template_request_model.dart index 698178e3..26e3a271 100644 --- a/lib/core/model/procedure/Procedure_template_request_model.dart +++ b/lib/core/model/procedure/Procedure_template_request_model.dart @@ -1,31 +1,31 @@ class ProcedureTempleteRequestModel { - int doctorID; - String firstName; - String middleName; - String lastName; - String patientMobileNumber; - String patientIdentificationID; - int patientID; - String from; - String to; - int searchType; - String mobileNo; - String identificationNo; - int editedBy; - int projectID; - int clinicID; - String tokenID; - int languageID; - String stamp; - String iPAdress; - double versionID; - int channel; - String sessionID; - bool isLoginForDoctorApp; - bool patientOutSA; - String vidaAuthTokenID; - String vidaRefreshTokenID; - int deviceTypeID; + int? doctorID; + String? firstName; + String? middleName; + String? lastName; + String? patientMobileNumber; + String? patientIdentificationID; + int? patientID; + String? from; + String? to; + int? searchType; + String? mobileNo; + String? identificationNo; + int? editedBy; + int? projectID; + int? clinicID; + String? tokenID; + int? languageID; + String? stamp; + String? iPAdress; + double? versionID; + int? channel; + String? sessionID; + bool? isLoginForDoctorApp; + bool? patientOutSA; + String? vidaAuthTokenID; + String? vidaRefreshTokenID; + int? deviceTypeID; ProcedureTempleteRequestModel( {this.doctorID, diff --git a/lib/core/model/procedure/categories_procedure.dart b/lib/core/model/procedure/categories_procedure.dart index 9e6f847f..e7580062 100644 --- a/lib/core/model/procedure/categories_procedure.dart +++ b/lib/core/model/procedure/categories_procedure.dart @@ -1,26 +1,26 @@ class CategoriseProcedureModel { - List entityList; - int rowcount; + List ?entityList; + int ?rowcount; dynamic statusMessage; CategoriseProcedureModel( - {this.entityList, this.rowcount, this.statusMessage}); + {this.entityList, this.rowcount, this.statusMessage}); - CategoriseProcedureModel.fromJson(Map json) { + CategoriseProcedureModel.fromJson(Map json) { if (json['entityList'] != null) { - entityList = new List(); + entityList = []; json['entityList'].forEach((v) { - entityList.add(new EntityList.fromJson(v)); + entityList!.add(new EntityList.fromJson(v)); }); } rowcount = json['rowcount']; statusMessage = json['statusMessage']; } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); if (this.entityList != null) { - data['entityList'] = this.entityList.map((v) => v.toJson()).toList(); + data['entityList'] = this.entityList!.map((v) => v.toJson()).toList(); } data['rowcount'] = this.rowcount; data['statusMessage'] = this.statusMessage; @@ -29,38 +29,38 @@ class CategoriseProcedureModel { } class EntityList { - bool allowedClinic; - String category; - String categoryID; - String genderValidation; - String group; - String orderedValidation; + bool ?allowedClinic; + String ? category; + String ? categoryID; + String ? genderValidation; + String ? group; + String ? orderedValidation; dynamic price; - String procedureId; - String procedureName; - String specialPermission; - String subGroup; - String template; - String remarks; - String type; + String ? procedureId; + String ? procedureName; + String ? specialPermission; + String ? subGroup; + String ? template; + String ? remarks; + String ? type; EntityList( {this.allowedClinic, - this.category, - this.categoryID, - this.genderValidation, - this.group, - this.orderedValidation, - this.price, - this.procedureId, - this.procedureName, - this.specialPermission, - this.subGroup, - this.template, - this.remarks, - this.type}); + this.category, + this.categoryID, + this.genderValidation, + this.group, + this.orderedValidation, + this.price, + this.procedureId, + this.procedureName, + this.specialPermission, + this.subGroup, + this.template, + this.remarks, + this.type}); - EntityList.fromJson(Map json) { + EntityList.fromJson(Map json) { allowedClinic = json['allowedClinic']; category = json['category']; categoryID = json['categoryID']; @@ -75,8 +75,8 @@ class EntityList { template = json['template']; } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); data['allowedClinic'] = this.allowedClinic; data['category'] = this.category; data['categoryID'] = this.categoryID; diff --git a/lib/core/model/procedure/get_ordered_procedure_model.dart b/lib/core/model/procedure/get_ordered_procedure_model.dart index c3c7718f..721faccb 100644 --- a/lib/core/model/procedure/get_ordered_procedure_model.dart +++ b/lib/core/model/procedure/get_ordered_procedure_model.dart @@ -1,26 +1,26 @@ class GetOrderedProcedureModel { - List entityList; - int rowcount; + List? entityList; + int? rowcount; dynamic statusMessage; GetOrderedProcedureModel( {this.entityList, this.rowcount, this.statusMessage}); - GetOrderedProcedureModel.fromJson(Map json) { + GetOrderedProcedureModel.fromJson(Map json) { if (json['entityList'] != null) { - entityList = new List(); + entityList = []; json['entityList'].forEach((v) { - entityList.add(new EntityList.fromJson(v)); + entityList!.add(new EntityList.fromJson(v)); }); } rowcount = json['rowcount']; statusMessage = json['statusMessage']; } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); if (this.entityList != null) { - data['entityList'] = this.entityList.map((v) => v.toJson()).toList(); + data['entityList'] = this.entityList!.map((v) => v.toJson()).toList(); } data['rowcount'] = this.rowcount; data['statusMessage'] = this.statusMessage; @@ -29,60 +29,60 @@ class GetOrderedProcedureModel { } class EntityList { - String achiCode; - String appointmentDate; - int appointmentNo; - int categoryID; - String clinicDescription; - String cptCode; - int createdBy; - String createdOn; - String doctorName; - bool isApprovalCreated; - bool isApprovalRequired; - bool isCovered; - bool isInvoiced; - bool isReferralInvoiced; - bool isUncoveredByDoctor; - int lineItemNo; - String orderDate; - int orderNo; - int orderType; - String procedureId; - String procedureName; - String remarks; - String status; - String template; - int doctorID; + String? achiCode; + String? appointmentDate; + int? appointmentNo; + int? categoryID; + String? clinicDescription; + String? cptCode; + int? createdBy; + String? createdOn; + String? doctorName; + bool? isApprovalCreated; + bool? isApprovalRequired; + bool? isCovered; + bool? isInvoiced; + bool? isReferralInvoiced; + bool? isUncoveredByDoctor; + int? lineItemNo; + String? orderDate; + int? orderNo; + int? orderType; + String? procedureId; + String? procedureName; + String? remarks; + String? status; + String? template; + int? doctorID; EntityList( {this.achiCode, - this.appointmentDate, - this.appointmentNo, - this.categoryID, - this.clinicDescription, - this.cptCode, - this.createdBy, - this.createdOn, - this.doctorName, - this.isApprovalCreated, - this.isApprovalRequired, - this.isCovered, - this.isInvoiced, - this.isReferralInvoiced, - this.isUncoveredByDoctor, - this.lineItemNo, - this.orderDate, - this.orderNo, - this.orderType, - this.procedureId, - this.procedureName, - this.remarks, - this.status, - this.template, - this.doctorID}); + this.appointmentDate, + this.appointmentNo, + this.categoryID, + this.clinicDescription, + this.cptCode, + this.createdBy, + this.createdOn, + this.doctorName, + this.isApprovalCreated, + this.isApprovalRequired, + this.isCovered, + this.isInvoiced, + this.isReferralInvoiced, + this.isUncoveredByDoctor, + this.lineItemNo, + this.orderDate, + this.orderNo, + this.orderType, + this.procedureId, + this.procedureName, + this.remarks, + this.status, + this.template, + this.doctorID}); - EntityList.fromJson(Map json) { + EntityList.fromJson(Map json) { achiCode = json['achiCode']; doctorID = json['doctorID']; appointmentDate = json['appointmentDate']; @@ -110,8 +110,8 @@ class EntityList { template = json['template']; } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); data['achiCode'] = this.achiCode; data['doctorID'] = this.doctorID; data['appointmentDate'] = this.appointmentDate; diff --git a/lib/core/model/procedure/get_ordered_procedure_request_model.dart b/lib/core/model/procedure/get_ordered_procedure_request_model.dart index 5178ab14..dbfb75cd 100644 --- a/lib/core/model/procedure/get_ordered_procedure_request_model.dart +++ b/lib/core/model/procedure/get_ordered_procedure_request_model.dart @@ -1,9 +1,10 @@ class GetOrderedProcedureRequestModel { - String vidaAuthTokenID; - int patientMRN; - int appointmentNo; + String? vidaAuthTokenID; + int? patientMRN; + int? appointmentNo; - GetOrderedProcedureRequestModel({this.vidaAuthTokenID, this.patientMRN, this.appointmentNo}); + GetOrderedProcedureRequestModel( + {this.vidaAuthTokenID, this.patientMRN, this.appointmentNo}); GetOrderedProcedureRequestModel.fromJson(Map json) { vidaAuthTokenID = json['VidaAuthTokenID']; diff --git a/lib/core/model/procedure/get_procedure_model.dart b/lib/core/model/procedure/get_procedure_model.dart index 5c83b49b..732def33 100644 --- a/lib/core/model/procedure/get_procedure_model.dart +++ b/lib/core/model/procedure/get_procedure_model.dart @@ -1,25 +1,25 @@ class GetProcedureModel { - List entityList; - int rowcount; + List? entityList; + int? rowcount; dynamic statusMessage; GetProcedureModel({this.entityList, this.rowcount, this.statusMessage}); - GetProcedureModel.fromJson(Map json) { + GetProcedureModel.fromJson(Map json) { if (json['entityList'] != null) { - entityList = new List(); + entityList = []; json['entityList'].forEach((v) { - entityList.add(new EntityList.fromJson(v)); + entityList!.add(new EntityList.fromJson(v)); }); } rowcount = json['rowcount']; statusMessage = json['statusMessage']; } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); if (this.entityList != null) { - data['entityList'] = this.entityList.map((v) => v.toJson()).toList(); + data['entityList'] = this.entityList!.map((v) => v.toJson()).toList(); } data['rowcount'] = this.rowcount; data['statusMessage'] = this.statusMessage; @@ -28,34 +28,34 @@ class GetProcedureModel { } class EntityList { - bool allowedClinic; - String category; - String categoryID; - String genderValidation; - String group; - String orderedValidation; + bool? allowedClinic; + String? category; + String? categoryID; + String? genderValidation; + String? group; + String? orderedValidation; dynamic price; - String procedureId; - String procedureName; - String specialPermission; - String subGroup; - String template; + String? procedureId; + String? procedureName; + String? specialPermission; + String? subGroup; + String? template; EntityList( {this.allowedClinic, - this.category, - this.categoryID, - this.genderValidation, - this.group, - this.orderedValidation, - this.price, - this.procedureId, - this.procedureName, - this.specialPermission, - this.subGroup, - this.template}); + this.category, + this.categoryID, + this.genderValidation, + this.group, + this.orderedValidation, + this.price, + this.procedureId, + this.procedureName, + this.specialPermission, + this.subGroup, + this.template}); - EntityList.fromJson(Map json) { + EntityList.fromJson(Map json) { allowedClinic = json['allowedClinic']; category = json['category']; categoryID = json['categoryID']; @@ -70,8 +70,8 @@ class EntityList { template = json['template']; } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); data['allowedClinic'] = this.allowedClinic; data['category'] = this.category; data['categoryID'] = this.categoryID; diff --git a/lib/core/model/procedure/get_procedure_req_model.dart b/lib/core/model/procedure/get_procedure_req_model.dart index 6202a520..3fae7396 100644 --- a/lib/core/model/procedure/get_procedure_req_model.dart +++ b/lib/core/model/procedure/get_procedure_req_model.dart @@ -1,20 +1,20 @@ class GetProcedureReqModel { - int clinicId; - int patientMRN; - int pageSize; - int pageIndex; - List search; + int? clinicId; + int? patientMRN; + int? pageSize; + int? pageIndex; + List ?search; dynamic category; - String vidaAuthTokenID; + String ?vidaAuthTokenID; GetProcedureReqModel( {this.clinicId, - this.patientMRN, - this.pageSize, - this.pageIndex, - this.search, - this.category, - this.vidaAuthTokenID}); + this.patientMRN, + this.pageSize, + this.pageIndex, + this.search, + this.category, + this.vidaAuthTokenID}); GetProcedureReqModel.fromJson(Map json) { clinicId = json['ClinicId']; diff --git a/lib/core/model/procedure/post_procedure_req_model.dart b/lib/core/model/procedure/post_procedure_req_model.dart index b12563f8..7534da58 100644 --- a/lib/core/model/procedure/post_procedure_req_model.dart +++ b/lib/core/model/procedure/post_procedure_req_model.dart @@ -1,27 +1,27 @@ import 'ControlsModel.dart'; class PostProcedureReqModel { - int patientMRN; - int appointmentNo; - int episodeID; - List procedures; - String vidaAuthTokenID; + int? patientMRN; + int? appointmentNo; + int? episodeID; + List ?procedures; + String ?vidaAuthTokenID; PostProcedureReqModel( {this.patientMRN, - this.appointmentNo, - this.episodeID, - this.procedures, - this.vidaAuthTokenID}); + this.appointmentNo, + this.episodeID, + this.procedures, + this.vidaAuthTokenID}); PostProcedureReqModel.fromJson(Map json) { patientMRN = json['PatientMRN']; appointmentNo = json['AppointmentNo']; episodeID = json['EpisodeID']; if (json['Procedures'] != null) { - procedures = new List(); + procedures = []; json['Procedures'].forEach((v) { - procedures.add(new Procedures.fromJson(v)); + procedures!.add(new Procedures.fromJson(v)); }); } vidaAuthTokenID = json['VidaAuthTokenID']; @@ -33,7 +33,7 @@ class PostProcedureReqModel { data['AppointmentNo'] = this.appointmentNo; data['EpisodeID'] = this.episodeID; if (this.procedures != null) { - data['Procedures'] = this.procedures.map((v) => v.toJson()).toList(); + data['Procedures'] = this.procedures!.map((v) => v.toJson()).toList(); } data['VidaAuthTokenID'] = this.vidaAuthTokenID; return data; @@ -41,9 +41,9 @@ class PostProcedureReqModel { } class Procedures { - String procedure; - String category; - List controls; + String ?procedure; + String ?category; + List ?controls; Procedures({this.procedure, this.category, this.controls}); @@ -51,9 +51,9 @@ class Procedures { procedure = json['Procedure']; category = json['Category']; if (json['Controls'] != null) { - controls = new List(); + controls = []; json['Controls'].forEach((v) { - controls.add(new Controls.fromJson(v)); + controls!.add(new Controls.fromJson(v)); }); } } @@ -63,7 +63,7 @@ class Procedures { data['Procedure'] = this.procedure; data['Category'] = this.category; if (this.controls != null) { - data['Controls'] = this.controls.map((v) => v.toJson()).toList(); + data['Controls'] = this.controls!.map((v) => v.toJson()).toList(); } return data; } diff --git a/lib/core/model/procedure/procedure_category_list_model.dart b/lib/core/model/procedure/procedure_category_list_model.dart index 849e84e5..50048080 100644 --- a/lib/core/model/procedure/procedure_category_list_model.dart +++ b/lib/core/model/procedure/procedure_category_list_model.dart @@ -1,6 +1,6 @@ class ProcedureCategoryListModel { - List entityList; - int rowcount; + List? entityList; + int? rowcount; dynamic statusMessage; ProcedureCategoryListModel( @@ -8,9 +8,9 @@ class ProcedureCategoryListModel { ProcedureCategoryListModel.fromJson(Map json) { if (json['entityList'] != null) { - entityList = new List(); + entityList = []; json['entityList'].forEach((v) { - entityList.add(new EntityList.fromJson(v)); + entityList!.add(new EntityList.fromJson(v)); }); } rowcount = json['rowcount']; @@ -20,7 +20,7 @@ class ProcedureCategoryListModel { Map toJson() { final Map data = new Map(); if (this.entityList != null) { - data['entityList'] = this.entityList.map((v) => v.toJson()).toList(); + data['entityList'] = this.entityList!.map((v) => v.toJson()).toList(); } data['rowcount'] = this.rowcount; data['statusMessage'] = this.statusMessage; @@ -29,8 +29,8 @@ class ProcedureCategoryListModel { } class EntityList { - int categoryId; - String categoryName; + int? categoryId; + String? categoryName; EntityList({this.categoryId, this.categoryName}); diff --git a/lib/core/model/procedure/procedure_templateModel.dart b/lib/core/model/procedure/procedure_templateModel.dart index 3b12d646..38a05693 100644 --- a/lib/core/model/procedure/procedure_templateModel.dart +++ b/lib/core/model/procedure/procedure_templateModel.dart @@ -1,13 +1,13 @@ class ProcedureTempleteModel { - String setupID; - int projectID; - int clinicID; - int doctorID; - int templateID; - String templateName; - bool isActive; - int createdBy; - String createdOn; + String? setupID; + int? projectID; + int? clinicID; + int? doctorID; + int? templateID; + String? templateName; + bool? isActive; + int? createdBy; + String? createdOn; dynamic editedBy; dynamic editedOn; diff --git a/lib/core/model/procedure/procedure_template_details_model.dart b/lib/core/model/procedure/procedure_template_details_model.dart index 1fc797ae..6dec310f 100644 --- a/lib/core/model/procedure/procedure_template_details_model.dart +++ b/lib/core/model/procedure/procedure_template_details_model.dart @@ -1,58 +1,58 @@ class ProcedureTempleteDetailsModel { - String setupID; - int projectID; - int clinicID; - int doctorID; - int templateID; - String templateName; - String procedureID; - bool isActive; - int createdBy; - String createdOn; + String? setupID; + int? projectID; + int? clinicID; + int? doctorID; + int? templateID; + String? templateName; + String? procedureID; + bool ?isActive; + int? createdBy; + String? createdOn; dynamic editedBy; dynamic editedOn; - String procedureName; - String procedureNameN; - String alias; - String aliasN; - String categoryID; - String subGroupID; - String categoryDescription; - String categoryDescriptionN; - String categoryAlias; + String? procedureName; + String? procedureNameN; + String? alias; + String? aliasN; + String? categoryID; + String? subGroupID; + String? categoryDescription; + String? categoryDescriptionN; + String? categoryAlias; dynamic riskCategoryID; - String type = "1"; - String remarks; - int selectedType = 0; + String? type = "1"; + String? remarks; + int? selectedType = 0; ProcedureTempleteDetailsModel( {this.setupID, - this.projectID, - this.clinicID, - this.doctorID, - this.templateID, - this.procedureID, - this.isActive, - this.createdBy, - this.createdOn, - this.editedBy, - this.editedOn, - this.procedureName, - this.procedureNameN, - this.alias, - this.aliasN, - this.categoryID, - this.subGroupID, - this.riskCategoryID, - this.templateName, - this.categoryDescription, - this.categoryDescriptionN, - this.categoryAlias, - this.remarks, - this.type = "1", - this.selectedType = 0}); + this.projectID, + this.clinicID, + this.doctorID, + this.templateID, + this.procedureID, + this.isActive, + this.createdBy, + this.createdOn, + this.editedBy, + this.editedOn, + this.procedureName, + this.procedureNameN, + this.alias, + this.aliasN, + this.categoryID, + this.subGroupID, + this.riskCategoryID, + this.templateName, + this.categoryDescription, + this.categoryDescriptionN, + this.categoryAlias, + this.remarks, + this.type = "1", + this.selectedType = 0}); - ProcedureTempleteDetailsModel.fromJson(Map json) { + ProcedureTempleteDetailsModel.fromJson(Map json) { setupID = json['SetupID']; projectID = json['ProjectID']; clinicID = json['ClinicID']; @@ -77,8 +77,8 @@ class ProcedureTempleteDetailsModel { categoryAlias = json['CategoryAlias']; } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); data['SetupID'] = this.setupID; data['ProjectID'] = this.projectID; data['ClinicID'] = this.clinicID; @@ -105,12 +105,12 @@ class ProcedureTempleteDetailsModel { } } class ProcedureTempleteDetailsModelList { - List procedureTemplate = List(); - String templateName; - int templateId; + List procedureTemplate =[]; + String? templateName; + int? templateId; ProcedureTempleteDetailsModelList( - {this.templateName, this.templateId, ProcedureTempleteDetailsModel template}) { + {this.templateName, this.templateId, required ProcedureTempleteDetailsModel template}) { procedureTemplate.add(template); } } diff --git a/lib/core/model/procedure/procedure_template_details_request_model.dart b/lib/core/model/procedure/procedure_template_details_request_model.dart index 6df6fc73..99c9f814 100644 --- a/lib/core/model/procedure/procedure_template_details_request_model.dart +++ b/lib/core/model/procedure/procedure_template_details_request_model.dart @@ -1,32 +1,32 @@ class ProcedureTempleteDetailsRequestModel { - int doctorID; - String firstName; - int templateID; - String middleName; - String lastName; - String patientMobileNumber; - String patientIdentificationID; - int patientID; - String from; - String to; - int searchType; - String mobileNo; - String identificationNo; - int editedBy; - int projectID; - int clinicID; - String tokenID; - int languageID; - String stamp; - String iPAdress; - double versionID; - int channel; - String sessionID; - bool isLoginForDoctorApp; - bool patientOutSA; - String vidaAuthTokenID; - String vidaRefreshTokenID; - int deviceTypeID; + int? doctorID; + String? firstName; + int? templateID; + String? middleName; + String? lastName; + String? patientMobileNumber; + String? patientIdentificationID; + int? patientID; + String? from; + String? to; + int? searchType; + String? mobileNo; + String? identificationNo; + int? editedBy; + int? projectID; + int? clinicID; + String? tokenID; + int? languageID; + String? stamp; + String? iPAdress; + double? versionID; + int? channel; + String? sessionID; + bool? isLoginForDoctorApp; + bool? patientOutSA; + String? vidaAuthTokenID; + String? vidaRefreshTokenID; + int? deviceTypeID; ProcedureTempleteDetailsRequestModel( {this.doctorID, diff --git a/lib/core/model/procedure/procedure_valadate_model.dart b/lib/core/model/procedure/procedure_valadate_model.dart index 3a3e23cf..431d369a 100644 --- a/lib/core/model/procedure/procedure_valadate_model.dart +++ b/lib/core/model/procedure/procedure_valadate_model.dart @@ -1,6 +1,6 @@ class ProcedureValadteModel { - List entityList; - int rowcount; + List? entityList; + int? rowcount; dynamic statusMessage; dynamic success; @@ -9,9 +9,9 @@ class ProcedureValadteModel { ProcedureValadteModel.fromJson(Map json) { if (json['entityList'] != null) { - entityList = new List(); + entityList = []; json['entityList'].forEach((v) { - entityList.add(new EntityList.fromJson(v)); + entityList!.add(new EntityList.fromJson(v)); }); } rowcount = json['rowcount']; @@ -22,7 +22,7 @@ class ProcedureValadteModel { Map toJson() { final Map data = new Map(); if (this.entityList != null) { - data['entityList'] = this.entityList.map((v) => v.toJson()).toList(); + data['entityList'] = this.entityList!.map((v) => v.toJson()).toList(); } data['rowcount'] = this.rowcount; data['statusMessage'] = this.statusMessage; @@ -32,8 +32,8 @@ class ProcedureValadteModel { } class EntityList { - String procedureId; - List warringMessages; + String? procedureId; + List? warringMessages; EntityList({this.procedureId, this.warringMessages}); diff --git a/lib/core/model/procedure/procedure_valadate_request_model.dart b/lib/core/model/procedure/procedure_valadate_request_model.dart index 0b872b93..581ff41f 100644 --- a/lib/core/model/procedure/procedure_valadate_request_model.dart +++ b/lib/core/model/procedure/procedure_valadate_request_model.dart @@ -1,9 +1,9 @@ class ProcedureValadteRequestModel { - String vidaAuthTokenID; - int patientMRN; - int appointmentNo; - int episodeID; - List procedure; + String? vidaAuthTokenID; + int? patientMRN; + int? appointmentNo; + int? episodeID; + List? procedure; ProcedureValadteRequestModel( {this.vidaAuthTokenID, diff --git a/lib/core/model/procedure/update_procedure_request_model.dart b/lib/core/model/procedure/update_procedure_request_model.dart index aee39879..a6b92d16 100644 --- a/lib/core/model/procedure/update_procedure_request_model.dart +++ b/lib/core/model/procedure/update_procedure_request_model.dart @@ -1,13 +1,13 @@ import 'ControlsModel.dart'; class UpdateProcedureRequestModel { - int orderNo; - int patientMRN; - int appointmentNo; - int episodeID; - int lineItemNo; - ProcedureDetail procedureDetail; - String vidaAuthTokenID; + int? orderNo; + int? patientMRN; + int? appointmentNo; + int? episodeID; + int? lineItemNo; + ProcedureDetail? procedureDetail; + String? vidaAuthTokenID; UpdateProcedureRequestModel( {this.orderNo, @@ -38,7 +38,7 @@ class UpdateProcedureRequestModel { data['EpisodeID'] = this.episodeID; data['LineItemNo'] = this.lineItemNo; if (this.procedureDetail != null) { - data['procedureDetail'] = this.procedureDetail.toJson(); + data['procedureDetail'] = this.procedureDetail!.toJson(); } data['VidaAuthTokenID'] = this.vidaAuthTokenID; return data; @@ -46,9 +46,9 @@ class UpdateProcedureRequestModel { } class ProcedureDetail { - String procedure; - String category; - List controls; + String? procedure; + String? category; + List? controls; ProcedureDetail({this.procedure, this.category, this.controls}); @@ -56,9 +56,9 @@ class ProcedureDetail { procedure = json['Procedure']; category = json['Category']; if (json['Controls'] != null) { - controls = new List(); + controls = []; json['Controls'].forEach((v) { - controls.add(new Controls.fromJson(v)); + controls!.add(new Controls.fromJson(v)); }); } } @@ -68,7 +68,7 @@ class ProcedureDetail { data['Procedure'] = this.procedure; data['Category'] = this.category; if (this.controls != null) { - data['Controls'] = this.controls.map((v) => v.toJson()).toList(); + data['Controls'] = this.controls!.map((v) => v.toJson()).toList(); } return data; } diff --git a/lib/core/model/radiology/final_radiology.dart b/lib/core/model/radiology/final_radiology.dart index e09f269a..ae307fdb 100644 --- a/lib/core/model/radiology/final_radiology.dart +++ b/lib/core/model/radiology/final_radiology.dart @@ -8,17 +8,17 @@ class FinalRadiology { dynamic invoiceNo; dynamic doctorID; dynamic clinicID; - DateTime orderDate; - DateTime reportDate; + DateTime? orderDate; + DateTime ?reportDate; dynamic reportData; dynamic imageURL; dynamic procedureID; dynamic appodynamicmentNo; dynamic dIAPacsURL; - bool isRead; + bool? isRead; dynamic readOn; var admissionNo; - bool isInOutPatient; + bool ?isInOutPatient; dynamic actualDoctorRate; dynamic clinicDescription; dynamic dIAPACSURL; @@ -28,8 +28,8 @@ class FinalRadiology { dynamic doctorTitle; dynamic gender; dynamic genderDescription; - bool isActiveDoctorProfile; - bool isExecludeDoctor; + bool? isActiveDoctorProfile; + bool ?isExecludeDoctor; dynamic isInOutPatientDescription; dynamic isInOutPatientDescriptionN; dynamic nationalityFlagURL; @@ -39,53 +39,53 @@ class FinalRadiology { dynamic qR; dynamic reportDataHTML; dynamic reportDataTextdynamic; - List speciality; - bool isCVI; - bool isRadMedicalReport; - bool isLiveCareAppodynamicment; + List? speciality; + bool ?isCVI; + bool ?isRadMedicalReport; + bool ?isLiveCareAppodynamicment; FinalRadiology( {this.setupID, - this.projectID, - this.patientID, - this.invoiceLineItemNo, - this.invoiceNo, - this.doctorID, - this.clinicID, - this.orderDate, - this.reportDate, - this.reportData, - this.imageURL, - this.procedureID, - this.appodynamicmentNo, - this.dIAPacsURL, - this.isRead, - this.readOn, - this.admissionNo, - this.isInOutPatient, - this.actualDoctorRate, - this.clinicDescription, - this.dIAPACSURL, - this.doctorImageURL, - this.doctorName, - this.doctorRate, - this.doctorTitle, - this.gender, - this.genderDescription, - this.isActiveDoctorProfile, - this.isExecludeDoctor, - this.isInOutPatientDescription, - this.isInOutPatientDescriptionN, - this.nationalityFlagURL, - this.noOfPatientsRate, - this.orderNo, - this.projectName, - this.qR, - this.reportDataHTML, - this.reportDataTextdynamic, - this.speciality, - this.isCVI, - this.isRadMedicalReport,this.isLiveCareAppodynamicment}); + this.projectID, + this.patientID, + this.invoiceLineItemNo, + this.invoiceNo, + this.doctorID, + this.clinicID, + this.orderDate, + this.reportDate, + this.reportData, + this.imageURL, + this.procedureID, + this.appodynamicmentNo, + this.dIAPacsURL, + this.isRead, + this.readOn, + this.admissionNo, + this.isInOutPatient, + this.actualDoctorRate, + this.clinicDescription, + this.dIAPACSURL, + this.doctorImageURL, + this.doctorName, + this.doctorRate, + this.doctorTitle, + this.gender, + this.genderDescription, + this.isActiveDoctorProfile, + this.isExecludeDoctor, + this.isInOutPatientDescription, + this.isInOutPatientDescriptionN, + this.nationalityFlagURL, + this.noOfPatientsRate, + this.orderNo, + this.projectName, + this.qR, + this.reportDataHTML, + this.reportDataTextdynamic, + this.speciality, + this.isCVI, + this.isRadMedicalReport,this.isLiveCareAppodynamicment}); FinalRadiology.fromJson(Map json) { try { @@ -128,7 +128,7 @@ class FinalRadiology { isLiveCareAppodynamicment = json['IsLiveCareAppointment']; reportDataHTML = json['ReportDataHTML']; reportDataTextdynamic = json['ReportDataTextdynamic']; - // speciality = json['Speciality'].cast(); + // speciality = json['Speciality'].cast(); isCVI = json['isCVI']; isRadMedicalReport = json['isRadMedicalReport']; @@ -186,9 +186,9 @@ class FinalRadiology { class FinalRadiologyList { dynamic filterName = ""; - List finalRadiologyList = List(); + List finalRadiologyList = []; - FinalRadiologyList({this.filterName, FinalRadiology finalRadiology}) { + FinalRadiologyList({this.filterName, required FinalRadiology finalRadiology}) { finalRadiologyList.add(finalRadiology); } } diff --git a/lib/core/model/radiology/request_patient_rad_orders_details.dart b/lib/core/model/radiology/request_patient_rad_orders_details.dart index 9e3458d5..7f39ee25 100644 --- a/lib/core/model/radiology/request_patient_rad_orders_details.dart +++ b/lib/core/model/radiology/request_patient_rad_orders_details.dart @@ -1,24 +1,24 @@ class RequestPatientRadOrdersDetails { - int projectID; - int orderNo; - int invoiceNo; - String setupID; - String procedureID; - bool isMedicalReport; - bool isCVI; - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - String sessionID; - bool isDentalAllowedBackend; - int deviceTypeID; - int patientID; - String tokenID; - int patientTypeID; - int patientType; + int? projectID; + int? orderNo; + int? invoiceNo; + String? setupID; + String? procedureID; + bool? isMedicalReport; + bool? isCVI; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; + String? sessionID; + bool? isDentalAllowedBackend; + int? deviceTypeID; + int? patientID; + String? tokenID; + int? patientTypeID; + int? patientType; RequestPatientRadOrdersDetails( {this.projectID, diff --git a/lib/core/model/radiology/request_send_rad_report_email.dart b/lib/core/model/radiology/request_send_rad_report_email.dart index 6d68653d..3b9e961a 100644 --- a/lib/core/model/radiology/request_send_rad_report_email.dart +++ b/lib/core/model/radiology/request_send_rad_report_email.dart @@ -1,30 +1,30 @@ class RequestSendRadReportEmail { - int channel; - String clinicName; - String dateofBirth; - int deviceTypeID; - String doctorName; - String generalid; - int invoiceNo; - String iPAdress; - bool isDentalAllowedBackend; - int languageID; - String orderDate; - int patientID; - String patientIditificationNum; - String patientMobileNumber; - String patientName; - int patientOutSA; - int patientType; - int patientTypeID; - int projectID; - String projectName; - String radResult; - String sessionID; - String setupID; - String to; - String tokenID; - double versionID; + int? channel; + String? clinicName; + String? dateofBirth; + int? deviceTypeID; + String? doctorName; + String? generalid; + int? invoiceNo; + String? iPAdress; + bool ?isDentalAllowedBackend; + int? languageID; + String? orderDate; + int? patientID; + String? patientIditificationNum; + String? patientMobileNumber; + String? patientName; + int? patientOutSA; + int? patientType; + int? patientTypeID; + int? projectID; + String? projectName; + String? radResult; + String? sessionID; + String? setupID; + String? to; + String? tokenID; + double? versionID; RequestSendRadReportEmail( {this.channel, @@ -54,7 +54,7 @@ class RequestSendRadReportEmail { this.tokenID, this.versionID}); - RequestSendRadReportEmail.fromJson(Map json) { + RequestSendRadReportEmail.fromJson(Map json) { channel = json['Channel']; clinicName = json['ClinicName']; dateofBirth = json['DateofBirth']; @@ -83,8 +83,8 @@ class RequestSendRadReportEmail { versionID = json['VersionID']; } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); data['Channel'] = this.channel; data['ClinicName'] = this.clinicName; data['DateofBirth'] = this.dateofBirth; diff --git a/lib/core/model/referral/DischargeReferralPatient.dart b/lib/core/model/referral/DischargeReferralPatient.dart index dff63bfc..3b9e961a 100644 --- a/lib/core/model/referral/DischargeReferralPatient.dart +++ b/lib/core/model/referral/DischargeReferralPatient.dart @@ -1,218 +1,116 @@ -import 'package:doctor_app_flutter/util/date-utils.dart'; +class RequestSendRadReportEmail { + int? channel; + String? clinicName; + String? dateofBirth; + int? deviceTypeID; + String? doctorName; + String? generalid; + int? invoiceNo; + String? iPAdress; + bool ?isDentalAllowedBackend; + int? languageID; + String? orderDate; + int? patientID; + String? patientIditificationNum; + String? patientMobileNumber; + String? patientName; + int? patientOutSA; + int? patientType; + int? patientTypeID; + int? projectID; + String? projectName; + String? radResult; + String? sessionID; + String? setupID; + String? to; + String? tokenID; + double? versionID; -class DischargeReferralPatient { - dynamic rowID; - int projectID; - int lineItemNo; - int doctorID; - int patientID; - String doctorName; - dynamic doctorNameN; - String firstName; - String middleName; - String lastName; - dynamic firstNameN; - dynamic middleNameN; - dynamic lastNameN; - int gender; - String dateofBirth; - String mobileNumber; - String emailAddress; - String patientIdentificationNo; - int patientType; - String admissionNo; - String admissionDate; - String roomID; - String bedID; - dynamic nursingStationID; - dynamic description; - String nationalityName; - dynamic nationalityNameN; - int referralDoctor; - int referringDoctor; - int referralClinic; - int referringClinic; - int referralStatus; - DateTime referralDate; - String referringDoctorRemarks; - String referredDoctorRemarks; - String referralResponseOn; - int priority; - int frequency; - String mAXResponseTime; - String dischargeDate; - dynamic clinicID; - String age; - String clinicDescription; - String frequencyDescription; - String genderDescription; - bool isDoctorLate; - bool isDoctorResponse; - String nursingStationName; - String priorityDescription; - String referringClinicDescription; - String referringDoctorName; - - DischargeReferralPatient( - {this.rowID, - this.projectID, - this.lineItemNo, - this.doctorID, - this.patientID, - this.doctorName, - this.doctorNameN, - this.firstName, - this.middleName, - this.lastName, - this.firstNameN, - this.middleNameN, - this.lastNameN, - this.gender, + RequestSendRadReportEmail( + {this.channel, + this.clinicName, this.dateofBirth, - this.mobileNumber, - this.emailAddress, - this.patientIdentificationNo, + this.deviceTypeID, + this.doctorName, + this.generalid, + this.invoiceNo, + this.iPAdress, + this.isDentalAllowedBackend, + this.languageID, + this.orderDate, + this.patientID, + this.patientIditificationNum, + this.patientMobileNumber, + this.patientName, + this.patientOutSA, this.patientType, - this.admissionNo, - this.admissionDate, - this.roomID, - this.bedID, - this.nursingStationID, - this.description, - this.nationalityName, - this.nationalityNameN, - this.referralDoctor, - this.referringDoctor, - this.referralClinic, - this.referringClinic, - this.referralStatus, - this.referralDate, - this.referringDoctorRemarks, - this.referredDoctorRemarks, - this.referralResponseOn, - this.priority, - this.frequency, - this.mAXResponseTime, - this.dischargeDate, - this.clinicID, - this.age, - this.clinicDescription, - this.frequencyDescription, - this.genderDescription, - this.isDoctorLate, - this.isDoctorResponse, - this.nursingStationName, - this.priorityDescription, - this.referringClinicDescription, - this.referringDoctorName}); + this.patientTypeID, + this.projectID, + this.projectName, + this.radResult, + this.sessionID, + this.setupID, + this.to, + this.tokenID, + this.versionID}); - DischargeReferralPatient.fromJson(Map json) { - rowID = json['RowID']; - projectID = json['ProjectID']; - lineItemNo = json['LineItemNo']; - doctorID = json['DoctorID']; - patientID = json['PatientID']; - doctorName = json['DoctorName']; - doctorNameN = json['DoctorNameN']; - firstName = json['FirstName']; - middleName = json['MiddleName']; - lastName = json['LastName']; - firstNameN = json['FirstNameN']; - middleNameN = json['MiddleNameN']; - lastNameN = json['LastNameN']; - gender = json['Gender']; + RequestSendRadReportEmail.fromJson(Map json) { + channel = json['Channel']; + clinicName = json['ClinicName']; dateofBirth = json['DateofBirth']; - mobileNumber = json['MobileNumber']; - emailAddress = json['EmailAddress']; - patientIdentificationNo = json['PatientIdentificationNo']; + deviceTypeID = json['DeviceTypeID']; + doctorName = json['DoctorName']; + generalid = json['generalid']; + invoiceNo = json['InvoiceNo']; + iPAdress = json['IPAdress']; + isDentalAllowedBackend = json['isDentalAllowedBackend']; + languageID = json['LanguageID']; + orderDate = json['OrderDate']; + patientID = json['PatientID']; + patientIditificationNum = json['PatientIditificationNum']; + patientMobileNumber = json['PatientMobileNumber']; + patientName = json['PatientName']; + patientOutSA = json['PatientOutSA']; patientType = json['PatientType']; - admissionNo = json['AdmissionNo']; - admissionDate = json['AdmissionDate']; - roomID = json['RoomID']; - bedID = json['BedID']; - nursingStationID = json['NursingStationID']; - description = json['Description']; - nationalityName = json['NationalityName']; - nationalityNameN = json['NationalityNameN']; - referralDoctor = json['ReferralDoctor']; - referringDoctor = json['ReferringDoctor']; - referralClinic = json['ReferralClinic']; - referringClinic = json['ReferringClinic']; - referralStatus = json['ReferralStatus']; - referralDate = AppDateUtils.convertStringToDate(json['ReferralDate']); - referringDoctorRemarks = json['ReferringDoctorRemarks']; - referredDoctorRemarks = json['ReferredDoctorRemarks']; - referralResponseOn = json['ReferralResponseOn']; - priority = json['Priority']; - frequency = json['Frequency']; - mAXResponseTime = json['MAXResponseTime']; - dischargeDate = json['DischargeDate']; - clinicID = json['ClinicID']; - age = json['Age']; - clinicDescription = json['ClinicDescription']; - frequencyDescription = json['FrequencyDescription']; - genderDescription = json['GenderDescription']; - isDoctorLate = json['IsDoctorLate']; - isDoctorResponse = json['IsDoctorResponse']; - nursingStationName = json['NursingStationName']; - priorityDescription = json['PriorityDescription']; - referringClinicDescription = json['ReferringClinicDescription']; - referringDoctorName = json['ReferringDoctorName']; + patientTypeID = json['PatientTypeID']; + projectID = json['ProjectID']; + projectName = json['ProjectName']; + radResult = json['RadResult']; + sessionID = json['SessionID']; + setupID = json['SetupID']; + to = json['To']; + tokenID = json['TokenID']; + versionID = json['VersionID']; } - Map toJson() { - final Map data = new Map(); - data['RowID'] = this.rowID; - data['ProjectID'] = this.projectID; - data['LineItemNo'] = this.lineItemNo; - data['DoctorID'] = this.doctorID; - data['PatientID'] = this.patientID; - data['DoctorName'] = this.doctorName; - data['DoctorNameN'] = this.doctorNameN; - data['FirstName'] = this.firstName; - data['MiddleName'] = this.middleName; - data['LastName'] = this.lastName; - data['FirstNameN'] = this.firstNameN; - data['MiddleNameN'] = this.middleNameN; - data['LastNameN'] = this.lastNameN; - data['Gender'] = this.gender; + Map toJson() { + final Map data = new Map(); + data['Channel'] = this.channel; + data['ClinicName'] = this.clinicName; data['DateofBirth'] = this.dateofBirth; - data['MobileNumber'] = this.mobileNumber; - data['EmailAddress'] = this.emailAddress; - data['PatientIdentificationNo'] = this.patientIdentificationNo; + data['DeviceTypeID'] = this.deviceTypeID; + data['DoctorName'] = this.doctorName; + data['generalid'] = this.generalid; + data['InvoiceNo'] = this.invoiceNo; + data['IPAdress'] = this.iPAdress; + data['isDentalAllowedBackend'] = this.isDentalAllowedBackend; + data['LanguageID'] = this.languageID; + data['OrderDate'] = this.orderDate; + data['PatientID'] = this.patientID; + data['PatientIditificationNum'] = this.patientIditificationNum; + data['PatientMobileNumber'] = this.patientMobileNumber; + data['PatientName'] = this.patientName; + data['PatientOutSA'] = this.patientOutSA; data['PatientType'] = this.patientType; - data['AdmissionNo'] = this.admissionNo; - data['AdmissionDate'] = this.admissionDate; - data['RoomID'] = this.roomID; - data['BedID'] = this.bedID; - data['NursingStationID'] = this.nursingStationID; - data['Description'] = this.description; - data['NationalityName'] = this.nationalityName; - data['NationalityNameN'] = this.nationalityNameN; - data['ReferralDoctor'] = this.referralDoctor; - data['ReferringDoctor'] = this.referringDoctor; - data['ReferralClinic'] = this.referralClinic; - data['ReferringClinic'] = this.referringClinic; - data['ReferralStatus'] = this.referralStatus; - data['ReferralDate'] = this.referralDate; - data['ReferringDoctorRemarks'] = this.referringDoctorRemarks; - data['ReferredDoctorRemarks'] = this.referredDoctorRemarks; - data['ReferralResponseOn'] = this.referralResponseOn; - data['Priority'] = this.priority; - data['Frequency'] = this.frequency; - data['MAXResponseTime'] = this.mAXResponseTime; - data['DischargeDate'] = this.dischargeDate; - data['ClinicID'] = this.clinicID; - data['Age'] = this.age; - data['ClinicDescription'] = this.clinicDescription; - data['FrequencyDescription'] = this.frequencyDescription; - data['GenderDescription'] = this.genderDescription; - data['IsDoctorLate'] = this.isDoctorLate; - data['IsDoctorResponse'] = this.isDoctorResponse; - data['NursingStationName'] = this.nursingStationName; - data['PriorityDescription'] = this.priorityDescription; - data['ReferringClinicDescription'] = this.referringClinicDescription; - data['ReferringDoctorName'] = this.referringDoctorName; + data['PatientTypeID'] = this.patientTypeID; + data['ProjectID'] = this.projectID; + data['ProjectName'] = this.projectName; + data['RadResult'] = this.radResult; + data['SessionID'] = this.sessionID; + data['SetupID'] = this.setupID; + data['To'] = this.to; + data['TokenID'] = this.tokenID; + data['VersionID'] = this.versionID; return data; } } diff --git a/lib/core/model/referral/MyReferralPatientModel.dart b/lib/core/model/referral/MyReferralPatientModel.dart index 4f00f455..094c0701 100644 --- a/lib/core/model/referral/MyReferralPatientModel.dart +++ b/lib/core/model/referral/MyReferralPatientModel.dart @@ -2,140 +2,149 @@ import 'package:doctor_app_flutter/util/date-utils.dart'; class MyReferralPatientModel { dynamic rowID; - int projectID; - int lineItemNo; - int doctorID; - int patientID; - String doctorName; + int? projectID; + int? lineItemNo; + int? doctorID; + int? patientID; + String? doctorName; dynamic doctorNameN; - String firstName; - String middleName; - String lastName; + String? firstName; + String? middleName; + String? lastName; dynamic firstNameN; dynamic middleNameN; dynamic lastNameN; - int gender; - String dateofBirth; - String mobileNumber; - String emailAddress; - String patientIdentificationNo; - int patientType; - String admissionNo; - String admissionDate; - String roomID; - String bedID; + int? gender; + String? dateofBirth; + String? mobileNumber; + String? emailAddress; + String? patientIdentificationNo; + int? patientType; + String? admissionNo; + String? admissionDate; + String? roomID; + String? bedID; dynamic nursingStationID; dynamic description; - String nationalityName; + String? nationalityName; dynamic nationalityNameN; - String clinicDescription; - String clinicDescriptionN; - int referralDoctor; - int referringDoctor; - int referralClinic; - int referringClinic; - int referralStatus; - DateTime referralDate; - String referringDoctorRemarks; - String referredDoctorRemarks; - String referralResponseOn; - int priority; - int frequency; - String mAXResponseTime; - int episodeID; - int appointmentNo; - String appointmentDate; - int appointmentType; - int patientMRN; - String createdOn; - int clinicID; - String nationalityID; - String age; - String doctorImageURL; - String frequencyDescription; - String genderDescription; - bool isDoctorLate; - bool isDoctorResponse; - String nationalityFlagURL; - String nursingStationName; - String priorityDescription; - String referringClinicDescription; - String referringDoctorName; - int referalStatus; - String sourceSetupID; - int sourceProjectId; - String targetSetupID; - int targetProjectId; - int targetClinicID; - int targetDoctorID; - int sourceAppointmentNo; - int targetAppointmentNo; - String remarksFromSource; + String? clinicDescription; + String? clinicDescriptionN; + int? referralDoctor; + int? referringDoctor; + int? referralClinic; + int? referringClinic; + int? referralStatus; + DateTime? referralDate; + String? referringDoctorRemarks; + String? referredDoctorRemarks; + String? referralResponseOn; + int? priority; + int? frequency; + String? mAXResponseTime; + int? episodeID; + int? appointmentNo; + String? appointmentDate; + int? appointmentType; + int? patientMRN; + String? createdOn; + int? clinicID; + String? nationalityID; + String? age; + String? doctorImageURL; + String? frequencyDescription; + String? genderDescription; + bool? isDoctorLate; + bool? isDoctorResponse; + String? nationalityFlagURL; + String? nursingStationName; + String? priorityDescription; + String? referringClinicDescription; + String? referringDoctorName; + int? referalStatus; + String? sourceSetupID; + int? sourceProjectId; + String? targetSetupID; + int? targetProjectId; + int? targetClinicID; + int? targetDoctorID; + int? sourceAppointmentNo; + int? targetAppointmentNo; + String? remarksFromSource; MyReferralPatientModel( {this.rowID, - this.projectID, - this.lineItemNo, - this.doctorID, - this.patientID, - this.doctorName, - this.doctorNameN, - this.firstName, - this.middleName, - this.lastName, - this.firstNameN, - this.middleNameN, - this.lastNameN, - this.gender, - this.dateofBirth, - this.mobileNumber, - this.emailAddress, - this.patientIdentificationNo, - this.patientType, - this.admissionNo, - this.admissionDate, - this.roomID, - this.bedID, - this.nursingStationID, - this.description, - this.nationalityName, - this.nationalityNameN, - this.clinicDescription, - this.clinicDescriptionN, - this.referralDoctor, - this.referringDoctor, - this.referralClinic, - this.referringClinic, - this.referralStatus, - this.referralDate, - this.referringDoctorRemarks, - this.referredDoctorRemarks, - this.referralResponseOn, - this.priority, - this.frequency, - this.mAXResponseTime, - this.episodeID, - this.appointmentNo, - this.appointmentDate, - this.appointmentType, - this.patientMRN, - this.createdOn, - this.clinicID, - this.nationalityID, - this.age, - this.doctorImageURL, - this.frequencyDescription, - this.genderDescription, - this.isDoctorLate, - this.isDoctorResponse, - this.nationalityFlagURL, - this.nursingStationName, - this.priorityDescription, - this.referringClinicDescription, - this.referringDoctorName, - this.referalStatus, this.sourceSetupID, this.sourceAppointmentNo, this.sourceProjectId, this.targetProjectId, this.targetAppointmentNo, this.targetClinicID, this.targetSetupID, this.targetDoctorID, this.remarksFromSource}); + this.projectID, + this.lineItemNo, + this.doctorID, + this.patientID, + this.doctorName, + this.doctorNameN, + this.firstName, + this.middleName, + this.lastName, + this.firstNameN, + this.middleNameN, + this.lastNameN, + this.gender, + this.dateofBirth, + this.mobileNumber, + this.emailAddress, + this.patientIdentificationNo, + this.patientType, + this.admissionNo, + this.admissionDate, + this.roomID, + this.bedID, + this.nursingStationID, + this.description, + this.nationalityName, + this.nationalityNameN, + this.clinicDescription, + this.clinicDescriptionN, + this.referralDoctor, + this.referringDoctor, + this.referralClinic, + this.referringClinic, + this.referralStatus, + this.referralDate, + this.referringDoctorRemarks, + this.referredDoctorRemarks, + this.referralResponseOn, + this.priority, + this.frequency, + this.mAXResponseTime, + this.episodeID, + this.appointmentNo, + this.appointmentDate, + this.appointmentType, + this.patientMRN, + this.createdOn, + this.clinicID, + this.nationalityID, + this.age, + this.doctorImageURL, + this.frequencyDescription, + this.genderDescription, + this.isDoctorLate, + this.isDoctorResponse, + this.nationalityFlagURL, + this.nursingStationName, + this.priorityDescription, + this.referringClinicDescription, + this.referringDoctorName, + this.referalStatus, + this.sourceSetupID, + this.sourceAppointmentNo, + this.sourceProjectId, + this.targetProjectId, + this.targetAppointmentNo, + this.targetClinicID, + this.targetSetupID, + this.targetDoctorID, + this.remarksFromSource}); - MyReferralPatientModel.fromJson(Map json) { + MyReferralPatientModel.fromJson(Map json) { rowID = json['RowID']; referalStatus = json['ReferalStatus']; projectID = json['ProjectID']; @@ -172,10 +181,10 @@ class MyReferralPatientModel { referringClinic = json['ReferringClinic']; referralStatus = json["ReferralStatus"] is String ? json['ReferralStatus'] == "Accepted" - ? 46 - : json['ReferralStatus'] == "Pending" - ? 1 - : 0 + ? 46 + : json['ReferralStatus'] == "Pending" + ? 1 + : 0 : json["ReferralStatus"]; try { referralDate = AppDateUtils.getDateTimeFromString(json['ReferralDate']); @@ -219,11 +228,10 @@ class MyReferralPatientModel { sourceAppointmentNo = json['SourceAppointmentNo']; targetAppointmentNo = json['TargetAppointmentNo']; remarksFromSource = json['RemarksFromSource']; - } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); data['RowID'] = this.rowID; data['ReferalStatus'] = this.referalStatus; data['ProjectID'] = this.projectID; @@ -298,6 +306,6 @@ class MyReferralPatientModel { } get patientName { - return this.firstName + " " + this.lastName; + return this.firstName! + " " + this.lastName!; } } diff --git a/lib/core/model/referral/MyReferralPatientRequestModel.dart b/lib/core/model/referral/MyReferralPatientRequestModel.dart index 08b98a99..885653a1 100644 --- a/lib/core/model/referral/MyReferralPatientRequestModel.dart +++ b/lib/core/model/referral/MyReferralPatientRequestModel.dart @@ -1,27 +1,27 @@ class MyReferralPatientRequestModel { - int channel; - int clinicID; - int doctorID; - int editedBy; - String firstName; - String from; - String iPAdress; - bool isLoginForDoctorApp; - int languageID; - String lastName; - String middleName; - int patientID; - String patientIdentificationID; - String patientMobileNumber; - bool patientOutSA; - int patientTypeID; - int projectID; - String sessionID; - String stamp; - String to; - String tokenID; - double versionID; - String vidaAuthTokenID; + int? channel; + int? clinicID; + int? doctorID; + int? editedBy; + String? firstName; + String? from; + String? iPAdress; + bool? isLoginForDoctorApp; + int? languageID; + String? lastName; + String? middleName; + int? patientID; + String? patientIdentificationID; + String? patientMobileNumber; + bool? patientOutSA; + int? patientTypeID; + int? projectID; + String? sessionID; + String? stamp; + String? to; + String? tokenID; + double? versionID; + String? vidaAuthTokenID; MyReferralPatientRequestModel( {this.channel, diff --git a/lib/core/model/referral/ReferralRequest.dart b/lib/core/model/referral/ReferralRequest.dart index b3ad1f03..e88b0e9b 100644 --- a/lib/core/model/referral/ReferralRequest.dart +++ b/lib/core/model/referral/ReferralRequest.dart @@ -1,28 +1,28 @@ class ReferralRequest { - String roomID; - String referralClinic; - String referralDoctor; - int createdBy; - int editedBy; - int patientID; - int patientTypeID; - int referringClinic; - int referringDoctor; - int projectID; - int admissionNo; - String referringDoctorRemarks; - String priority; - String frequency; - String extension; - int languageID; - String stamp; - String iPAdress; - double versionID; - int channel; - String tokenID; - String sessionID; - bool isLoginForDoctorApp; - bool patientOutSA; + String? roomID; + String? referralClinic; + String? referralDoctor; + int? createdBy; + int? editedBy; + int? patientID; + int? patientTypeID; + int? referringClinic; + int? referringDoctor; + int? projectID; + int? admissionNo; + String? referringDoctorRemarks; + String? priority; + String? frequency; + String? extension; + int? languageID; + String? stamp; + String? iPAdress; + double? versionID; + int? channel; + String? tokenID; + String? sessionID; + bool? isLoginForDoctorApp; + bool? patientOutSA; ReferralRequest( {this.roomID, diff --git a/lib/core/model/referral/add_referred_remarks_request.dart b/lib/core/model/referral/add_referred_remarks_request.dart index 14089513..5b7edbc6 100644 --- a/lib/core/model/referral/add_referred_remarks_request.dart +++ b/lib/core/model/referral/add_referred_remarks_request.dart @@ -1,19 +1,19 @@ class AddReferredRemarksRequestModel { - int projectID; - int admissionNo; - int lineItemNo; - String referredDoctorRemarks; - int editedBy; - int referalStatus; - bool isLoginForDoctorApp; - String iPAdress; - bool patientOutSA; - String tokenID; - int languageID; - double versionID; - int channel; - String sessionID; - int deviceTypeID; + int? projectID; + int? admissionNo; + int? lineItemNo; + String? referredDoctorRemarks; + int? editedBy; + int? referalStatus; + bool? isLoginForDoctorApp; + String? iPAdress; + bool? patientOutSA; + String? tokenID; + int? languageID; + double? versionID; + int? channel; + String? sessionID; + int? deviceTypeID; AddReferredRemarksRequestModel( {this.projectID, diff --git a/lib/core/model/search_drug/get_medication_response_model.dart b/lib/core/model/search_drug/get_medication_response_model.dart index a42a8b47..24079b5e 100644 --- a/lib/core/model/search_drug/get_medication_response_model.dart +++ b/lib/core/model/search_drug/get_medication_response_model.dart @@ -1,13 +1,13 @@ class GetMedicationResponseModel { - String description; - String genericName; - int itemId; - String keywords; + String? description; + String? genericName; + int ?itemId; + String? keywords; dynamic price; dynamic quantity; dynamic mediSpanGPICode; - bool isNarcotic; - String uom; + bool ?isNarcotic; + String? uom; GetMedicationResponseModel( {this.description, this.genericName, @@ -19,7 +19,7 @@ class GetMedicationResponseModel { this.uom, this.mediSpanGPICode}); - GetMedicationResponseModel.fromJson(Map json) { + GetMedicationResponseModel.fromJson(Map json) { description = json['Description']; genericName = json['GenericName']; itemId = json['ItemId']; @@ -31,8 +31,8 @@ class GetMedicationResponseModel { uom = json['uom']; } - Map toJson() { - final Map data = new Map(); + Map toJson() { + final Map data = new Map(); data['Description'] = this.description; data['GenericName'] = this.genericName; data['ItemId'] = this.itemId; diff --git a/lib/core/model/search_drug/item_by_medicine_model.dart b/lib/core/model/search_drug/item_by_medicine_model.dart index 0a93a4f1..a95988db 100644 --- a/lib/core/model/search_drug/item_by_medicine_model.dart +++ b/lib/core/model/search_drug/item_by_medicine_model.dart @@ -1,27 +1,27 @@ class ItemByMedicineModel { - List frequencies; - List routes; - List strengths; + List? frequencies; + List ?routes; + List? strengths; ItemByMedicineModel({this.frequencies, this.routes, this.strengths}); ItemByMedicineModel.fromJson(Map json) { if (json['frequencies'] != null) { - frequencies = new List(); + frequencies = []; json['frequencies'].forEach((v) { - frequencies.add(new Frequencies.fromJson(v)); + frequencies!.add(new Frequencies.fromJson(v)); }); } if (json['routes'] != null) { - routes = new List(); + routes = []; json['routes'].forEach((v) { - routes.add(new Routes.fromJson(v)); + routes!.add(new Routes.fromJson(v)); }); } if (json['strengths'] != null) { - strengths = new List(); + strengths = []; json['strengths'].forEach((v) { - strengths.add(new Strengths.fromJson(v)); + strengths!.add(new Strengths.fromJson(v)); }); } } @@ -29,22 +29,22 @@ class ItemByMedicineModel { Map toJson() { final Map data = new Map(); if (this.frequencies != null) { - data['frequencies'] = this.frequencies.map((v) => v.toJson()).toList(); + data['frequencies'] = this.frequencies!.map((v) => v.toJson()).toList(); } if (this.routes != null) { - data['routes'] = this.routes.map((v) => v.toJson()).toList(); + data['routes'] = this.routes!.map((v) => v.toJson()).toList(); } if (this.strengths != null) { - data['strengths'] = this.strengths.map((v) => v.toJson()).toList(); + data['strengths'] = this.strengths!.map((v) => v.toJson()).toList(); } return data; } } class Frequencies { - String description; - bool isDefault; - int parameterCode; + String? description; + bool? isDefault; + int ?parameterCode; Frequencies({this.description, this.isDefault, this.parameterCode}); @@ -64,9 +64,9 @@ class Frequencies { } class Strengths { - String description; - bool isDefault; - int parameterCode; + String? description; + bool ?isDefault; + int ?parameterCode; Strengths({this.description, this.isDefault, this.parameterCode}); @@ -86,9 +86,9 @@ class Strengths { } class Routes { - String description; - bool isDefault; - int parameterCode; + String ?description; + bool ?isDefault; + int ?parameterCode; Routes({this.description, this.isDefault, this.parameterCode}); diff --git a/lib/core/model/search_drug/item_by_medicine_request_model.dart b/lib/core/model/search_drug/item_by_medicine_request_model.dart index 7460044b..7ec3e21e 100644 --- a/lib/core/model/search_drug/item_by_medicine_request_model.dart +++ b/lib/core/model/search_drug/item_by_medicine_request_model.dart @@ -1,6 +1,6 @@ class ItemByMedicineRequestModel { - String vidaAuthTokenID; - int medicineCode; + String ?vidaAuthTokenID; + int ?medicineCode; ItemByMedicineRequestModel({this.vidaAuthTokenID, this.medicineCode}); diff --git a/lib/core/model/search_drug/search_drug_model.dart b/lib/core/model/search_drug/search_drug_model.dart index 396526c1..aa7739a2 100644 --- a/lib/core/model/search_drug/search_drug_model.dart +++ b/lib/core/model/search_drug/search_drug_model.dart @@ -1,15 +1,15 @@ class SearchDrugModel { - List entityList; - int rowcount; + List? entityList; + int ?rowcount; dynamic statusMessage; SearchDrugModel({this.entityList, this.rowcount, this.statusMessage}); SearchDrugModel.fromJson(Map json) { if (json['entityList'] != null) { - entityList = new List(); + entityList = []; json['entityList'].forEach((v) { - entityList.add(new EntityList.fromJson(v)); + entityList!.add(new EntityList.fromJson(v)); }); } rowcount = json['rowcount']; @@ -19,7 +19,7 @@ class SearchDrugModel { Map toJson() { final Map data = new Map(); if (this.entityList != null) { - data['entityList'] = this.entityList.map((v) => v.toJson()).toList(); + data['entityList'] = this.entityList!.map((v) => v.toJson()).toList(); } data['rowcount'] = this.rowcount; data['statusMessage'] = this.statusMessage; diff --git a/lib/core/model/search_drug/search_drug_request_model.dart b/lib/core/model/search_drug/search_drug_request_model.dart index b64e7d18..8c725c86 100644 --- a/lib/core/model/search_drug/search_drug_request_model.dart +++ b/lib/core/model/search_drug/search_drug_request_model.dart @@ -1,5 +1,5 @@ class SearchDrugRequestModel { - List search; + List ?search; // String vidaAuthTokenID; SearchDrugRequestModel({this.search}); diff --git a/lib/core/model/sick_leave/sick_leave_doctor_request_model.dart b/lib/core/model/sick_leave/sick_leave_doctor_request_model.dart index 26bb76bd..8087481c 100644 --- a/lib/core/model/sick_leave/sick_leave_doctor_request_model.dart +++ b/lib/core/model/sick_leave/sick_leave_doctor_request_model.dart @@ -1,12 +1,16 @@ class GetSickLeaveDoctorRequestModel { - int patientMRN; - String appointmentNo; - int status; - String vidaAuthTokenID; - String vidaRefreshTokenID; + int? patientMRN; + String? appointmentNo; + int? status; + String? vidaAuthTokenID; + String? vidaRefreshTokenID; GetSickLeaveDoctorRequestModel( - {this.patientMRN, this.appointmentNo, this.status, this.vidaAuthTokenID, this.vidaRefreshTokenID}); + {this.patientMRN, + this.appointmentNo, + this.status, + this.vidaAuthTokenID, + this.vidaRefreshTokenID}); GetSickLeaveDoctorRequestModel.fromJson(Map json) { patientMRN = json['PatientMRN']; diff --git a/lib/core/model/sick_leave/sick_leave_patient_model.dart b/lib/core/model/sick_leave/sick_leave_patient_model.dart index 1e79833c..aed6a216 100644 --- a/lib/core/model/sick_leave/sick_leave_patient_model.dart +++ b/lib/core/model/sick_leave/sick_leave_patient_model.dart @@ -21,13 +21,13 @@ class SickLeavePatientModel { dynamic doctorTitle; dynamic gender; dynamic genderDescription; - bool isActiveDoctorProfile; - bool isDoctorAllowVedioCall; - bool isExecludeDoctor; - bool isInOutPatient; + bool? isActiveDoctorProfile; + bool? isDoctorAllowVedioCall; + bool? isExecludeDoctor; + bool? isInOutPatient; dynamic isInOutPatientDescription; dynamic isInOutPatientDescriptionN; - bool isLiveCareAppointment; + bool? isLiveCareAppointment; dynamic noOfPatientsRate; dynamic patientName; dynamic projectName; diff --git a/lib/core/model/sick_leave/sick_leave_patient_request_model.dart b/lib/core/model/sick_leave/sick_leave_patient_request_model.dart index 69b18f41..ba2a399c 100644 --- a/lib/core/model/sick_leave/sick_leave_patient_request_model.dart +++ b/lib/core/model/sick_leave/sick_leave_patient_request_model.dart @@ -1,17 +1,17 @@ class SickLeavePatientRequestModel { - double versionID; - int channel; - int languageID; - String iPAdress; - String generalid; - int patientOutSA; - int deviceTypeID; - int patientType; - int patientTypeID; - String tokenID; - int patientID; - int patientMRN; - String sessionID; + double? versionID; + int? channel; + int? languageID; + String? iPAdress; + String? generalid; + int? patientOutSA; + int? deviceTypeID; + int? patientType; + int? patientTypeID; + String? tokenID; + int? patientID; + int? patientMRN; + String? sessionID; SickLeavePatientRequestModel( {this.versionID, diff --git a/lib/core/service/VideoCallService.dart b/lib/core/service/VideoCallService.dart index 31cc2cd6..992b694f 100644 --- a/lib/core/service/VideoCallService.dart +++ b/lib/core/service/VideoCallService.dart @@ -44,7 +44,7 @@ class VideoCallService extends BaseService { : "-"), tokenID: await sharedPref.getString(TOKEN), generalId: GENERAL_ID, - doctorId: doctorProfile.doctorID, + doctorId: doctorProfile!.doctorID, onFailure: (String error) { DrAppToastMsg.showErrorToast(error); }, @@ -98,7 +98,7 @@ class VideoCallService extends BaseService { hasError = false; await getDoctorProfile(isGetProfile: true); EndCallReq endCallReq = new EndCallReq(); - endCallReq.doctorId = doctorProfile.doctorID; + endCallReq.doctorId = doctorProfile!.doctorID; endCallReq.generalid = 'Cs2020@2016\$2958'; endCallReq.vCID = vCID; endCallReq.isDestroy = isPatient; diff --git a/lib/core/service/base/base_service.dart b/lib/core/service/base/base_service.dart index 58526da7..75f710e5 100644 --- a/lib/core/service/base/base_service.dart +++ b/lib/core/service/base/base_service.dart @@ -1,15 +1,16 @@ import 'package:doctor_app_flutter/client/base_app_client.dart'; +import 'package:doctor_app_flutter/config/config.dart'; import 'package:doctor_app_flutter/config/shared_pref_kay.dart'; import 'package:doctor_app_flutter/models/doctor/doctor_profile_model.dart'; import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; import 'package:doctor_app_flutter/util/dr_app_shared_pref.dart'; class BaseService { - String error; + String error=''; bool hasError = false; BaseAppClient baseAppClient = BaseAppClient(); DrAppSharedPreferances sharedPref = new DrAppSharedPreferances(); - DoctorProfileModel doctorProfile; + DoctorProfileModel ?doctorProfile; List patientArrivalList = []; @@ -18,24 +19,20 @@ class BaseService { } //TODO add the user login model when we need it - Future getDoctorProfile({bool isGetProfile = false}) async { + Future ? getDoctorProfile({bool isGetProfile = false}) async { if(isGetProfile) { - Map profile = await sharedPref.getObj(DOCTOR_PROFILE); - if (profile != null) { - doctorProfile = DoctorProfileModel.fromJson(profile); - if (doctorProfile != null) { - return doctorProfile; - } + Map profile = await sharedPref.getObj(DOCTOR_PROFILE); + doctorProfile = DoctorProfileModel.fromJson(profile); + if (doctorProfile != null) { + return doctorProfile!; } } if (doctorProfile == null) { - Map profile = await sharedPref.getObj(DOCTOR_PROFILE); - if (profile != null) { - doctorProfile = DoctorProfileModel.fromJson(profile); - if (doctorProfile != null) { - return doctorProfile; - } + Map profile = await sharedPref.getObj(DOCTOR_PROFILE); + doctorProfile = DoctorProfileModel.fromJson(profile); + if (doctorProfile != null) { + return doctorProfile!; } return null; } else { @@ -43,5 +40,38 @@ class BaseService { } } + Future getPatientArrivalList(String date,{String? fromDate, int patientMrn = -1, int appointmentNo = -1}) async{ + hasError = false; + Map body = Map(); + body['From'] = fromDate == null ? date : fromDate; + body['To'] = date; + body['PageIndex'] = 0; + body['PageSize'] = 0; + if(patientMrn != -1){ + body['PatientMRN'] = patientMrn; + } + if(appointmentNo != -1){ + body['AppointmentNo'] = appointmentNo; + } + + await baseAppClient.post( + ARRIVED_PATIENT_URL, + onSuccess: (dynamic response, int statusCode) { + patientArrivalList.clear(); + + if(response['patientArrivalList']['entityList'] != null){ + response['patientArrivalList']['entityList'].forEach((v) { + PatiantInformtion item = PatiantInformtion.fromJson(v); + patientArrivalList.add(item); + }); + } + }, + onFailure: (String error, int statusCode) { + hasError = true; + this.error = error; + }, + body: body, + ); + } } diff --git a/lib/core/service/home/dasboard_service.dart b/lib/core/service/home/dasboard_service.dart index ad3ec887..5516923a 100644 --- a/lib/core/service/home/dasboard_service.dart +++ b/lib/core/service/home/dasboard_service.dart @@ -9,7 +9,7 @@ class DashboardService extends BaseService { bool hasVirtualClinic = false; - String sServiceID; + String ?sServiceID; Future getDashboard() async { hasError = false; diff --git a/lib/core/service/home/scan_qr_service.dart b/lib/core/service/home/scan_qr_service.dart index b21768f9..a06a8974 100644 --- a/lib/core/service/home/scan_qr_service.dart +++ b/lib/core/service/home/scan_qr_service.dart @@ -4,15 +4,15 @@ import 'package:doctor_app_flutter/core/service/base/base_service.dart'; import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; class ScanQrService extends BaseService { - List myInPatientList = List(); - List inPatientList = List(); + List myInPatientList = []; + List inPatientList = []; Future getInPatient(PatientSearchRequestModel requestModel, bool isMyInpatient) async { hasError = false; await getDoctorProfile(); // if (isMyInpatient) { - // requestModel.doctorID = doctorProfile.doctorID; + // requestModel.doctorID = doctorProfile!.doctorID!; // } else { requestModel.doctorID = 0; //} @@ -26,7 +26,7 @@ class ScanQrService extends BaseService { response['List_MyInPatient'].forEach((v) { PatiantInformtion patient = PatiantInformtion.fromJson(v); inPatientList.add(patient); - if (patient.doctorId == doctorProfile.doctorID) { + if (patient.doctorId == doctorProfile!.doctorID!) { myInPatientList.add(patient); } }); diff --git a/lib/core/service/hospitals/hospitals_service.dart b/lib/core/service/hospitals/hospitals_service.dart index f8a7579d..efa24209 100644 --- a/lib/core/service/hospitals/hospitals_service.dart +++ b/lib/core/service/hospitals/hospitals_service.dart @@ -4,8 +4,7 @@ import 'package:doctor_app_flutter/core/model/hospitals/get_hospitals_response_m import 'package:doctor_app_flutter/core/service/base/base_service.dart'; class HospitalsService extends BaseService { - -List hospitals =List(); + List hospitals = []; Future getHospitals(GetHospitalsRequestModel getHospitalsRequestModel) async { hasError = false; diff --git a/lib/core/service/patient/DischargedPatientService.dart b/lib/core/service/patient/DischargedPatientService.dart index 2b353016..6566a57d 100644 --- a/lib/core/service/patient/DischargedPatientService.dart +++ b/lib/core/service/patient/DischargedPatientService.dart @@ -4,15 +4,15 @@ import 'package:doctor_app_flutter/core/service/base/base_service.dart'; import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; class DischargedPatientService extends BaseService { - List myDischargedPatients = List(); + List myDischargedPatients = []; - List myDischargeReferralPatients = List(); + List myDischargeReferralPatients = []; Future getDischargedPatient() async { hasError = false; Map body = Map(); await getDoctorProfile(isGetProfile: true); - body['DoctorID'] = doctorProfile.doctorID; + body['DoctorID'] = doctorProfile!.doctorID; body['FirstName'] = "0"; body['MiddleName'] = "0"; body['LastName'] = "0"; @@ -28,8 +28,7 @@ class DischargedPatientService extends BaseService { body['PatientTypeID'] = 1; hasError = false; myDischargedPatients.clear(); - await baseAppClient.post(GET_DISCHARGE_PATIENT, - onSuccess: (dynamic response, int statusCode) { + await baseAppClient.post(GET_DISCHARGE_PATIENT, onSuccess: (dynamic response, int statusCode) { if (response['List_MyDischargePatient'] != null) { response['List_MyDischargePatient'].forEach((v) { myDischargedPatients.add(PatiantInformtion.fromJson(v)); @@ -45,7 +44,7 @@ class DischargedPatientService extends BaseService { hasError = false; Map body = Map(); await getDoctorProfile(isGetProfile: true); - body['DoctorID'] = doctorProfile.doctorID; + body['DoctorID'] = doctorProfile!.doctorID; body['FirstName'] = "0"; body['MiddleName'] = "0"; body['LastName'] = "0"; @@ -61,8 +60,7 @@ class DischargedPatientService extends BaseService { body['PatientTypeID'] = 1; hasError = false; myDischargeReferralPatients.clear(); - await baseAppClient.post(GET_MY_DISCHARGE_PATIENT, - onSuccess: (dynamic response, int statusCode) { + await baseAppClient.post(GET_MY_DISCHARGE_PATIENT, onSuccess: (dynamic response, int statusCode) { if (response['List_MyDischargeReferralPatient'] != null) { response['List_MyDischargeReferralPatient'].forEach((v) { myDischargeReferralPatients.add(DischargeReferralPatient.fromJson(v)); diff --git a/lib/core/service/patient/LiveCarePatientServices.dart b/lib/core/service/patient/LiveCarePatientServices.dart index 10af0ea2..3ef3c548 100644 --- a/lib/core/service/patient/LiveCarePatientServices.dart +++ b/lib/core/service/patient/LiveCarePatientServices.dart @@ -30,8 +30,7 @@ class LiveCarePatientServices extends BaseService { var transferToAdminResponse = {}; var isLoginResponse = {}; - StartCallRes _startCallRes; - + late StartCallRes _startCallRes; StartCallRes get startCallRes => _startCallRes; Future getPendingPatientERForDoctorApp( @@ -48,7 +47,7 @@ class LiveCarePatientServices extends BaseService { /// add new items. localPatientList.forEach((element) { - if ((_patientList.singleWhere((it) => it.patientId == element.patientId, orElse: () => null)) == null) { + if ((_patientList.singleWhere((it) => it.patientId == element.patientId)) == null) { _patientList.add(element); } }); @@ -56,7 +55,7 @@ class LiveCarePatientServices extends BaseService { /// remove items. List removedPatientList = []; _patientList.forEach((element) { - if ((localPatientList.singleWhere((it) => it.patientId == element.patientId, orElse: () => null)) == null) { + if ((localPatientList.singleWhere((it) => it.patientId == element.patientId)) == null) { removedPatientList.add(element); } }); @@ -127,10 +126,10 @@ class LiveCarePatientServices extends BaseService { }, body: {"VC_ID": vcID, "generalid": GENERAL_ID}, isLiveCare: _isLive); } - Future isLogin({LiveCareUserLoginRequestModel isLoginRequestModel, int loginStatus}) async { + Future isLogin({LiveCareUserLoginRequestModel? isLoginRequestModel, int? loginStatus}) async { hasError = false; await getDoctorProfile(); - isLoginRequestModel.doctorId = super.doctorProfile.doctorID; + isLoginRequestModel!.doctorId = super.doctorProfile!.doctorID!; await baseAppClient.post(LIVE_CARE_IS_LOGIN, onSuccess: (response, statusCode) async { isLoginResponse = response; }, onFailure: (String error, int statusCode) { @@ -153,12 +152,12 @@ class LiveCarePatientServices extends BaseService { }, body: {"VC_ID": vcID, "generalid": GENERAL_ID}, isLiveCare: _isLive); } - Future addPatientToDoctorList({int vcID}) async { + Future addPatientToDoctorList({required int vcID}) async { hasError = false; await getDoctorProfile(); AddPatientToDoctorListRequestModel addPatientToDoctorListRequestModel = AddPatientToDoctorListRequestModel(); - addPatientToDoctorListRequestModel.doctorId = super.doctorProfile.doctorID; + addPatientToDoctorListRequestModel.doctorId = super.doctorProfile!.doctorID!; addPatientToDoctorListRequestModel.vCID = vcID; addPatientToDoctorListRequestModel.isOutKsa = false; addPatientToDoctorListRequestModel.generalid = GENERAL_ID; @@ -171,11 +170,11 @@ class LiveCarePatientServices extends BaseService { }, body: addPatientToDoctorListRequestModel.toJson(), isLiveCare: _isLive); } - Future removePatientFromDoctorList({int vcID}) async { + Future removePatientFromDoctorList({required int vcID}) async { hasError = false; AddPatientToDoctorListRequestModel addPatientToDoctorListRequestModel = AddPatientToDoctorListRequestModel(); await getDoctorProfile(); - addPatientToDoctorListRequestModel.doctorId = super.doctorProfile.doctorID; + addPatientToDoctorListRequestModel.doctorId = super.doctorProfile!.doctorID!; addPatientToDoctorListRequestModel.vCID = vcID; addPatientToDoctorListRequestModel.isOutKsa = false; addPatientToDoctorListRequestModel.generalid = GENERAL_ID; diff --git a/lib/core/service/patient/MyReferralPatientService.dart b/lib/core/service/patient/MyReferralPatientService.dart index 35729def..8f6c6e8a 100644 --- a/lib/core/service/patient/MyReferralPatientService.dart +++ b/lib/core/service/patient/MyReferralPatientService.dart @@ -6,14 +6,14 @@ import 'package:doctor_app_flutter/core/service/base/base_service.dart'; import 'package:doctor_app_flutter/models/doctor/request_add_referred_doctor_remarks.dart'; class MyReferralInPatientService extends BaseService { - List myReferralPatients = List(); + List myReferralPatients = []; Future getMyReferralPatientService() async { hasError = false; await getDoctorProfile(); MyReferralPatientRequestModel myReferralPatientRequestModel = MyReferralPatientRequestModel( - doctorID: doctorProfile.doctorID, + doctorID: doctorProfile!.doctorID, firstName: "0", middleName: "0", lastName: "0", @@ -48,7 +48,7 @@ class MyReferralInPatientService extends BaseService { await getDoctorProfile(); MyReferralPatientRequestModel myReferralPatientRequestModel = MyReferralPatientRequestModel( - doctorID: doctorProfile.doctorID, + doctorID: doctorProfile!.doctorID!, firstName: "0", middleName: "0", lastName: "0", @@ -86,7 +86,7 @@ class MyReferralInPatientService extends BaseService { _requestAddReferredDoctorRemarks.admissionNo = referral.admissionNo.toString(); _requestAddReferredDoctorRemarks.lineItemNo = referral.lineItemNo; _requestAddReferredDoctorRemarks.referredDoctorRemarks = referredDoctorRemarks; - _requestAddReferredDoctorRemarks.editedBy = doctorProfile.doctorID; + _requestAddReferredDoctorRemarks.editedBy = doctorProfile!.doctorID; _requestAddReferredDoctorRemarks.patientID = referral.patientID; _requestAddReferredDoctorRemarks.referringDoctor = referral.referringDoctor; await baseAppClient.post( @@ -104,8 +104,8 @@ class MyReferralInPatientService extends BaseService { hasError = false; await getDoctorProfile(); AddReferredRemarksRequestModel _requestAddReferredDoctorRemarks = AddReferredRemarksRequestModel( - editedBy: doctorProfile.doctorID, - projectID: doctorProfile.projectID, + editedBy: doctorProfile!.doctorID, + projectID: doctorProfile!.projectID, referredDoctorRemarks: referredDoctorRemarks, referalStatus: referralStatus); _requestAddReferredDoctorRemarks.projectID = referral.projectID; @@ -114,7 +114,7 @@ class MyReferralInPatientService extends BaseService { _requestAddReferredDoctorRemarks.admissionNo = int.parse(referral.admissionNo); _requestAddReferredDoctorRemarks.lineItemNo = referral.lineItemNo; _requestAddReferredDoctorRemarks.referredDoctorRemarks = referredDoctorRemarks; - _requestAddReferredDoctorRemarks.editedBy = doctorProfile.doctorID; + _requestAddReferredDoctorRemarks.editedBy = doctorProfile!.doctorID; _requestAddReferredDoctorRemarks.referalStatus = referralStatus; // _requestAddReferredDoctorRemarks.patientID = referral.patientID; diff --git a/lib/core/service/patient/PatientMuseService.dart b/lib/core/service/patient/PatientMuseService.dart index c34de9e0..7c40b804 100644 --- a/lib/core/service/patient/PatientMuseService.dart +++ b/lib/core/service/patient/PatientMuseService.dart @@ -3,7 +3,7 @@ import 'package:doctor_app_flutter/core/model/patient_muse/PatientMuseResultsMod import 'package:doctor_app_flutter/core/service/base/base_service.dart'; class PatientMuseService extends BaseService { - List patientMuseResultsModelList = List(); + List patientMuseResultsModelList = []; getECGPatient({int patientType, int patientOutSA, int patientID}) async { Map body = Map(); diff --git a/lib/core/service/patient/ReferralService.dart b/lib/core/service/patient/ReferralService.dart index 69e2a810..b6aafa56 100644 --- a/lib/core/service/patient/ReferralService.dart +++ b/lib/core/service/patient/ReferralService.dart @@ -25,11 +25,11 @@ class ReferralService extends BaseService { referralRequest.priority = priority.toString(); referralRequest.frequency = frequency.toString(); referralRequest.referringDoctorRemarks = referringDoctorRemarks; - referralRequest.referringClinic = doctorProfile.clinicID; - referralRequest.referringDoctor = doctorProfile.doctorID; + referralRequest.referringClinic = doctorProfile!.clinicID; + referralRequest.referringDoctor = doctorProfile!.doctorID; referralRequest.extension = extension; - referralRequest.editedBy = doctorProfile.doctorID; - referralRequest.createdBy = doctorProfile.doctorID; + referralRequest.editedBy = doctorProfile!.doctorID; + referralRequest.createdBy = doctorProfile!.doctorID; referralRequest.patientOutSA = false; await baseAppClient.post( diff --git a/lib/core/service/patient/patient-doctor-referral-service.dart b/lib/core/service/patient/patient-doctor-referral-service.dart index 5b659631..7cdf1270 100644 --- a/lib/core/service/patient/patient-doctor-referral-service.dart +++ b/lib/core/service/patient/patient-doctor-referral-service.dart @@ -15,7 +15,7 @@ import '../base/lookup-service.dart'; class PatientReferralService extends LookupService { List projectsList = []; List clinicsList = []; - List doctorsList = List(); + List doctorsList = []; List listMyReferredPatientModel = []; List pendingReferralList = []; List patientReferralList = []; @@ -142,7 +142,7 @@ class PatientReferralService extends LookupService { MyReferredPatientModel item = MyReferredPatientModel.fromJson(v); if (doctorProfile != null) { item.isReferralDoctorSameBranch = - doctorProfile.projectID == item.projectID; + doctorProfile!.projectID == item.projectID; } else { item.isReferralDoctorSameBranch = false; } @@ -173,7 +173,7 @@ class PatientReferralService extends LookupService { MyReferredPatientModel item = MyReferredPatientModel.fromJson(v); if (doctorProfile != null) { item.isReferralDoctorSameBranch = - doctorProfile.projectID == item.projectID; + doctorProfile!.projectID == item.projectID; } else { item.isReferralDoctorSameBranch = false; } @@ -193,7 +193,7 @@ class PatientReferralService extends LookupService { DoctorProfileModel doctorProfile = await getDoctorProfile(); Map body = Map(); // body['ClinicID'] = 0; - body['DoctorID'] = doctorProfile.doctorID; + body['DoctorID'] = doctorProfile!.doctorID; await baseAppClient.post( GET_PENDING_REFERRAL_PATIENT, @@ -255,7 +255,7 @@ class PatientReferralService extends LookupService { body['IsAccepted'] = isAccepted; body['PatientName'] = referralPatient.patientName; body['ReferralResponse'] = referralPatient.remarksFromSource; - body['DoctorName'] = doctorProfile.doctorName; + body['DoctorName'] = doctorProfile!.doctorName; await baseAppClient.post( RESPONSE_PENDING_REFERRAL_PATIENT, diff --git a/lib/core/service/patient/patientInPatientService.dart b/lib/core/service/patient/patientInPatientService.dart index bc7f1283..b6535398 100644 --- a/lib/core/service/patient/patientInPatientService.dart +++ b/lib/core/service/patient/patientInPatientService.dart @@ -4,8 +4,8 @@ import 'package:doctor_app_flutter/core/service/base/base_service.dart'; import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; class PatientInPatientService extends BaseService { - List inPatientList = List(); - List myInPatientList = List(); + List inPatientList = []; + List myInPatientList = []; Future getInPatientList( PatientSearchRequestModel requestModel, bool isMyInpatient) async { @@ -13,7 +13,7 @@ class PatientInPatientService extends BaseService { await getDoctorProfile(isGetProfile: true); if (isMyInpatient) { - requestModel.doctorID = doctorProfile.doctorID; + requestModel.doctorID = doctorProfile!.doctorID; } else { requestModel.doctorID = 0; } @@ -27,7 +27,7 @@ class PatientInPatientService extends BaseService { response['List_MyInPatient'].forEach((v) { PatiantInformtion patient = PatiantInformtion.fromJson(v); inPatientList.add(patient); - if(patient.doctorId == doctorProfile.doctorID){ + if(patient.doctorId == doctorProfile!.doctorID){ myInPatientList.add(patient); } }); diff --git a/lib/core/service/patient/patient_service.dart b/lib/core/service/patient/patient_service.dart index f79e342c..7ad60455 100644 --- a/lib/core/service/patient/patient_service.dart +++ b/lib/core/service/patient/patient_service.dart @@ -30,8 +30,8 @@ import 'package:doctor_app_flutter/models/patient/vital_sign/vital_sign_res_mode class PatientService extends BaseService { List _patientVitalSignList = []; List patientVitalSignOrderdSubList = []; - List inPatientList = List(); - List myInPatientList = List(); + List inPatientList = []; + List myInPatientList = []; List get patientVitalSignList => _patientVitalSignList; @@ -157,7 +157,7 @@ class PatientService extends BaseService { await getDoctorProfile(); if (isMyInpatient) { - requestModel.doctorID = doctorProfile.doctorID; + requestModel.doctorID = doctorProfile!.doctorID; } else { requestModel.doctorID = 0; } @@ -171,7 +171,7 @@ class PatientService extends BaseService { response['List_MyInPatient'].forEach((v) { PatiantInformtion patient = PatiantInformtion.fromJson(v); inPatientList.add(patient); - if (patient.doctorId == doctorProfile.doctorID) { + if (patient.doctorId == doctorProfile!.doctorID) { myInPatientList.add(patient); } }); @@ -435,8 +435,8 @@ class PatientService extends BaseService { // TODO Change it to use it when we implement authentication user Map profile = await sharedPref.getObj(DOCTOR_PROFILE); DoctorProfileModel doctorProfile = new DoctorProfileModel.fromJson(profile); - int doctorID = doctorProfile.doctorID; - int clinicId = doctorProfile.clinicID; + int doctorID = doctorProfile!.doctorID; + int clinicId = doctorProfile!.clinicID; _referToDoctorRequest = ReferToDoctorRequest( projectID: projectID, admissionNo: admissionNo, diff --git a/lib/core/service/patient/profile/discharge_summary_servive.dart b/lib/core/service/patient/profile/discharge_summary_servive.dart index a92ef0eb..f41dbc16 100644 --- a/lib/core/service/patient/profile/discharge_summary_servive.dart +++ b/lib/core/service/patient/profile/discharge_summary_servive.dart @@ -18,7 +18,8 @@ class DischargeSummaryService extends BaseService { _allDischargeSummaryList; Future getPendingDischargeSummary( - {GetDischargeSummaryReqModel getDischargeSummaryReqModel}) async { + {required GetDischargeSummaryReqModel + getDischargeSummaryReqModel}) async { hasError = false; await baseAppClient.post(GET_PENDING_DISCHARGE_SUMMARY, onSuccess: (dynamic response, int statusCode) { diff --git a/lib/core/service/patient/profile/operation_report_servive.dart b/lib/core/service/patient/profile/operation_report_servive.dart index 7ac4ade7..3a39a4b8 100644 --- a/lib/core/service/patient/profile/operation_report_servive.dart +++ b/lib/core/service/patient/profile/operation_report_servive.dart @@ -11,12 +11,11 @@ class OperationReportService extends BaseService { List get reservationList => _reservationList; List _operationDetailsList = []; - List get operationDetailsList => _operationDetailsList; + List get operationDetailsList => + _operationDetailsList; - Future getReservations( - {GetReservationsRequestModel getReservationsRequestModel, - int patientId}) async { - getReservationsRequestModel = + Future getReservations({required int patientId}) async { + GetReservationsRequestModel getReservationsRequestModel = GetReservationsRequestModel(patientID: patientId, doctorID: ""); hasError = false; @@ -35,10 +34,9 @@ class OperationReportService extends BaseService { }, body: getReservationsRequestModel.toJson()); } - Future getOperationReportDetails( - {GetOperationDetailsRequestModel getOperationReportRequestModel, - }) async { - + Future getOperationReportDetails({ + required GetOperationDetailsRequestModel getOperationReportRequestModel, + }) async { hasError = false; await baseAppClient.post(GET_OPERATION_DETAILS, onSuccess: (dynamic response, int statusCode) { @@ -46,7 +44,8 @@ class OperationReportService extends BaseService { _operationDetailsList.clear(); response['List_OperationDetails'].forEach( (v) { - _operationDetailsList.add(GetOperationDetailsResponseModel.fromJson(v)); + _operationDetailsList + .add(GetOperationDetailsResponseModel.fromJson(v)); }, ); }, onFailure: (String error, int statusCode) { diff --git a/lib/core/service/patient_medical_file/insurance/InsuranceCardService.dart b/lib/core/service/patient_medical_file/insurance/InsuranceCardService.dart index 2bb9dac7..f1c6ecb1 100644 --- a/lib/core/service/patient_medical_file/insurance/InsuranceCardService.dart +++ b/lib/core/service/patient_medical_file/insurance/InsuranceCardService.dart @@ -16,10 +16,10 @@ class InsuranceCardService extends BaseService { _insuranceApprovalInPatientRequestModel = InsuranceApprovalInPatientRequestModel(); - List _insuranceApproval = List(); + List _insuranceApproval = []; List get insuranceApproval => _insuranceApproval; - List _insuranceApprovalInPatient = List(); + List _insuranceApprovalInPatient = []; List get insuranceApprovalInPatient => _insuranceApprovalInPatient; diff --git a/lib/core/service/patient_medical_file/lab_order/labs_service.dart b/lib/core/service/patient_medical_file/lab_order/labs_service.dart index 0a10eb31..324abfc3 100644 --- a/lib/core/service/patient_medical_file/lab_order/labs_service.dart +++ b/lib/core/service/patient_medical_file/lab_order/labs_service.dart @@ -13,8 +13,8 @@ import 'package:doctor_app_flutter/models/patient/patiant_info_model.dart'; import '../../base/base_service.dart'; class LabsService extends BaseService { - List patientLabOrdersList = List(); - List _allSpecialLab = List(); + List patientLabOrdersList = []; + List _allSpecialLab = []; List get allSpecialLab => _allSpecialLab; AllSpecialLabResultRequestModel _allSpecialLabResultRequestModel = AllSpecialLabResultRequestModel(); @@ -25,7 +25,7 @@ class LabsService extends BaseService { String url = ""; if (isInpatient) { await getDoctorProfile(); - body['ProjectID'] = doctorProfile.projectID; + body['ProjectID'] = doctorProfile!.projectID; url = GET_PATIENT_LAB_OREDERS; } else { body['isDentalAllowedBackend'] = false; @@ -53,10 +53,10 @@ class LabsService extends BaseService { RequestPatientLabSpecialResult _requestPatientLabSpecialResult = RequestPatientLabSpecialResult(); - List patientLabSpecialResult = List(); - List labResultList = List(); - List labOrdersResultsList = List(); - List labOrdersResultHistoryList = List(); + List patientLabSpecialResult = []; + List labResultList = []; + List labOrdersResultsList = []; + List labOrdersResultHistoryList = []; Future getLaboratoryResult( {String projectID, diff --git a/lib/core/service/patient_medical_file/medical_report/PatientMedicalReportService.dart b/lib/core/service/patient_medical_file/medical_report/PatientMedicalReportService.dart index dfb9c3ae..300fa777 100644 --- a/lib/core/service/patient_medical_file/medical_report/PatientMedicalReportService.dart +++ b/lib/core/service/patient_medical_file/medical_report/PatientMedicalReportService.dart @@ -13,8 +13,8 @@ class PatientMedicalReportService extends BaseService { Map body = Map(); await getDoctorProfile(); body['AdmissionNo'] = patient.admissionNo; - body['SetupID'] = doctorProfile.setupID; - body['ProjectID'] = doctorProfile.projectID; + body['SetupID'] = doctorProfile!.setupID; + body['ProjectID'] = doctorProfile!.projectID; medicalReportList = []; await baseAppClient.postPatient(PATIENT_MEDICAL_REPORT_GET_LIST, onSuccess: (dynamic response, int statusCode) { if (response['DAPP_ListMedicalReportList'] != null) { diff --git a/lib/core/service/patient_medical_file/medical_report/medical_file_service.dart b/lib/core/service/patient_medical_file/medical_report/medical_file_service.dart index 42cdafc6..0624079a 100644 --- a/lib/core/service/patient_medical_file/medical_report/medical_file_service.dart +++ b/lib/core/service/patient_medical_file/medical_report/medical_file_service.dart @@ -4,7 +4,7 @@ import 'package:doctor_app_flutter/core/model/medical_report/medical_file_reques import 'package:doctor_app_flutter/core/service/base/base_service.dart'; class MedicalFileService extends BaseService { - List _medicalFileList = List(); + List _medicalFileList = []; List get medicalFileList => _medicalFileList; MedicalFileRequestModel _fileRequestModel = MedicalFileRequestModel( diff --git a/lib/core/service/patient_medical_file/prescription/prescription_service.dart b/lib/core/service/patient_medical_file/prescription/prescription_service.dart index ffbcae9b..886ee5d2 100644 --- a/lib/core/service/patient_medical_file/prescription/prescription_service.dart +++ b/lib/core/service/patient_medical_file/prescription/prescription_service.dart @@ -16,9 +16,9 @@ import 'package:doctor_app_flutter/models/patient/vital_sign/patient-vital-sign- import 'package:doctor_app_flutter/util/date-utils.dart'; class PrescriptionService extends LookupService { - List _prescriptionList = List(); + List _prescriptionList = []; List get prescriptionList => _prescriptionList; - List _drugsList = List(); + List _drugsList = []; List get drugsList => _drugsList; List doctorsList = []; List allMedicationList = []; diff --git a/lib/core/service/patient_medical_file/prescription/prescriptions_service.dart b/lib/core/service/patient_medical_file/prescription/prescriptions_service.dart index 06de5a74..f542d119 100644 --- a/lib/core/service/patient_medical_file/prescription/prescriptions_service.dart +++ b/lib/core/service/patient_medical_file/prescription/prescriptions_service.dart @@ -17,10 +17,10 @@ import 'package:flutter/cupertino.dart'; import '../../base/base_service.dart'; class PrescriptionsService extends BaseService { - List prescriptionsList = List(); - List medicationForInPatient = List(); - List prescriptionsOrderList = List(); - List prescriptionInPatientList = List(); + List prescriptionsList = []; + List medicationForInPatient = []; + List prescriptionsOrderList = []; + List prescriptionInPatientList = []; InPatientPrescriptionRequestModel _inPatientPrescriptionRequestModel = InPatientPrescriptionRequestModel(); GetMedicationForInPatientRequestModel _getMedicationForInPatientRequestModel = @@ -62,7 +62,7 @@ class PrescriptionsService extends BaseService { RequestPrescriptionReport _requestPrescriptionReport = RequestPrescriptionReport(appointmentNo: 0, isDentalAllowedBackend: false); - List prescriptionReportList = List(); + List prescriptionReportList = []; Future getPrescriptionReport({Prescriptions prescriptions, @required PatiantInformtion patient}) async { hasError = false; @@ -100,7 +100,7 @@ class PrescriptionsService extends BaseService { longitude: 0, isDentalAllowedBackend: false, ); - List pharmacyPrescriptionsList = List(); + List pharmacyPrescriptionsList = []; Future getListPharmacyForPrescriptions({int itemId, @required PatiantInformtion patient}) async { hasError = false; @@ -120,7 +120,7 @@ class PrescriptionsService extends BaseService { isDentalAllowedBackend: false, ); - List prescriptionReportEnhList = List(); + List prescriptionReportEnhList = []; Future getPrescriptionReportEnh({PrescriptionsOrder prescriptionsOrder, @required PatiantInformtion patient}) async { ///This logic copy from the old app from class [order-history.component.ts] in line 45 diff --git a/lib/core/service/patient_medical_file/procedure/procedure_service.dart b/lib/core/service/patient_medical_file/procedure/procedure_service.dart index 56a92de5..a1f9a4ed 100644 --- a/lib/core/service/patient_medical_file/procedure/procedure_service.dart +++ b/lib/core/service/patient_medical_file/procedure/procedure_service.dart @@ -14,20 +14,20 @@ import 'package:doctor_app_flutter/core/model/procedure/update_procedure_request import 'package:doctor_app_flutter/core/service/base/base_service.dart'; class ProcedureService extends BaseService { - List _procedureList = List(); + List _procedureList = []; List get procedureList => _procedureList; - List _valadteProcedureList = List(); + List _valadteProcedureList = []; List get valadteProcedureList => _valadteProcedureList; - List _categoriesList = List(); + List _categoriesList = []; List get categoriesList => _categoriesList; - List procedureslist = List(); + List procedureslist = []; List categoryList = []; - // List _templateList = List(); + // List _templateList = []; // List get templateList => _templateList; - List templateList = List(); + List templateList = []; - List _templateDetailsList = List(); + List _templateDetailsList = []; List get templateDetailsList => _templateDetailsList; GetOrderedProcedureRequestModel _getOrderedProcedureRequestModel = GetOrderedProcedureRequestModel(); diff --git a/lib/core/service/patient_medical_file/radiology/radiology_service.dart b/lib/core/service/patient_medical_file/radiology/radiology_service.dart index f10f2253..dd61af31 100644 --- a/lib/core/service/patient_medical_file/radiology/radiology_service.dart +++ b/lib/core/service/patient_medical_file/radiology/radiology_service.dart @@ -6,7 +6,7 @@ import 'package:flutter/cupertino.dart'; import '../../base/base_service.dart'; class RadiologyService extends BaseService { - List finalRadiologyList = List(); + List finalRadiologyList = []; String url = ''; Future getRadImageURL({int invoiceNo, int lineItem, int projectId, @required PatiantInformtion patient}) async { diff --git a/lib/core/service/patient_medical_file/sick_leave/sickleave_service.dart b/lib/core/service/patient_medical_file/sick_leave/sickleave_service.dart index 070fd862..532f6141 100644 --- a/lib/core/service/patient_medical_file/sick_leave/sickleave_service.dart +++ b/lib/core/service/patient_medical_file/sick_leave/sickleave_service.dart @@ -18,7 +18,7 @@ class SickLeaveService extends BaseService { List get getReasons => reasonse; List reasonse = []; List get getAllSickLeave => _getAllsickLeave; - List _getAllsickLeave = List(); + List _getAllsickLeave = []; List get coveringDoctorsList => _coveringDoctors; List _coveringDoctors = []; @@ -29,8 +29,8 @@ class SickLeaveService extends BaseService { dynamic _postReschedule; - List getAllSickLeavePatient = List(); - List getAllSickLeaveDoctor = List(); + List getAllSickLeavePatient = []; + List getAllSickLeaveDoctor = []; SickLeavePatientRequestModel _sickLeavePatientRequestModel = SickLeavePatientRequestModel(); GetSickLeaveDoctorRequestModel _sickLeaveDoctorRequestModel = GetSickLeaveDoctorRequestModel(); diff --git a/lib/core/service/patient_medical_file/ucaf/patient-ucaf-service.dart b/lib/core/service/patient_medical_file/ucaf/patient-ucaf-service.dart index 53fa257e..23b1a70e 100644 --- a/lib/core/service/patient_medical_file/ucaf/patient-ucaf-service.dart +++ b/lib/core/service/patient_medical_file/ucaf/patient-ucaf-service.dart @@ -29,7 +29,7 @@ class UcafService extends LookupService { if (patientChiefComplaintList != null) { patientChiefComplaintList.clear(); } else { - patientChiefComplaintList = new List(); + patientChiefComplaintList = new []; } response['List_ChiefComplaint']['entityList'].forEach((v) { patientChiefComplaintList.add(GetChiefComplaintResModel.fromJson(v)); @@ -59,7 +59,7 @@ class UcafService extends LookupService { if (patientVitalSignsHistory != null) { patientVitalSignsHistory.clear(); } else { - patientVitalSignsHistory = new List(); + patientVitalSignsHistory = new []; } if (response['List_DoctorPatientVitalSign'] != null) { response['List_DoctorPatientVitalSign'].forEach((v) { @@ -96,7 +96,7 @@ class UcafService extends LookupService { if (patientVitalSignsHistory != null) { patientVitalSignsHistory.clear(); } else { - patientVitalSignsHistory = new List(); + patientVitalSignsHistory = new []; } if (response['VitalSignsHistory'] != null) { response['VitalSignsHistory'].forEach((v) { diff --git a/lib/core/service/pending_order_service.dart b/lib/core/service/pending_order_service.dart index e6f35bb8..f0bcf5e9 100644 --- a/lib/core/service/pending_order_service.dart +++ b/lib/core/service/pending_order_service.dart @@ -6,10 +6,10 @@ import 'package:doctor_app_flutter/models/pending_orders/pending_order_request_m import 'package:doctor_app_flutter/models/pending_orders/pending_orders_model.dart'; class PendingOrderService extends BaseService { - List _pendingOrderList = List(); + List _pendingOrderList = []; List get pendingOrderList => _pendingOrderList; - List _admissionOrderList = List(); + List _admissionOrderList = []; List get admissionOrderList => _admissionOrderList; Future getPendingOrders( diff --git a/lib/core/viewModel/LiveCarePatientViewModel.dart b/lib/core/viewModel/LiveCarePatientViewModel.dart index 53feedd1..49f2f1bc 100644 --- a/lib/core/viewModel/LiveCarePatientViewModel.dart +++ b/lib/core/viewModel/LiveCarePatientViewModel.dart @@ -47,7 +47,7 @@ class LiveCarePatientViewModel extends BaseViewModel { Future endCall(int vCID, bool isPatient) async { await getDoctorProfile(isGetProfile: true); EndCallReq endCallReq = new EndCallReq(); - endCallReq.doctorId = doctorProfile.doctorID; + endCallReq.doctorId = doctorProfile!.doctorID; endCallReq.generalid = 'Cs2020@2016\$2958'; endCallReq.vCID = vCID; endCallReq.isDestroy = isPatient; @@ -70,15 +70,15 @@ class LiveCarePatientViewModel extends BaseViewModel { Future startCall({int vCID, bool isReCall}) async { StartCallReq startCallReq = new StartCallReq(); await getDoctorProfile(); - startCallReq.clinicId = super.doctorProfile.clinicID; + startCallReq.clinicId = super.doctorProfile!.clinicID; startCallReq.vCID = vCID; //["VC_ID"]; startCallReq.isrecall = isReCall; - startCallReq.doctorId = doctorProfile.doctorID; + startCallReq.doctorId = doctorProfile!.doctorID; startCallReq.isOutKsa = false; //["IsOutKSA"]; - startCallReq.projectName = doctorProfile.projectName; - startCallReq.docotrName = doctorProfile.doctorName; - startCallReq.clincName = doctorProfile.clinicDescription; - startCallReq.docSpec = doctorProfile.doctorTitleForProfile; + startCallReq.projectName = doctorProfile!.projectName; + startCallReq.docotrName = doctorProfile!.doctorName; + startCallReq.clincName = doctorProfile!.clinicDescription; + startCallReq.docSpec = doctorProfile!.doctorTitleForProfile; startCallReq.generalid = 'Cs2020@2016\$2958'; setState(ViewState.BusyLocal); @@ -116,7 +116,7 @@ class LiveCarePatientViewModel extends BaseViewModel { } List getSelectedAlternativeServices() { - List selectedServices = List(); + List selectedServices = []; for (AlternativeService service in alternativeServicesList) { if (service.isSelected) { selectedServices.add(service.serviceID); @@ -184,7 +184,7 @@ class LiveCarePatientViewModel extends BaseViewModel { await getDoctorProfile(isGetProfile: true); LiveCareUserLoginRequestModel userLoginRequestModel = new LiveCareUserLoginRequestModel(); - userLoginRequestModel.isOutKsa = (doctorProfile.projectID == 2 || doctorProfile.projectID == 3) ? 1 : 0; + userLoginRequestModel.isOutKsa = (doctorProfile!.projectID == 2 || doctorProfile!.projectID == 3) ? 1 : 0; userLoginRequestModel.isLogin = loginStatus; userLoginRequestModel.generalid = "Cs2020@2016\$2958"; diff --git a/lib/core/viewModel/PatientSearchViewModel.dart b/lib/core/viewModel/PatientSearchViewModel.dart index 5acc6f07..f56c98e1 100644 --- a/lib/core/viewModel/PatientSearchViewModel.dart +++ b/lib/core/viewModel/PatientSearchViewModel.dart @@ -70,7 +70,7 @@ class PatientSearchViewModel extends BaseViewModel { setState(ViewState.Busy); } await getDoctorProfile(isGetProfile: true); - patientSearchRequestModel.doctorID = doctorProfile.doctorID; + patientSearchRequestModel.doctorID = doctorProfile!.doctorID; await _outPatientService.getOutPatient(patientSearchRequestModel); if (_outPatientService.hasError) { error = _outPatientService.error; @@ -163,8 +163,8 @@ class PatientSearchViewModel extends BaseViewModel { List get myIinPatientList => _inPatientService.myInPatientList; - List filteredInPatientItems = List(); - List filteredMyInPatientItems = List(); + List filteredInPatientItems = []; + List filteredMyInPatientItems = []; Future getInPatientList(PatientSearchRequestModel requestModel, {bool isMyInpatient = false, bool isLocalBusy = false}) async { diff --git a/lib/core/viewModel/SOAP_view_model.dart b/lib/core/viewModel/SOAP_view_model.dart index 8785fda2..3aa49db8 100644 --- a/lib/core/viewModel/SOAP_view_model.dart +++ b/lib/core/viewModel/SOAP_view_model.dart @@ -855,9 +855,9 @@ class SOAPViewModel extends BaseViewModel { appointmentNo: patientInfo.appointmentNo, severity: allergy.selectedAllergySeverity.id, remarks: allergy.remark, - createdBy: allergy.createdBy ?? doctorProfile.doctorID, + createdBy: allergy.createdBy ?? doctorProfile!.doctorID, createdOn: DateTime.now().toIso8601String(), - editedBy: doctorProfile.doctorID, + editedBy: doctorProfile!.doctorID, editedOn: DateTime.now().toIso8601String(), isChecked: allergy.isChecked, isUpdatedByNurse: false)); diff --git a/lib/core/viewModel/base_view_model.dart b/lib/core/viewModel/base_view_model.dart index d50a8d5a..f55aca90 100644 --- a/lib/core/viewModel/base_view_model.dart +++ b/lib/core/viewModel/base_view_model.dart @@ -8,7 +8,7 @@ import 'package:flutter/material.dart'; class BaseViewModel extends ChangeNotifier { DrAppSharedPreferances sharedPref = new DrAppSharedPreferances(); - DoctorProfileModel doctorProfile; + DoctorProfileModel ? doctorProfile; ViewState _state = ViewState.Idle; bool isInternetConnection = true; @@ -22,26 +22,22 @@ class BaseViewModel extends ChangeNotifier { void setState(ViewState viewState) { _state = viewState; - notifyListeners(); + notifyListeners(); } - Future getDoctorProfile({bool isGetProfile = false}) async { + Future ?getDoctorProfile({bool isGetProfile = false}) async { if (isGetProfile) { - Map profile = await sharedPref.getObj(DOCTOR_PROFILE); - if (profile != null) { - doctorProfile = DoctorProfileModel.fromJson(profile); - if (doctorProfile != null) { - return doctorProfile; - } + Map profile = await sharedPref.getObj(DOCTOR_PROFILE); + doctorProfile = DoctorProfileModel.fromJson(profile); + if (doctorProfile != null) { + return doctorProfile; } } if (doctorProfile == null) { - Map profile = await sharedPref.getObj(DOCTOR_PROFILE); - if (profile != null) { - doctorProfile = DoctorProfileModel.fromJson(profile); - if (doctorProfile != null) { - return doctorProfile; - } + Map profile = await sharedPref.getObj(DOCTOR_PROFILE); + doctorProfile = DoctorProfileModel.fromJson(profile); + if (doctorProfile != null) { + return doctorProfile; } return null; } else { @@ -51,13 +47,13 @@ class BaseViewModel extends ChangeNotifier { void getIsolateDoctorProfile(bool isGetProfile) async { if (isGetProfile) { - Map profile = await sharedPref.getObj(DOCTOR_PROFILE); + Map profile = await sharedPref.getObj(DOCTOR_PROFILE); if (profile != null) { doctorProfile = DoctorProfileModel.fromJson(profile); } } if (doctorProfile == null) { - Map profile = await sharedPref.getObj(DOCTOR_PROFILE); + Map profile = await sharedPref.getObj(DOCTOR_PROFILE); if (profile != null) { doctorProfile = DoctorProfileModel.fromJson(profile); } diff --git a/lib/core/viewModel/dashboard_view_model.dart b/lib/core/viewModel/dashboard_view_model.dart index 04e63dd9..0e5cedaf 100644 --- a/lib/core/viewModel/dashboard_view_model.dart +++ b/lib/core/viewModel/dashboard_view_model.dart @@ -94,9 +94,9 @@ class DashboardViewModel extends BaseViewModel { setState(ViewState.BusyLocal); await getDoctorProfile(); ClinicModel clinicModel = ClinicModel( - doctorID: doctorProfile.doctorID, + doctorID: doctorProfile!.doctorID, clinicID: clinicId, - projectID: doctorProfile.projectID, + projectID: doctorProfile!.projectID, ); await authProvider.getDoctorProfileBasedOnClinic(clinicModel); if (authProvider.state == ViewState.ErrorLocal) { diff --git a/lib/core/viewModel/doctor_replay_view_model.dart b/lib/core/viewModel/doctor_replay_view_model.dart index 707fb805..d66fa68f 100644 --- a/lib/core/viewModel/doctor_replay_view_model.dart +++ b/lib/core/viewModel/doctor_replay_view_model.dart @@ -52,8 +52,8 @@ class DoctorReplayViewModel extends BaseViewModel { transactionNo: model.transactionNo.toString(), doctorResponse: response, infoStatus: 6, - createdBy: this.doctorProfile.doctorID, - infoEnteredBy: this.doctorProfile.doctorID, + createdBy: this.doctorProfile!.doctorID, + infoEnteredBy: this.doctorProfile!.doctorID, setupID: "010266"); setState(ViewState.BusyLocal); await _doctorReplyService.createDoctorResponse(createDoctorResponseModel); diff --git a/lib/core/viewModel/labs_view_model.dart b/lib/core/viewModel/labs_view_model.dart index d83aee2a..27fe6ebe 100644 --- a/lib/core/viewModel/labs_view_model.dart +++ b/lib/core/viewModel/labs_view_model.dart @@ -20,8 +20,8 @@ class LabsViewModel extends BaseViewModel { List get labOrdersResultsList => _labsService.labOrdersResultsList; List get allSpecialLabList => _labsService.allSpecialLab; - List _patientLabOrdersListClinic = List(); - List _patientLabOrdersListHospital = List(); + List _patientLabOrdersListClinic = []; + List _patientLabOrdersListHospital = []; List get patientLabOrdersList => filterType == FilterType.Clinic ? _patientLabOrdersListClinic : _patientLabOrdersListHospital; @@ -79,7 +79,7 @@ class LabsViewModel extends BaseViewModel { List get labResultList => _labsService.labResultList; - List labResultLists = List(); + List labResultLists = []; List get labResultListsCoustom { return labResultLists; diff --git a/lib/core/viewModel/medicine_view_model.dart b/lib/core/viewModel/medicine_view_model.dart index 8ccf1a70..9bb43796 100644 --- a/lib/core/viewModel/medicine_view_model.dart +++ b/lib/core/viewModel/medicine_view_model.dart @@ -18,7 +18,7 @@ class MedicineViewModel extends BaseViewModel { ProcedureService _procedureService = locator(); PrescriptionService _prescriptionService = locator(); List get procedureTemplate => _procedureService.templateList; - List templateList = List(); + List templateList = []; get pharmacyItemsList => _medicineService.pharmacyItemsList; get searchText => _medicineService.searchText; get pharmaciesList => _medicineService.pharmaciesList; diff --git a/lib/core/viewModel/patient-referral-viewmodel.dart b/lib/core/viewModel/patient-referral-viewmodel.dart index 93635629..9eaf94f7 100644 --- a/lib/core/viewModel/patient-referral-viewmodel.dart +++ b/lib/core/viewModel/patient-referral-viewmodel.dart @@ -115,7 +115,7 @@ class PatientReferralViewModel extends BaseViewModel { Future getDoctorBranch() async { DoctorProfileModel doctorProfile = await getDoctorProfile(); if (doctorProfile != null) { - dynamic _selectedBranch = {"facilityId": doctorProfile.projectID, "facilityName": doctorProfile.projectName}; + dynamic _selectedBranch = {"facilityId": doctorProfile!.projectID, "facilityName": doctorProfile!.projectName}; return _selectedBranch; } return null; diff --git a/lib/core/viewModel/prescription_view_model.dart b/lib/core/viewModel/prescription_view_model.dart index 96645618..22eba8f6 100644 --- a/lib/core/viewModel/prescription_view_model.dart +++ b/lib/core/viewModel/prescription_view_model.dart @@ -38,8 +38,8 @@ class PrescriptionViewModel extends BaseViewModel { List get itemMedicineList => _prescriptionService.itemMedicineList; PrescriptionsService _prescriptionsService = locator(); - List _prescriptionsOrderListClinic = List(); - List _prescriptionsOrderListHospital = List(); + List _prescriptionsOrderListClinic = []; + List _prescriptionsOrderListHospital = []; List get prescriptionReportList => _prescriptionsService.prescriptionReportList; diff --git a/lib/core/viewModel/prescriptions_view_model.dart b/lib/core/viewModel/prescriptions_view_model.dart index 2548a59c..b420e724 100644 --- a/lib/core/viewModel/prescriptions_view_model.dart +++ b/lib/core/viewModel/prescriptions_view_model.dart @@ -17,8 +17,8 @@ class PrescriptionsViewModel extends BaseViewModel { FilterType filterType = FilterType.Clinic; PrescriptionsService _prescriptionsService = locator(); - List _prescriptionsOrderListClinic = List(); - List _prescriptionsOrderListHospital = List(); + List _prescriptionsOrderListClinic = []; + List _prescriptionsOrderListHospital = []; List get prescriptionReportList => _prescriptionsService.prescriptionReportList; @@ -32,7 +32,7 @@ class PrescriptionsViewModel extends BaseViewModel { List get medicationForInPatient => _prescriptionsService.medicationForInPatient; - List _medicationForInPatient = List(); + List _medicationForInPatient = []; getPrescriptions(PatiantInformtion patient) async { setState(ViewState.Busy); diff --git a/lib/core/viewModel/procedure_View_model.dart b/lib/core/viewModel/procedure_View_model.dart index b576b7a4..f1b62892 100644 --- a/lib/core/viewModel/procedure_View_model.dart +++ b/lib/core/viewModel/procedure_View_model.dart @@ -40,8 +40,8 @@ class ProcedureViewModel extends BaseViewModel { List get categoryList => _procedureService.categoryList; RadiologyService _radiologyService = locator(); LabsService _labsService = locator(); - List _finalRadiologyListClinic = List(); - List _finalRadiologyListHospital = List(); + List _finalRadiologyListClinic = []; + List _finalRadiologyListHospital = []; List get finalRadiologyList => filterType == FilterType.Clinic ? _finalRadiologyListClinic : _finalRadiologyListHospital; @@ -53,12 +53,12 @@ class ProcedureViewModel extends BaseViewModel { List get labOrdersResultsList => _labsService.labOrdersResultsList; List get procedureTemplate => _procedureService.templateList; - List templateList = List(); + List templateList = []; List get procedureTemplateDetails => _procedureService.templateDetailsList; - List _patientLabOrdersListClinic = List(); - List _patientLabOrdersListHospital = List(); + List _patientLabOrdersListClinic = []; + List _patientLabOrdersListHospital = []; Future getProcedure({int mrn, String patientType, int appointmentNo}) async { hasError = false; @@ -252,7 +252,7 @@ class ProcedureViewModel extends BaseViewModel { List get labResultList => _labsService.labResultList; - List labResultLists = List(); + List labResultLists = []; List get labResultListsCoustom { return labResultLists; @@ -322,7 +322,7 @@ class ProcedureViewModel extends BaseViewModel { procedureValadteRequestModel.episodeID = patient.episodeNo; procedureValadteRequestModel.appointmentNo = patient.appointmentNo; - List controlsProcedure = List(); + List controlsProcedure = []; postProcedureReqModel.appointmentNo = patient.appointmentNo; postProcedureReqModel.episodeID = patient.episodeNo; @@ -330,7 +330,7 @@ class ProcedureViewModel extends BaseViewModel { entityList.forEach((element) { procedureValadteRequestModel.procedure = [element.procedureId]; - List controls = List(); + List controls = []; controls.add( Controls(code: "remarks", controlValue: element.remarks != null ? element.remarks : ""), ); diff --git a/lib/core/viewModel/project_view_model.dart b/lib/core/viewModel/project_view_model.dart index b363800f..bb310558 100644 --- a/lib/core/viewModel/project_view_model.dart +++ b/lib/core/viewModel/project_view_model.dart @@ -111,7 +111,7 @@ class ProjectViewModel with ChangeNotifier { void getProfile() async { Map profile = await sharedPref.getObj(DOCTOR_PROFILE); DoctorProfileModel doctorProfile = new DoctorProfileModel.fromJson(profile); - ClinicModel clinicModel = ClinicModel(doctorID:doctorProfile.doctorID,clinicID: doctorProfile.clinicID, projectID: doctorProfile.projectID,); + ClinicModel clinicModel = ClinicModel(doctorID:doctorProfile!.doctorID,clinicID: doctorProfile!.clinicID, projectID: doctorProfile!.projectID,); await Provider.of(AppGlobal.CONTEX, listen: false) .getDoctorProfileBasedOnClinic(clinicModel); diff --git a/lib/core/viewModel/radiology_view_model.dart b/lib/core/viewModel/radiology_view_model.dart index d656de6c..88563c8e 100644 --- a/lib/core/viewModel/radiology_view_model.dart +++ b/lib/core/viewModel/radiology_view_model.dart @@ -12,8 +12,8 @@ class RadiologyViewModel extends BaseViewModel { FilterType filterType = FilterType.Clinic; RadiologyService _radiologyService = locator(); - List _finalRadiologyListClinic = List(); - List _finalRadiologyListHospital = List(); + List _finalRadiologyListClinic = []; + List _finalRadiologyListHospital = []; List get finalRadiologyList => filterType == FilterType.Clinic diff --git a/lib/landing_page.dart b/lib/landing_page.dart index fcdb1eff..169f97a3 100644 --- a/lib/landing_page.dart +++ b/lib/landing_page.dart @@ -113,7 +113,7 @@ class MyAppbar extends StatelessWidget with PreferredSizeWidget { @override final Size preferredSize; - MyAppbar({Key key}) + MyAppbar({Key ? key}) : preferredSize = Size.fromHeight(0.0), super(key: key); @override diff --git a/lib/screens/doctor/doctor_replay/all_doctor_questions.dart b/lib/screens/doctor/doctor_replay/all_doctor_questions.dart index 5166d2b1..8295ca39 100644 --- a/lib/screens/doctor/doctor_replay/all_doctor_questions.dart +++ b/lib/screens/doctor/doctor_replay/all_doctor_questions.dart @@ -14,7 +14,7 @@ import 'doctor_repaly_chat.dart'; class AllDoctorQuestions extends StatefulWidget { final Function changeCurrentTab; - const AllDoctorQuestions({Key key, this.changeCurrentTab}) : super(key: key); + const AllDoctorQuestions({Key ? key, this.changeCurrentTab}) : super(key: key); @override _AllDoctorQuestionsState createState() => _AllDoctorQuestionsState(); diff --git a/lib/screens/doctor/doctor_replay/doctor_repaly_chat.dart b/lib/screens/doctor/doctor_replay/doctor_repaly_chat.dart index cda899f1..9de8befd 100644 --- a/lib/screens/doctor/doctor_replay/doctor_repaly_chat.dart +++ b/lib/screens/doctor/doctor_replay/doctor_repaly_chat.dart @@ -25,7 +25,7 @@ class DoctorReplayChat extends StatefulWidget { final DoctorReplayViewModel previousModel; bool showMsgBox = false; DoctorReplayChat( - {Key key, this.reply, this.previousModel, + {Key ? key, this.reply, this.previousModel, }); @override @@ -270,7 +270,7 @@ class _DoctorReplayChatState extends State { width: 50, height: 50, child: Image.asset( - widget.previousModel.doctorProfile.gender == 0 + widget.previousModel.doctorProfile!.gender == 0 ? 'assets/images/male_avatar.png' : 'assets/images/female_avatar.png', fit: BoxFit.cover, @@ -281,7 +281,7 @@ class _DoctorReplayChatState extends State { Container( width: MediaQuery.of(context).size.width * 0.35, child: AppText( - widget.previousModel.doctorProfile.doctorName, + widget.previousModel.doctorProfile!.doctorName, fontSize: SizeConfig.getTextMultiplierBasedOnWidth() *3, fontFamily: 'Poppins', color: Color(0xFF2B353E), diff --git a/lib/screens/doctor/doctor_replay/doctor_reply_screen.dart b/lib/screens/doctor/doctor_replay/doctor_reply_screen.dart index 7957d4bd..f9596fc6 100644 --- a/lib/screens/doctor/doctor_replay/doctor_reply_screen.dart +++ b/lib/screens/doctor/doctor_replay/doctor_reply_screen.dart @@ -30,7 +30,7 @@ import 'not_replaied_Doctor_Questions.dart'; class DoctorReplyScreen extends StatefulWidget { final Function changeCurrentTab; - const DoctorReplyScreen({Key key, this.changeCurrentTab}) : super(key: key); + const DoctorReplyScreen({Key ? key, this.changeCurrentTab}) : super(key: key); @override _DoctorReplyScreenState createState() => _DoctorReplyScreenState(); diff --git a/lib/screens/doctor/doctor_replay/doctor_reply_widget.dart b/lib/screens/doctor/doctor_replay/doctor_reply_widget.dart index ecd0f93d..7e9a1603 100644 --- a/lib/screens/doctor/doctor_replay/doctor_reply_widget.dart +++ b/lib/screens/doctor/doctor_replay/doctor_reply_widget.dart @@ -18,7 +18,7 @@ class DoctorReplyWidget extends StatefulWidget { final ListGtMyPatientsQuestions reply; bool isShowMore = false; - DoctorReplyWidget({Key key, this.reply}); + DoctorReplyWidget({Key ? key, this.reply}); @override _DoctorReplyWidgetState createState() => _DoctorReplyWidgetState(); diff --git a/lib/screens/home/dashboard_referral_patient.dart b/lib/screens/home/dashboard_referral_patient.dart index 0bae430a..308aad15 100644 --- a/lib/screens/home/dashboard_referral_patient.dart +++ b/lib/screens/home/dashboard_referral_patient.dart @@ -17,7 +17,7 @@ class DashboardReferralPatient extends StatelessWidget { final double height; final DashboardViewModel model; - const DashboardReferralPatient({Key key, this.dashboardItemList, this.height, this.model}) : super(key: key); + const DashboardReferralPatient({Key ? key, this.dashboardItemList, this.height, this.model}) : super(key: key); @override Widget build(BuildContext context) { return Container( diff --git a/lib/screens/home/home_page_card.dart b/lib/screens/home/home_page_card.dart index 39a99e65..94466dee 100644 --- a/lib/screens/home/home_page_card.dart +++ b/lib/screens/home/home_page_card.dart @@ -8,7 +8,7 @@ class HomePageCard extends StatelessWidget { this.imageName, this.child, this.onTap, - Key key, + Key ? key, this.color, this.opacity = 0.4, this.margin, this.width, this.gradient}) diff --git a/lib/screens/home/home_screen.dart b/lib/screens/home/home_screen.dart index 2a1d7d1a..2303bbb2 100644 --- a/lib/screens/home/home_screen.dart +++ b/lib/screens/home/home_screen.dart @@ -367,7 +367,7 @@ class _HomeScreenState extends State { textColors[1] = Color(0xFF353E47); textColors[2] = Colors.white; - List patientCards = List(); + List patientCards = []; if (model.hasVirtualClinic) { patientCards.add(HomePatientCard( @@ -464,7 +464,7 @@ class _HomeScreenState extends State { patientSearchRequestModel: PatientSearchRequestModel( from: date, to: date, - doctorID: authenticationViewModel.doctorProfile.doctorID), + doctorID: authenticationViewModel.doctorProfile!.doctorID), ), settings: RouteSettings(name: 'OutPatientsScreen'), )); diff --git a/lib/screens/home/label.dart b/lib/screens/home/label.dart index 0d316652..74f62b6f 100644 --- a/lib/screens/home/label.dart +++ b/lib/screens/home/label.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class Label extends StatelessWidget { Label({ - Key key, this.firstLine, this.secondLine, this.color= const Color(0xFF2E303A), this.secondLineFontSize, this.firstLineFontSize, + Key ? key, this.firstLine, this.secondLine, this.color= const Color(0xFF2E303A), this.secondLineFontSize, this.firstLineFontSize, }) : super(key: key); final String firstLine; final String secondLine; diff --git a/lib/screens/live_care/live-care_transfer_to_admin.dart b/lib/screens/live_care/live-care_transfer_to_admin.dart index 233f59d8..d9882414 100644 --- a/lib/screens/live_care/live-care_transfer_to_admin.dart +++ b/lib/screens/live_care/live-care_transfer_to_admin.dart @@ -23,7 +23,7 @@ import 'package:speech_to_text/speech_to_text.dart' as stt; class LivaCareTransferToAdmin extends StatefulWidget { final PatiantInformtion patient; - const LivaCareTransferToAdmin({Key key, this.patient}) : super(key: key); + const LivaCareTransferToAdmin({Key ? key, this.patient}) : super(key: key); @override _LivaCareTransferToAdminState createState() => diff --git a/lib/screens/live_care/panding_list.dart b/lib/screens/live_care/panding_list.dart index f081479c..3e0b5c49 100644 --- a/lib/screens/live_care/panding_list.dart +++ b/lib/screens/live_care/panding_list.dart @@ -21,7 +21,7 @@ DrAppSharedPreferances sharedPref = DrAppSharedPreferances(); class LiveCarePandingListScreen extends StatefulWidget { // In the constructor, require a item id. - LiveCarePandingListScreen({Key key}) : super(key: key); + LiveCarePandingListScreen({Key ? key}) : super(key: key); @override _LiveCarePandingListState createState() => _LiveCarePandingListState(); diff --git a/lib/screens/medicine/pharmacies_list_screen.dart b/lib/screens/medicine/pharmacies_list_screen.dart index 49c39c53..b7c55c3f 100644 --- a/lib/screens/medicine/pharmacies_list_screen.dart +++ b/lib/screens/medicine/pharmacies_list_screen.dart @@ -23,7 +23,7 @@ class PharmaciesListScreen extends StatefulWidget { final String url; - PharmaciesListScreen({Key key, @required this.itemID, this.url}) + PharmaciesListScreen({Key ? key, @required this.itemID, this.url}) : super(key: key); @override diff --git a/lib/screens/patients/In_patient/in_patient_screen.dart b/lib/screens/patients/In_patient/in_patient_screen.dart index c0eaa510..37159611 100644 --- a/lib/screens/patients/In_patient/in_patient_screen.dart +++ b/lib/screens/patients/In_patient/in_patient_screen.dart @@ -26,7 +26,7 @@ class InPatientScreen extends StatefulWidget { bool isAllClinic = true; bool showBottomSheet = false; String ?selectedClinicName; - InPatientScreen({Key key, this.specialClinic}); + InPatientScreen({Key ? key, this.specialClinic}); @override _InPatientScreenState createState() => _InPatientScreenState(); diff --git a/lib/screens/patients/In_patient/list_of_all_in_patient.dart b/lib/screens/patients/In_patient/list_of_all_in_patient.dart index 06634819..9b589a00 100644 --- a/lib/screens/patients/In_patient/list_of_all_in_patient.dart +++ b/lib/screens/patients/In_patient/list_of_all_in_patient.dart @@ -42,7 +42,7 @@ class ListOfAllInPatient extends StatelessWidget { isInpatient: true, isMyPatient: patientSearchViewModel .filteredInPatientItems[index].doctorId == - patientSearchViewModel.doctorProfile.doctorID, + patientSearchViewModel.doctorProfile!.doctorID, onTap: () { FocusScopeNode currentFocus = FocusScope.of(context); if (!currentFocus.hasPrimaryFocus) { @@ -61,7 +61,7 @@ class ListOfAllInPatient extends StatelessWidget { "arrivalType": "1", "isMyPatient": patientSearchViewModel .filteredInPatientItems[index].doctorId == - patientSearchViewModel.doctorProfile.doctorID, + patientSearchViewModel.doctorProfile!.doctorID, }); }, ); diff --git a/lib/screens/patients/out_patient_prescription_details_screen.dart b/lib/screens/patients/out_patient_prescription_details_screen.dart index c7056ce3..3dce1b9e 100644 --- a/lib/screens/patients/out_patient_prescription_details_screen.dart +++ b/lib/screens/patients/out_patient_prescription_details_screen.dart @@ -12,7 +12,7 @@ import 'package:flutter/material.dart'; class OutPatientPrescriptionDetailsScreen extends StatefulWidget { final PrescriptionResModel prescriptionResModel; - OutPatientPrescriptionDetailsScreen({Key key, this.prescriptionResModel}); + OutPatientPrescriptionDetailsScreen({Key ? key, this.prescriptionResModel}); @override _OutPatientPrescriptionDetailsScreenState createState() => diff --git a/lib/screens/patients/patient_search/patient_search_screen.dart b/lib/screens/patients/patient_search/patient_search_screen.dart index e1fdd033..b3cfcada 100644 --- a/lib/screens/patients/patient_search/patient_search_screen.dart +++ b/lib/screens/patients/patient_search/patient_search_screen.dart @@ -139,7 +139,7 @@ class _PatientSearchScreenState extends State { }); PatientSearchRequestModel patientSearchRequestModel = PatientSearchRequestModel( - doctorID: authenticationViewModel.doctorProfile.doctorID); + doctorID: authenticationViewModel.doctorProfile!.doctorID); if (showOther) { patientSearchRequestModel.firstName = firstNameInfoController.text.trim().isEmpty diff --git a/lib/screens/patients/patient_search/time_bar.dart b/lib/screens/patients/patient_search/time_bar.dart index a1ee2cab..a1d61dce 100644 --- a/lib/screens/patients/patient_search/time_bar.dart +++ b/lib/screens/patients/patient_search/time_bar.dart @@ -14,7 +14,7 @@ class TimeBar extends StatefulWidget { final bool isSearchWithKeyInfo; const TimeBar( - {Key key, + {Key ? key, this.model, this.selectedPatientType, this.patientSearchRequestModel, diff --git a/lib/screens/patients/profile/UCAF/ucaf_pager_screen.dart b/lib/screens/patients/profile/UCAF/ucaf_pager_screen.dart index 80072f17..4408fdb0 100644 --- a/lib/screens/patients/profile/UCAF/ucaf_pager_screen.dart +++ b/lib/screens/patients/profile/UCAF/ucaf_pager_screen.dart @@ -18,7 +18,7 @@ import 'UCAF-detail-screen.dart'; import 'UCAF-input-screen.dart'; class UCAFPagerScreen extends StatefulWidget { - const UCAFPagerScreen({Key key}) : super(key: key); + const UCAFPagerScreen({Key ? key}) : super(key: key); @override _UCAFPagerScreenState createState() => _UCAFPagerScreenState(); diff --git a/lib/screens/patients/profile/diagnosis/diagnosis_screen.dart b/lib/screens/patients/profile/diagnosis/diagnosis_screen.dart index ce14d468..e2e2bd78 100644 --- a/lib/screens/patients/profile/diagnosis/diagnosis_screen.dart +++ b/lib/screens/patients/profile/diagnosis/diagnosis_screen.dart @@ -33,7 +33,7 @@ import 'package:provider/provider.dart'; DrAppSharedPreferances sharedPref = new DrAppSharedPreferances(); class DiagnosisScreen extends StatefulWidget { - const DiagnosisScreen({Key key}) : super(key: key); + const DiagnosisScreen({Key ? key}) : super(key: key); @override _ProgressNoteState createState() => _ProgressNoteState(); diff --git a/lib/screens/patients/profile/discharge_summary/discharge_summary.dart b/lib/screens/patients/profile/discharge_summary/discharge_summary.dart index fbe2f108..f5d92340 100644 --- a/lib/screens/patients/profile/discharge_summary/discharge_summary.dart +++ b/lib/screens/patients/profile/discharge_summary/discharge_summary.dart @@ -15,7 +15,7 @@ import 'pending_discharge_summary.dart'; class DischargeSummaryPage extends StatefulWidget { final Function changeCurrentTab; - const DischargeSummaryPage({Key key, this.changeCurrentTab}) + const DischargeSummaryPage({Key ? key, this.changeCurrentTab}) : super(key: key); @override diff --git a/lib/screens/patients/profile/discharge_summary/pending_discharge_summary.dart b/lib/screens/patients/profile/discharge_summary/pending_discharge_summary.dart index 0313371b..2deb1dd5 100644 --- a/lib/screens/patients/profile/discharge_summary/pending_discharge_summary.dart +++ b/lib/screens/patients/profile/discharge_summary/pending_discharge_summary.dart @@ -12,7 +12,7 @@ class PendingDischargeSummary extends StatefulWidget { final Function changeCurrentTab; final PatiantInformtion patient; - const PendingDischargeSummary({Key key, this.changeCurrentTab, this.patient}) + const PendingDischargeSummary({Key ? key, this.changeCurrentTab, this.patient}) : super(key: key); @override diff --git a/lib/screens/patients/profile/lab_result/LabResultWidget.dart b/lib/screens/patients/profile/lab_result/LabResultWidget.dart index 6ca92a4a..c0d3d6b6 100644 --- a/lib/screens/patients/profile/lab_result/LabResultWidget.dart +++ b/lib/screens/patients/profile/lab_result/LabResultWidget.dart @@ -21,7 +21,7 @@ class LabResultWidget extends StatelessWidget { final bool isInpatient; LabResultWidget( - {Key key, + {Key ? key, this.filterName, this.patientLabResultList, this.patientLabOrder, diff --git a/lib/screens/patients/profile/lab_result/lab_result_chart_and_detials.dart b/lib/screens/patients/profile/lab_result/lab_result_chart_and_detials.dart index 49fee0f4..d8303cd9 100644 --- a/lib/screens/patients/profile/lab_result/lab_result_chart_and_detials.dart +++ b/lib/screens/patients/profile/lab_result/lab_result_chart_and_detials.dart @@ -11,7 +11,7 @@ import 'Lab_Result_details_wideget.dart'; class LabResultChartAndDetails extends StatelessWidget { LabResultChartAndDetails({ - Key key, + Key ? key, @required this.labResult, @required this.name, }) : super(key: key); diff --git a/lib/screens/patients/profile/lab_result/lab_result_history_chart_and_detials.dart b/lib/screens/patients/profile/lab_result/lab_result_history_chart_and_detials.dart index 322eb817..4b9ffa44 100644 --- a/lib/screens/patients/profile/lab_result/lab_result_history_chart_and_detials.dart +++ b/lib/screens/patients/profile/lab_result/lab_result_history_chart_and_detials.dart @@ -9,7 +9,7 @@ import 'LineChartCurvedLabHistory.dart'; class LabResultHistoryChartAndDetails extends StatelessWidget { LabResultHistoryChartAndDetails({ - Key key, + Key ? key, @required this.labResultHistory, @required this.name, }) : super(key: key); diff --git a/lib/screens/patients/profile/lab_result/lab_result_secreen.dart b/lib/screens/patients/profile/lab_result/lab_result_secreen.dart index dd8ace01..4c67f9ed 100644 --- a/lib/screens/patients/profile/lab_result/lab_result_secreen.dart +++ b/lib/screens/patients/profile/lab_result/lab_result_secreen.dart @@ -14,7 +14,7 @@ import 'package:flutter/material.dart'; class LabResult extends StatefulWidget { final LabOrdersResModel labOrders; - LabResult({Key key, this.labOrders}); + LabResult({Key ? key, this.labOrders}); @override _LabResultState createState() => _LabResultState(); diff --git a/lib/screens/patients/profile/lab_result/laboratory_result_page.dart b/lib/screens/patients/profile/lab_result/laboratory_result_page.dart index 4ccd4379..84465b20 100644 --- a/lib/screens/patients/profile/lab_result/laboratory_result_page.dart +++ b/lib/screens/patients/profile/lab_result/laboratory_result_page.dart @@ -17,7 +17,7 @@ class LaboratoryResultPage extends StatefulWidget { final bool isInpatient; LaboratoryResultPage( - {Key key, + {Key ? key, this.patientLabOrders, this.patient, this.patientType, diff --git a/lib/screens/patients/profile/lab_result/laboratory_result_widget.dart b/lib/screens/patients/profile/lab_result/laboratory_result_widget.dart index 9bf81081..0da094ab 100644 --- a/lib/screens/patients/profile/lab_result/laboratory_result_widget.dart +++ b/lib/screens/patients/profile/lab_result/laboratory_result_widget.dart @@ -25,7 +25,7 @@ class LaboratoryResultWidget extends StatefulWidget { final bool isInpatient; const LaboratoryResultWidget( - {Key key, + {Key ? key, this.onTap, this.billNo, this.details, diff --git a/lib/screens/patients/profile/lab_result/special_lab_result_details_page.dart b/lib/screens/patients/profile/lab_result/special_lab_result_details_page.dart index db86dd72..014015a0 100644 --- a/lib/screens/patients/profile/lab_result/special_lab_result_details_page.dart +++ b/lib/screens/patients/profile/lab_result/special_lab_result_details_page.dart @@ -13,7 +13,7 @@ class SpecialLabResultDetailsPage extends StatelessWidget { final String resultData; final PatiantInformtion patient; - const SpecialLabResultDetailsPage({Key key, this.resultData, this.patient}) : super(key: key); + const SpecialLabResultDetailsPage({Key ? key, this.resultData, this.patient}) : super(key: key); @override Widget build(BuildContext context) { diff --git a/lib/screens/patients/profile/notes/note/progress_note_screen.dart b/lib/screens/patients/profile/notes/note/progress_note_screen.dart index 3e07f76e..ba1ef017 100644 --- a/lib/screens/patients/profile/notes/note/progress_note_screen.dart +++ b/lib/screens/patients/profile/notes/note/progress_note_screen.dart @@ -35,7 +35,7 @@ DrAppSharedPreferances sharedPref = new DrAppSharedPreferances(); class ProgressNoteScreen extends StatefulWidget { final int visitType; - const ProgressNoteScreen({Key key, this.visitType}) : super(key: key); + const ProgressNoteScreen({Key ? key, this.visitType}) : super(key: key); @override _ProgressNoteState createState() => _ProgressNoteState(); @@ -136,7 +136,7 @@ class _ProgressNoteState extends State { .status == 1 && authenticationViewModel - .doctorProfile.doctorID != + .doctorProfile!.doctorID != model .patientProgressNoteList[ index] @@ -163,7 +163,7 @@ class _ProgressNoteState extends State { .status == 1 && authenticationViewModel - .doctorProfile.doctorID != + .doctorProfile!.doctorID != model .patientProgressNoteList[ index] @@ -208,7 +208,7 @@ class _ProgressNoteState extends State { .status != 4 && authenticationViewModel - .doctorProfile.doctorID == + .doctorProfile!.doctorID == model .patientProgressNoteList[ index] diff --git a/lib/screens/patients/profile/notes/note/update_note.dart b/lib/screens/patients/profile/notes/note/update_note.dart index 3fde4262..5e76c457 100644 --- a/lib/screens/patients/profile/notes/note/update_note.dart +++ b/lib/screens/patients/profile/notes/note/update_note.dart @@ -35,7 +35,7 @@ class UpdateNoteOrder extends StatefulWidget { final bool isUpdate; const UpdateNoteOrder( - {Key key, + {Key ? key, this.note, this.patientModel, this.patient, @@ -232,7 +232,7 @@ class _UpdateNoteOrderState extends State { CreateNoteModel reqModel = CreateNoteModel( admissionNo: int.parse(widget.patient.admissionNo), - createdBy: doctorProfile.doctorID, + createdBy: doctorProfile!.doctorID, visitType: widget.visitType, patientID: widget.patient.patientId, nursingRemarks: ' ', diff --git a/lib/screens/patients/profile/operation_report/operation_report.dart b/lib/screens/patients/profile/operation_report/operation_report.dart index 7df24564..f0e611a6 100644 --- a/lib/screens/patients/profile/operation_report/operation_report.dart +++ b/lib/screens/patients/profile/operation_report/operation_report.dart @@ -286,7 +286,7 @@ class _ProgressNoteState extends State { // if ( // authenticationViewModel - // .doctorProfile.doctorID == + // .doctorProfile!.doctorID == // model // .operationReportList[ // index] diff --git a/lib/screens/patients/profile/operation_report/update_operation_report.dart b/lib/screens/patients/profile/operation_report/update_operation_report.dart index 85c36bae..11cd537d 100644 --- a/lib/screens/patients/profile/operation_report/update_operation_report.dart +++ b/lib/screens/patients/profile/operation_report/update_operation_report.dart @@ -581,7 +581,7 @@ class _UpdateOperationReportState extends State { admissionNo: int.parse( widget.patient.admissionNo), createdBy: - model.doctorProfile.doctorID, + model.doctorProfile!.doctorID, setupID: "010266"); await model.updateOperationReport( createUpdateOperationReportRequestModel); diff --git a/lib/screens/patients/profile/radiology/radiology_report_screen.dart b/lib/screens/patients/profile/radiology/radiology_report_screen.dart index e7714074..7b917ef2 100644 --- a/lib/screens/patients/profile/radiology/radiology_report_screen.dart +++ b/lib/screens/patients/profile/radiology/radiology_report_screen.dart @@ -11,7 +11,7 @@ class RadiologyReportScreen extends StatelessWidget { final String reportData; final String url; - RadiologyReportScreen({Key key, this.reportData, this.url}); + RadiologyReportScreen({Key ? key, this.reportData, this.url}); @override Widget build(BuildContext context) { diff --git a/lib/screens/patients/profile/referral/refer-patient-screen-in-patient.dart b/lib/screens/patients/profile/referral/refer-patient-screen-in-patient.dart index 41686ead..a6502733 100644 --- a/lib/screens/patients/profile/referral/refer-patient-screen-in-patient.dart +++ b/lib/screens/patients/profile/referral/refer-patient-screen-in-patient.dart @@ -126,7 +126,7 @@ class _PatientMakeInPatientReferralScreenState String patientType = routeArgs['patientType']; String arrivalType = routeArgs['arrivalType']; bool isInpatient = routeArgs['isInpatient']; - referToList = List(); + referToList = []; dynamic sameBranch = { "id": 1, "name": TranslationBase.of(context).sameBranch diff --git a/lib/screens/patients/profile/referral/refer-patient-screen.dart b/lib/screens/patients/profile/referral/refer-patient-screen.dart index bb89f6ce..850e017e 100644 --- a/lib/screens/patients/profile/referral/refer-patient-screen.dart +++ b/lib/screens/patients/profile/referral/refer-patient-screen.dart @@ -56,7 +56,7 @@ class _PatientMakeReferralScreenState extends State { String patientType = routeArgs['patientType']; String arrivalType = routeArgs['arrivalType']; - referToList = List(); + referToList = []; dynamic sameBranch = { "id": 1, "name": TranslationBase.of(context).sameBranch diff --git a/lib/screens/patients/profile/soap_update/assessment/add_assessment_details.dart b/lib/screens/patients/profile/soap_update/assessment/add_assessment_details.dart index 0410f239..af55c61b 100644 --- a/lib/screens/patients/profile/soap_update/assessment/add_assessment_details.dart +++ b/lib/screens/patients/profile/soap_update/assessment/add_assessment_details.dart @@ -34,7 +34,7 @@ class AddAssessmentDetails extends StatefulWidget { final bool isUpdate; AddAssessmentDetails( - {Key key, + {Key ? key, this.mySelectedAssessment, this.addSelectedAssessment, this.patientInfo, @@ -477,7 +477,7 @@ class _AddAssessmentDetailsState extends State { DoctorProfileModel doctorProfile = DoctorProfileModel.fromJson(profile); mySelectedAssessment.icdCode10ID = mySelectedAssessment.selectedICD.code; - mySelectedAssessment.doctorName = doctorProfile.doctorName; + mySelectedAssessment.doctorName = doctorProfile!.doctorName; widget.addSelectedAssessment(mySelectedAssessment, isUpdate); Navigator.of(context).pop(); } diff --git a/lib/screens/patients/profile/soap_update/assessment/update_assessment_page.dart b/lib/screens/patients/profile/soap_update/assessment/update_assessment_page.dart index a54b5140..836b0356 100644 --- a/lib/screens/patients/profile/soap_update/assessment/update_assessment_page.dart +++ b/lib/screens/patients/profile/soap_update/assessment/update_assessment_page.dart @@ -32,7 +32,7 @@ class UpdateAssessmentPage extends StatefulWidget { final int currentIndex; UpdateAssessmentPage( - {Key key, + {Key ? key, this.changePageViewIndex, this.patientInfo, this.changeLoadingState, @@ -45,7 +45,7 @@ class UpdateAssessmentPage extends StatefulWidget { class _UpdateAssessmentPageState extends State implements AssessmentCallBack { bool isAssessmentExpand = false; - List mySelectedAssessmentList = List(); + List mySelectedAssessmentList = []; @override Widget build(BuildContext context) { diff --git a/lib/screens/patients/profile/soap_update/objective/update_objective_page.dart b/lib/screens/patients/profile/soap_update/objective/update_objective_page.dart index a251aed4..c1721ff2 100644 --- a/lib/screens/patients/profile/soap_update/objective/update_objective_page.dart +++ b/lib/screens/patients/profile/soap_update/objective/update_objective_page.dart @@ -32,7 +32,7 @@ class UpdateObjectivePage extends StatefulWidget { final PatiantInformtion patientInfo; UpdateObjectivePage( - {Key key, + {Key ? key, this.changePageViewIndex, this.patientInfo, this.changeLoadingState, @@ -45,7 +45,7 @@ class UpdateObjectivePage extends StatefulWidget { class _UpdateObjectivePageState extends State implements ObjectiveCallBack { bool isSysExaminationExpand = false; - List mySelectedExamination = List(); + List mySelectedExamination = []; BoxDecoration containerBorderDecoration( Color containerColor, Color borderColor) { @@ -228,9 +228,9 @@ class _UpdateObjectivePageState extends State episodeId: widget.patientInfo.episodeNo == null?0: widget.patientInfo.episodeNo, appointmentNo: widget.patientInfo.appointmentNo == null?0:widget.patientInfo.appointmentNo, remarks: exam.remark ?? '', - createdBy: exam.createdBy ?? doctorProfile.doctorID, + createdBy: exam.createdBy ?? doctorProfile!.doctorID, createdOn: exam.createdOn ?? DateTime.now().toIso8601String(), - editedBy: doctorProfile.doctorID, + editedBy: doctorProfile!.doctorID, editedOn: DateTime.now().toIso8601String(), examId: exam.selectedExamination!.id, examType: exam.selectedExamination!.typeId, diff --git a/lib/screens/patients/profile/soap_update/plan/update_plan_page.dart b/lib/screens/patients/profile/soap_update/plan/update_plan_page.dart index cac5deeb..08bd697f 100644 --- a/lib/screens/patients/profile/soap_update/plan/update_plan_page.dart +++ b/lib/screens/patients/profile/soap_update/plan/update_plan_page.dart @@ -366,7 +366,7 @@ class _UpdatePlanPageState extends State } else { Map profile = await sharedPref.getObj(DOCTOR_PROFILE); DoctorProfileModel doctorProfile = DoctorProfileModel.fromJson(profile); - postProgressNoteRequestModel.editedBy = doctorProfile.doctorID; + postProgressNoteRequestModel.editedBy = doctorProfile!.doctorID; await widget.sOAPViewModel .patchProgressNote(postProgressNoteRequestModel); } diff --git a/lib/screens/patients/profile/soap_update/subjective/history/add_history_dialog.dart b/lib/screens/patients/profile/soap_update/subjective/history/add_history_dialog.dart index 4e9dac03..49c559a0 100644 --- a/lib/screens/patients/profile/soap_update/subjective/history/add_history_dialog.dart +++ b/lib/screens/patients/profile/soap_update/subjective/history/add_history_dialog.dart @@ -23,7 +23,7 @@ class AddHistoryDialog extends StatefulWidget { final Function(MasterKeyModel) removeHistory; const AddHistoryDialog( - {Key key, + {Key ? key, this.changePageViewIndex, this.controller, this.myHistoryList, diff --git a/lib/screens/patients/profile/soap_update/subjective/history/priority_bar.dart b/lib/screens/patients/profile/soap_update/subjective/history/priority_bar.dart index 57698f56..9b530d99 100644 --- a/lib/screens/patients/profile/soap_update/subjective/history/priority_bar.dart +++ b/lib/screens/patients/profile/soap_update/subjective/history/priority_bar.dart @@ -8,7 +8,7 @@ import 'package:provider/provider.dart'; class PriorityBar extends StatefulWidget { final Function onTap; - const PriorityBar({Key key, this.onTap}) : super(key: key); + const PriorityBar({Key ? key, this.onTap}) : super(key: key); @override _PriorityBarState createState() => _PriorityBarState(); diff --git a/lib/screens/patients/profile/soap_update/subjective/history/update_history_widget.dart b/lib/screens/patients/profile/soap_update/subjective/history/update_history_widget.dart index a3a58f7b..39031685 100644 --- a/lib/screens/patients/profile/soap_update/subjective/history/update_history_widget.dart +++ b/lib/screens/patients/profile/soap_update/subjective/history/update_history_widget.dart @@ -14,7 +14,7 @@ import 'add_history_dialog.dart'; class UpdateHistoryWidget extends StatefulWidget { final List myHistoryList; - const UpdateHistoryWidget({Key key, this.myHistoryList}) : super(key: key); + const UpdateHistoryWidget({Key ? key, this.myHistoryList}) : super(key: key); @override _UpdateHistoryWidgetState createState() => _UpdateHistoryWidgetState(); diff --git a/lib/screens/patients/profile/soap_update/subjective/update_subjective_page.dart b/lib/screens/patients/profile/soap_update/subjective/update_subjective_page.dart index 0b58d340..0c07483d 100644 --- a/lib/screens/patients/profile/soap_update/subjective/update_subjective_page.dart +++ b/lib/screens/patients/profile/soap_update/subjective/update_subjective_page.dart @@ -26,7 +26,7 @@ class UpdateSubjectivePage extends StatefulWidget { final int currentIndex; UpdateSubjectivePage( - {Key key, + {Key ? key, this.changePageViewIndex, this.patientInfo, this.changeLoadingState, @@ -46,8 +46,8 @@ class _UpdateSubjectivePageState extends State TextEditingController medicationController = TextEditingController(); final formKey = GlobalKey(); - List myAllergiesList = List(); - List myHistoryList = List(); + List myAllergiesList = []; + List myHistoryList = []; getHistory(SOAPViewModel model) async { widget.changeLoadingState(true); diff --git a/lib/screens/patients/profile/soap_update/update_soap_index.dart b/lib/screens/patients/profile/soap_update/update_soap_index.dart index 5642faa8..41629fb7 100644 --- a/lib/screens/patients/profile/soap_update/update_soap_index.dart +++ b/lib/screens/patients/profile/soap_update/update_soap_index.dart @@ -21,7 +21,7 @@ import 'plan/update_plan_page.dart'; class UpdateSoapIndex extends StatefulWidget { final bool isUpdate; - const UpdateSoapIndex({Key key, this.isUpdate}) : super(key: key); + const UpdateSoapIndex({Key ? key, this.isUpdate}) : super(key: key); @override _UpdateSoapIndexState createState() => _UpdateSoapIndexState(); @@ -31,8 +31,8 @@ class _UpdateSoapIndexState extends State with TickerProviderStateMixin { PageController _controller; int _currentIndex = 0; - List myAllergiesList = List(); - List myHistoryList = List(); + List myAllergiesList = []; + List myHistoryList = []; changePageViewIndex(pageIndex, {isChangeState = true}) { if (pageIndex != _currentIndex && isChangeState) changeLoadingState(true); diff --git a/lib/screens/patients/profile/vital_sign/vital_sign_details_blood_pressurewideget.dart b/lib/screens/patients/profile/vital_sign/vital_sign_details_blood_pressurewideget.dart index 69f45d6e..6567f3cd 100644 --- a/lib/screens/patients/profile/vital_sign/vital_sign_details_blood_pressurewideget.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sign_details_blood_pressurewideget.dart @@ -17,7 +17,7 @@ class VitalSignBloodPressureWidget extends StatefulWidget { final String viewKey2; VitalSignBloodPressureWidget( - {Key key, + {Key ? key, this.vitalList, this.title1, this.title2, diff --git a/lib/screens/patients/profile/vital_sign/vital_sign_details_wideget.dart b/lib/screens/patients/profile/vital_sign/vital_sign_details_wideget.dart index cec53580..f248e037 100644 --- a/lib/screens/patients/profile/vital_sign/vital_sign_details_wideget.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sign_details_wideget.dart @@ -15,7 +15,7 @@ class VitalSignDetailsWidget extends StatefulWidget { final String viewKey; VitalSignDetailsWidget( - {Key key, this.vitalList, this.title1, this.title2, this.viewKey}); + {Key ? key, this.vitalList, this.title1, this.title2, this.viewKey}); @override _VitalSignDetailsWidgetState createState() => _VitalSignDetailsWidgetState(); 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 20d5b439..c02cb5b1 100644 --- a/lib/screens/patients/profile/vital_sign/vital_sign_item.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sign_item.dart @@ -13,7 +13,7 @@ class VitalSignItem extends StatelessWidget { final double width; const VitalSignItem( - {Key key, + {Key ? key, @required this.des, this.lastVal = 'N/A', this.unit = '', 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 ef8049ce..ffb26985 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 @@ -11,7 +11,7 @@ import 'LineChartCurved.dart'; class VitalSingChartAndDetials extends StatelessWidget { VitalSingChartAndDetials({ - Key key, + Key ? key, @required this.vitalList, @required this.name, @required this.viewKey, diff --git a/lib/screens/patients/profile/vital_sign/vital_sing_chart_blood_pressure.dart b/lib/screens/patients/profile/vital_sign/vital_sing_chart_blood_pressure.dart index d0416539..a9b6a665 100644 --- a/lib/screens/patients/profile/vital_sign/vital_sing_chart_blood_pressure.dart +++ b/lib/screens/patients/profile/vital_sign/vital_sing_chart_blood_pressure.dart @@ -11,7 +11,7 @@ import 'LineChartCurvedBloodPressure.dart'; class VitalSingChartBloodPressure extends StatelessWidget { VitalSingChartBloodPressure({ - Key key, + Key ? key, @required this.vitalList, @required this.name, @required this.viewKey1, diff --git a/lib/screens/prescription/prescription_checkout_screen.dart b/lib/screens/prescription/prescription_checkout_screen.dart index cac2f99a..0985f014 100644 --- a/lib/screens/prescription/prescription_checkout_screen.dart +++ b/lib/screens/prescription/prescription_checkout_screen.dart @@ -37,7 +37,7 @@ class PrescriptionCheckOutScreen extends StatefulWidget { final List prescriptionList; final ProcedureTempleteDetailsModel groupProcedures; - const PrescriptionCheckOutScreen({Key key, this.model, this.patient, this.prescriptionList, this.groupProcedures}) + const PrescriptionCheckOutScreen({Key ? key, this.model, this.patient, this.prescriptionList, this.groupProcedures}) : super(key: key); @override @@ -62,7 +62,7 @@ class _PrescriptionCheckOutScreenState extends State PatiantInformtion patient, String patientType}) async { PostPrescriptionReqModel postProcedureReqModel = new PostPrescriptionReqModel(); - List prescriptionList = List(); + List prescriptionList = []; postProcedureReqModel.appointmentNo = patient.appointmentNo; postProcedureReqModel.clinicID = patient.clinicId; diff --git a/lib/screens/prescription/prescription_details_page.dart b/lib/screens/prescription/prescription_details_page.dart index 623cee90..9242bd91 100644 --- a/lib/screens/prescription/prescription_details_page.dart +++ b/lib/screens/prescription/prescription_details_page.dart @@ -8,7 +8,7 @@ import 'package:flutter/material.dart'; class PrescriptionDetailsPage extends StatelessWidget { final PrescriptionReport prescriptionReport; - PrescriptionDetailsPage({Key key, this.prescriptionReport}); + PrescriptionDetailsPage({Key ? key, this.prescriptionReport}); @override Widget build(BuildContext context) { diff --git a/lib/screens/prescription/prescription_item_in_patient_page.dart b/lib/screens/prescription/prescription_item_in_patient_page.dart index 84f38748..e5013704 100644 --- a/lib/screens/prescription/prescription_item_in_patient_page.dart +++ b/lib/screens/prescription/prescription_item_in_patient_page.dart @@ -23,7 +23,7 @@ class PrescriptionItemsInPatientPage extends StatelessWidget { final int prescriptionIndex; PrescriptionItemsInPatientPage( - {Key key, + {Key ? key, this.prescriptions, this.patient, this.patientType, diff --git a/lib/screens/prescription/prescription_items_page.dart b/lib/screens/prescription/prescription_items_page.dart index b97343c4..eaf2bd31 100644 --- a/lib/screens/prescription/prescription_items_page.dart +++ b/lib/screens/prescription/prescription_items_page.dart @@ -17,7 +17,7 @@ class PrescriptionItemsPage extends StatelessWidget { final PatiantInformtion patient; final String patientType; final String arrivalType; - PrescriptionItemsPage({Key key, this.prescriptions, this.patient, this.patientType, this.arrivalType}); + PrescriptionItemsPage({Key ? key, this.prescriptions, this.patient, this.patientType, this.arrivalType}); @override Widget build(BuildContext context) { diff --git a/lib/screens/prescription/update_prescription_form.dart b/lib/screens/prescription/update_prescription_form.dart index 01ba6a91..edd90190 100644 --- a/lib/screens/prescription/update_prescription_form.dart +++ b/lib/screens/prescription/update_prescription_form.dart @@ -84,7 +84,7 @@ class _UpdatePrescriptionFormState extends State { super.initState(); strengthController.text = widget.doseStreangth; remarksController.text = widget.remarks; - indicationList = List(); + indicationList = []; dynamic indication1 = {"id": 545, "name": "Gingival Hyperplasia"}; dynamic indication2 = {"id": 546, "name": "Mild Drowsiness"}; @@ -968,7 +968,7 @@ class _UpdatePrescriptionFormState extends State { //PrescriptionViewModel model = PrescriptionViewModel(); PostPrescriptionReqModel updatePrescriptionReqModel = new PostPrescriptionReqModel(); - List sss = List(); + List sss = []; updatePrescriptionReqModel.appointmentNo = patient.appointmentNo; updatePrescriptionReqModel.clinicID = patient.clinicId; diff --git a/lib/screens/procedures/ExpansionProcedure.dart b/lib/screens/procedures/ExpansionProcedure.dart index 06e56f03..45e79bf2 100644 --- a/lib/screens/procedures/ExpansionProcedure.dart +++ b/lib/screens/procedures/ExpansionProcedure.dart @@ -23,7 +23,7 @@ class ExpansionProcedure extends StatefulWidget { final ProcedureTempleteDetailsModel groupProcedures; const ExpansionProcedure( - {Key key, + {Key ? key, this.procedureTempleteModel, this.model, this.removeFavProcedure, diff --git a/lib/screens/procedures/ProcedureCard.dart b/lib/screens/procedures/ProcedureCard.dart index 82bb649c..77291c2c 100644 --- a/lib/screens/procedures/ProcedureCard.dart +++ b/lib/screens/procedures/ProcedureCard.dart @@ -20,7 +20,7 @@ class ProcedureCard extends StatelessWidget { final int doctorID; final bool isInpatient; const ProcedureCard({ - Key key, + Key ? key, this.onTap, this.entityList, this.categoryID, diff --git a/lib/screens/procedures/add-favourite-procedure.dart b/lib/screens/procedures/add-favourite-procedure.dart index 7f4e49b2..3fd6d460 100644 --- a/lib/screens/procedures/add-favourite-procedure.dart +++ b/lib/screens/procedures/add-favourite-procedure.dart @@ -25,7 +25,7 @@ class AddFavouriteProcedure extends StatefulWidget { final ProcedureType procedureType; AddFavouriteProcedure({ - Key key, + Key ? key, this.model, this.prescriptionModel, this.patient, @@ -41,7 +41,7 @@ class _AddFavouriteProcedureState extends State { ProcedureViewModel model; PatiantInformtion patient; - List entityList = List(); + List entityList = []; ProcedureTempleteDetailsModel groupProcedures; @override diff --git a/lib/screens/procedures/add-procedure-page.dart b/lib/screens/procedures/add-procedure-page.dart index e0b7374f..4bdf1b2e 100644 --- a/lib/screens/procedures/add-procedure-page.dart +++ b/lib/screens/procedures/add-procedure-page.dart @@ -21,7 +21,7 @@ class AddProcedurePage extends StatefulWidget { final ProcedureType procedureType; const AddProcedurePage( - {Key key, this.model, this.patient, @required this.procedureType}) + {Key ? key, this.model, this.patient, @required this.procedureType}) : super(key: key); @override @@ -39,8 +39,8 @@ class _AddProcedurePageState extends State { TextEditingController procedureController = TextEditingController(); TextEditingController remarksController = TextEditingController(); - List entityList = List(); - List entityListProcedure = List(); + List entityList = []; + List entityListProcedure = []; TextEditingController procedureName = TextEditingController(); dynamic selectedCategory; diff --git a/lib/screens/procedures/base_add_procedure_tab_page.dart b/lib/screens/procedures/base_add_procedure_tab_page.dart index e9ab695b..727c0449 100644 --- a/lib/screens/procedures/base_add_procedure_tab_page.dart +++ b/lib/screens/procedures/base_add_procedure_tab_page.dart @@ -21,7 +21,7 @@ class BaseAddProcedureTabPage extends StatefulWidget { final ProcedureType procedureType; const BaseAddProcedureTabPage( - {Key key, + {Key ? key, this.model, this.prescriptionModel, this.patient, diff --git a/lib/screens/procedures/entity_list_checkbox_search_widget.dart b/lib/screens/procedures/entity_list_checkbox_search_widget.dart index 725bb007..dc5c344e 100644 --- a/lib/screens/procedures/entity_list_checkbox_search_widget.dart +++ b/lib/screens/procedures/entity_list_checkbox_search_widget.dart @@ -21,7 +21,7 @@ class EntityListCheckboxSearchWidget extends StatefulWidget { /// todo clear the function here EntityListCheckboxSearchWidget( - {Key key, + {Key ? key, this.model, this.addSelectedHistories, this.removeHistory, @@ -48,9 +48,9 @@ class _EntityListCheckboxSearchWidgetState }); } - List items = List(); - List remarksList = List(); - List typeList = List(); + List items = []; + List remarksList = []; + List typeList = []; @override void initState() { @@ -245,10 +245,10 @@ class _EntityListCheckboxSearchWidgetState } void filterSearchResults(String query) { - List dummySearchList = List(); + List dummySearchList = []; dummySearchList.addAll(widget.masterList); if (query.isNotEmpty) { - List dummyListData = List(); + List dummyListData = []; dummySearchList.forEach((item) { if (item.procedureName.toLowerCase().contains(query.toLowerCase())) { dummyListData.add(item); diff --git a/lib/screens/procedures/entity_list_fav_procedure.dart b/lib/screens/procedures/entity_list_fav_procedure.dart index 8d4f93ed..05287322 100644 --- a/lib/screens/procedures/entity_list_fav_procedure.dart +++ b/lib/screens/procedures/entity_list_fav_procedure.dart @@ -32,7 +32,7 @@ class EntityListCheckboxSearchFavProceduresWidget extends StatefulWidget { final bool isProcedure; EntityListCheckboxSearchFavProceduresWidget( - {Key key, + {Key ? key, this.model, this.addSelectedHistories, this.removeHistory, @@ -64,10 +64,10 @@ class _EntityListCheckboxSearchFavProceduresWidgetState extends State items = List(); - List itemsProcedure = List(); - List remarksList = List(); - List typeList = List(); + List items = []; + List itemsProcedure = []; + List remarksList = []; + List typeList = []; @override void initState() { @@ -135,10 +135,10 @@ class _EntityListCheckboxSearchFavProceduresWidgetState extends State dummySearchList = List(); + List dummySearchList = []; dummySearchList.addAll(widget.masterList); if (query.isNotEmpty) { - List dummyListData = List(); + List dummyListData = []; dummySearchList.forEach((item) { if (item.templateName.toLowerCase().contains(query.toLowerCase())) { dummyListData.add(item); diff --git a/lib/screens/procedures/procedure_checkout_screen.dart b/lib/screens/procedures/procedure_checkout_screen.dart index 45b84940..3854ecd4 100644 --- a/lib/screens/procedures/procedure_checkout_screen.dart +++ b/lib/screens/procedures/procedure_checkout_screen.dart @@ -30,9 +30,9 @@ class ProcedureCheckOutScreen extends StatefulWidget { } class _ProcedureCheckOutScreenState extends State { - List remarksList = List(); + List remarksList = []; final TextEditingController remarksController = TextEditingController(); - List typeList = List(); + List typeList = []; @override Widget build(BuildContext context) { @@ -198,7 +198,7 @@ class _ProcedureCheckOutScreenState extends State { color: Color(0xff359846), fontWeight: FontWeight.w700, onPressed: () async { - List entityList = List(); + List entityList = []; widget.items.forEach((element) { entityList.add( EntityList( diff --git a/lib/screens/procedures/procedure_screen.dart b/lib/screens/procedures/procedure_screen.dart index 79fb961c..e1c82c63 100644 --- a/lib/screens/procedures/procedure_screen.dart +++ b/lib/screens/procedures/procedure_screen.dart @@ -24,7 +24,7 @@ class ProcedureScreen extends StatelessWidget { void initState() async { Map profile = await sharedPref.getObj(DOCTOR_PROFILE); DoctorProfileModel doctorProfile = DoctorProfileModel.fromJson(profile); - doctorNameP = doctorProfile.doctorID; + doctorNameP = doctorProfile!.doctorID; } @override diff --git a/lib/screens/procedures/update-procedure.dart b/lib/screens/procedures/update-procedure.dart index a11ac875..8f90e1f5 100644 --- a/lib/screens/procedures/update-procedure.dart +++ b/lib/screens/procedures/update-procedure.dart @@ -86,7 +86,7 @@ class _UpdateProcedureWidgetState extends State { widget.remarksController.text = widget.remarks; } - List entityList = List(); + List entityList = []; dynamic selectedCategory; @override Widget build(BuildContext context) { @@ -357,7 +357,7 @@ class _UpdateProcedureWidgetState extends State { String categorieId}) async { UpdateProcedureRequestModel updateProcedureReqModel = new UpdateProcedureRequestModel(); - List controls = List(); + List controls = []; ProcedureDetail controlsProcedure = new ProcedureDetail(); updateProcedureReqModel.appointmentNo = patient.appointmentNo; diff --git a/lib/widgets/auth/method_type_card.dart b/lib/widgets/auth/method_type_card.dart index 9839d0ad..76b42d63 100644 --- a/lib/widgets/auth/method_type_card.dart +++ b/lib/widgets/auth/method_type_card.dart @@ -7,7 +7,7 @@ import 'package:hexcolor/hexcolor.dart'; // class MethodTypeCard extends StatelessWidget { // const MethodTypeCard({ -// Key key, +// Key ? key, // this.assetPath, // this.onTap, // this.label, this.height = 20, this.isSvg = true, @@ -71,7 +71,7 @@ import 'package:hexcolor/hexcolor.dart'; class MethodTypeCard extends StatelessWidget { const MethodTypeCard({ - Key key, + Key ? key, this.assetPath, this.onTap, this.label, diff --git a/lib/widgets/auth/verification_methods_list.dart b/lib/widgets/auth/verification_methods_list.dart index 97fbb42b..d9175a11 100644 --- a/lib/widgets/auth/verification_methods_list.dart +++ b/lib/widgets/auth/verification_methods_list.dart @@ -14,7 +14,7 @@ class VerificationMethodsList extends StatefulWidget { final AuthenticationViewModel authenticationViewModel; const VerificationMethodsList( - {Key key, + {Key ? key, this.authMethodType, this.authenticateUser, this.onShowMore, diff --git a/lib/widgets/charts/app_bar_chart.dart b/lib/widgets/charts/app_bar_chart.dart index aa532306..67c44c3b 100644 --- a/lib/widgets/charts/app_bar_chart.dart +++ b/lib/widgets/charts/app_bar_chart.dart @@ -3,7 +3,7 @@ import 'package:flutter/material.dart'; class AppBarChart extends StatelessWidget { const AppBarChart({ - Key key, + Key ? key, @required this.seriesList, }) : super(key: key); diff --git a/lib/widgets/charts/app_line_chart.dart b/lib/widgets/charts/app_line_chart.dart index 554b63fa..26e3c582 100644 --- a/lib/widgets/charts/app_line_chart.dart +++ b/lib/widgets/charts/app_line_chart.dart @@ -17,7 +17,7 @@ class AppLineChart extends StatelessWidget { final bool stacked; AppLineChart( - {Key key, + {Key ? key, @required this.seriesList, this.chartTitle, this.animate = true, diff --git a/lib/widgets/charts/app_time_series_chart.dart b/lib/widgets/charts/app_time_series_chart.dart index 670284a1..67ad3f0e 100644 --- a/lib/widgets/charts/app_time_series_chart.dart +++ b/lib/widgets/charts/app_time_series_chart.dart @@ -12,7 +12,7 @@ import 'package:flutter/material.dart'; /// [endDate] the end date class AppTimeSeriesChart extends StatelessWidget { AppTimeSeriesChart({ - Key key, + Key ? key, @required this.seriesList, this.chartName = '', this.startDate, diff --git a/lib/widgets/data_display/list/custom_Item.dart b/lib/widgets/data_display/list/custom_Item.dart index c11af999..76087761 100644 --- a/lib/widgets/data_display/list/custom_Item.dart +++ b/lib/widgets/data_display/list/custom_Item.dart @@ -27,7 +27,7 @@ class CustomItem extends StatelessWidget { final BoxDecoration decoration; CustomItem( - {Key key, + {Key ? key, this.startIcon, this.disabled: false, this.onTap, diff --git a/lib/widgets/data_display/list/flexible_container.dart b/lib/widgets/data_display/list/flexible_container.dart index a35fa279..91cc86ea 100644 --- a/lib/widgets/data_display/list/flexible_container.dart +++ b/lib/widgets/data_display/list/flexible_container.dart @@ -18,7 +18,7 @@ class FlexibleContainer extends StatelessWidget { final Widget child; FlexibleContainer({ - Key key, + Key ? key, this.widthFactor = 0.9, this.heightFactor = 1, this.padding, diff --git a/lib/widgets/doctor/lab_result_widget.dart b/lib/widgets/doctor/lab_result_widget.dart index c4343a4b..8c2d56ab 100644 --- a/lib/widgets/doctor/lab_result_widget.dart +++ b/lib/widgets/doctor/lab_result_widget.dart @@ -11,7 +11,7 @@ import 'package:doctor_app_flutter/util/translations_delegate_base.dart'; class LabResultWidget extends StatefulWidget { final List labResult; - LabResultWidget({Key key, this.labResult}); + LabResultWidget({Key ? key, this.labResult}); @override _LabResultWidgetState createState() => _LabResultWidgetState(); diff --git a/lib/widgets/doctor/my_referral_patient_widget.dart b/lib/widgets/doctor/my_referral_patient_widget.dart index 453cff30..e56887a0 100644 --- a/lib/widgets/doctor/my_referral_patient_widget.dart +++ b/lib/widgets/doctor/my_referral_patient_widget.dart @@ -19,7 +19,7 @@ class MyReferralPatientWidget extends StatefulWidget { final Function expandClick; MyReferralPatientWidget( - {Key key, + {Key ? key, this.myReferralPatientModel, this.model, this.isExpand, diff --git a/lib/widgets/doctor/my_schedule_widget.dart b/lib/widgets/doctor/my_schedule_widget.dart index 5c21f9ad..803f337e 100644 --- a/lib/widgets/doctor/my_schedule_widget.dart +++ b/lib/widgets/doctor/my_schedule_widget.dart @@ -13,7 +13,7 @@ import 'package:provider/provider.dart'; class MyScheduleWidget extends StatelessWidget { final ListDoctorWorkingHoursTable workingHoursTable; - MyScheduleWidget({Key key, this.workingHoursTable}); + MyScheduleWidget({Key ? key, this.workingHoursTable}); @override Widget build(BuildContext context) { diff --git a/lib/widgets/patients/clinic_list_dropdwon.dart b/lib/widgets/patients/clinic_list_dropdwon.dart index c903bd7b..f9795ee8 100644 --- a/lib/widgets/patients/clinic_list_dropdwon.dart +++ b/lib/widgets/patients/clinic_list_dropdwon.dart @@ -12,7 +12,7 @@ class ClinicList extends StatelessWidget { final int clinicId; final Function (int value) onClinicChange; - ClinicList({Key key, this.clinicId, this.onClinicChange}) : super(key: key); + ClinicList({Key ? key, this.clinicId, this.onClinicChange}) : super(key: key); @override Widget build(BuildContext context) { diff --git a/lib/widgets/patients/patient_card/PatientCard.dart b/lib/widgets/patients/patient_card/PatientCard.dart index 85069187..5df10470 100644 --- a/lib/widgets/patients/patient_card/PatientCard.dart +++ b/lib/widgets/patients/patient_card/PatientCard.dart @@ -576,7 +576,7 @@ class PatientCard extends StatelessWidget { class PatientStatus extends StatelessWidget { PatientStatus({ - Key key, + Key ? key, this.label, this.color, }) : super(key: key); diff --git a/lib/widgets/patients/patient_card/ShowTimer.dart b/lib/widgets/patients/patient_card/ShowTimer.dart index b769588b..fba1a52a 100644 --- a/lib/widgets/patients/patient_card/ShowTimer.dart +++ b/lib/widgets/patients/patient_card/ShowTimer.dart @@ -9,7 +9,7 @@ class ShowTimer extends StatefulWidget { const ShowTimer({ - Key key, this.patientInfo, + Key ? key, this.patientInfo, }) : super(key: key); @override diff --git a/lib/widgets/patients/patient_service_title.dart b/lib/widgets/patients/patient_service_title.dart index 08ce9293..9785319c 100644 --- a/lib/widgets/patients/patient_service_title.dart +++ b/lib/widgets/patients/patient_service_title.dart @@ -6,7 +6,7 @@ class ServiceTitle extends StatefulWidget { final String title; final String subTitle; - const ServiceTitle({Key key, this.title, this.subTitle}) : super(key: key); + const ServiceTitle({Key ? key, this.title, this.subTitle}) : super(key: key); @override _ServiceTitleState createState() => _ServiceTitleState(); diff --git a/lib/widgets/patients/profile/PatientProfileButton.dart b/lib/widgets/patients/profile/PatientProfileButton.dart index a3c4492f..bafd45c9 100644 --- a/lib/widgets/patients/profile/PatientProfileButton.dart +++ b/lib/widgets/patients/profile/PatientProfileButton.dart @@ -33,7 +33,7 @@ class PatientProfileButton extends StatelessWidget { final Color color; PatientProfileButton({ - Key key, + Key ? key, this.patient, this.patientType, this.arrivalType, diff --git a/lib/widgets/patients/profile/Profile_general_info_Widget.dart b/lib/widgets/patients/profile/Profile_general_info_Widget.dart index e0eb5b12..b6e32c4f 100644 --- a/lib/widgets/patients/profile/Profile_general_info_Widget.dart +++ b/lib/widgets/patients/profile/Profile_general_info_Widget.dart @@ -13,7 +13,7 @@ import '../../shared/rounded_container_widget.dart'; *@desc: Profile General Info Widget class */ class ProfileGeneralInfoWidget extends StatelessWidget { - ProfileGeneralInfoWidget({Key key, this.patient}) : super(key: key); + ProfileGeneralInfoWidget({Key ? key, this.patient}) : super(key: key); PatiantInformtion patient; diff --git a/lib/widgets/patients/profile/add-order/addNewOrder.dart b/lib/widgets/patients/profile/add-order/addNewOrder.dart index cc9223f6..1b9441dd 100644 --- a/lib/widgets/patients/profile/add-order/addNewOrder.dart +++ b/lib/widgets/patients/profile/add-order/addNewOrder.dart @@ -3,7 +3,7 @@ import 'package:flutter/material.dart'; class AddNewOrder extends StatelessWidget { const AddNewOrder({ - Key key, + Key ? key, this.onTap, this.label, }) : super(key: key); diff --git a/lib/widgets/patients/profile/large_avatar.dart b/lib/widgets/patients/profile/large_avatar.dart index 80f54e12..bc50c07b 100644 --- a/lib/widgets/patients/profile/large_avatar.dart +++ b/lib/widgets/patients/profile/large_avatar.dart @@ -5,7 +5,7 @@ import 'package:flutter/material.dart'; class LargeAvatar extends StatelessWidget { LargeAvatar( - {Key key, + {Key ? key, this.name, this.url, this.disableProfileView: false, diff --git a/lib/widgets/patients/profile/prescription_in_patinets_widget.dart b/lib/widgets/patients/profile/prescription_in_patinets_widget.dart index 52af839c..171ff4f5 100644 --- a/lib/widgets/patients/profile/prescription_in_patinets_widget.dart +++ b/lib/widgets/patients/profile/prescription_in_patinets_widget.dart @@ -15,7 +15,7 @@ class PrescriptionInPatientWidget extends StatelessWidget { final List prescriptionReportForInPatientList; PrescriptionInPatientWidget( - {Key key, this.prescriptionReportForInPatientList}); + {Key ? key, this.prescriptionReportForInPatientList}); @override Widget build(BuildContext context) { diff --git a/lib/widgets/patients/profile/prescription_out_patinets_widget.dart b/lib/widgets/patients/profile/prescription_out_patinets_widget.dart index 50afbdcf..920065d9 100644 --- a/lib/widgets/patients/profile/prescription_out_patinets_widget.dart +++ b/lib/widgets/patients/profile/prescription_out_patinets_widget.dart @@ -14,7 +14,7 @@ import 'large_avatar.dart'; class PrescriptionOutPatientWidget extends StatelessWidget { final List patientPrescriptionsList; - PrescriptionOutPatientWidget({Key key, this.patientPrescriptionsList}); + PrescriptionOutPatientWidget({Key ? key, this.patientPrescriptionsList}); @override Widget build(BuildContext context) { diff --git a/lib/widgets/patients/profile/profile-welcome-widget.dart b/lib/widgets/patients/profile/profile-welcome-widget.dart index 0a405d8d..fc859526 100644 --- a/lib/widgets/patients/profile/profile-welcome-widget.dart +++ b/lib/widgets/patients/profile/profile-welcome-widget.dart @@ -34,7 +34,7 @@ class ProfileWelcomeWidget extends StatelessWidget { child: ClipRRect( borderRadius: BorderRadius.circular(20), child: CachedNetworkImage( - imageUrl: authenticationViewModel.doctorProfile.doctorImageURL, + imageUrl: authenticationViewModel.doctorProfile!.doctorImageURL, fit: BoxFit.fill, width: 75, height: 75, diff --git a/lib/widgets/patients/profile/profile_medical_info_widget.dart b/lib/widgets/patients/profile/profile_medical_info_widget.dart index fec33a62..910e2e3a 100644 --- a/lib/widgets/patients/profile/profile_medical_info_widget.dart +++ b/lib/widgets/patients/profile/profile_medical_info_widget.dart @@ -16,7 +16,7 @@ class ProfileMedicalInfoWidget extends StatelessWidget { final bool isInpatient; ProfileMedicalInfoWidget( - {Key key, this.patient, this.patientType, this.arrivalType, this.from, this.to, this.isInpatient}); + {Key ? key, this.patient, this.patientType, this.arrivalType, this.from, this.to, this.isInpatient}); @override Widget build(BuildContext context) { 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 a7ab2412..35c08900 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 @@ -17,7 +17,7 @@ class ProfileMedicalInfoWidgetInPatient extends StatelessWidget { final bool isDischargedPatient; ProfileMedicalInfoWidgetInPatient( - {Key key, + {Key ? key, this.patient, this.patientType, this.arrivalType, 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 c6c2c464..9afa90b1 100644 --- a/lib/widgets/patients/profile/profile_medical_info_widget_search.dart +++ b/lib/widgets/patients/profile/profile_medical_info_widget_search.dart @@ -18,7 +18,7 @@ class ProfileMedicalInfoWidgetSearch extends StatelessWidget { final bool isDischargedPatient; ProfileMedicalInfoWidgetSearch( - {Key key, + {Key ? key, this.patient, this.patientType, this.arrivalType, diff --git a/lib/widgets/patients/vital_sign_details_wideget.dart b/lib/widgets/patients/vital_sign_details_wideget.dart index b8314b03..eeeb1cdc 100644 --- a/lib/widgets/patients/vital_sign_details_wideget.dart +++ b/lib/widgets/patients/vital_sign_details_wideget.dart @@ -12,7 +12,7 @@ class VitalSignDetailsWidget extends StatefulWidget { final String viewKey; VitalSignDetailsWidget( - {Key key, this.vitalList, this.title1, this.title2, this.viewKey}); + {Key ? key, this.vitalList, this.title1, this.title2, this.viewKey}); @override _VitalSignDetailsWidgetState createState() => _VitalSignDetailsWidgetState(); diff --git a/lib/widgets/shared/StarRating.dart b/lib/widgets/shared/StarRating.dart index f391e7bf..a65df00b 100644 --- a/lib/widgets/shared/StarRating.dart +++ b/lib/widgets/shared/StarRating.dart @@ -9,7 +9,7 @@ class StarRating extends StatelessWidget { final bool forceStars; StarRating( - {Key key, + {Key ? key, this.totalAverage: 0.0, this.size: 16.0, this.totalCount = 5, diff --git a/lib/widgets/shared/TextFields.dart b/lib/widgets/shared/TextFields.dart index 3674e144..07cbc52f 100644 --- a/lib/widgets/shared/TextFields.dart +++ b/lib/widgets/shared/TextFields.dart @@ -40,7 +40,7 @@ final _mobileFormatter = NumberTextInputFormatter(); class TextFields extends StatefulWidget { TextFields( - {Key key, + {Key ? key, this.type, this.hintText, this.suffixIcon, diff --git a/lib/widgets/shared/app_drawer_widget.dart b/lib/widgets/shared/app_drawer_widget.dart index 4444cf0a..7f6ced05 100644 --- a/lib/widgets/shared/app_drawer_widget.dart +++ b/lib/widgets/shared/app_drawer_widget.dart @@ -77,7 +77,7 @@ class _AppDrawerState extends State { onTap: () { // TODO: return it back when its needed // Navigator.of(context).pushNamed(PROFILE, arguments: { - // 'title': authProvider.doctorProfile.doctorName, + // 'title': authProvider.doctorProfile!.doctorName, // "doctorProfileall": authProvider.doctorProfile // }); }, @@ -90,7 +90,7 @@ class _AppDrawerState extends State { TranslationBase.of(context).dr + capitalizeOnlyFirstLater( authenticationViewModel - .doctorProfile.doctorName + .doctorProfile!.doctorName .replaceAll("DR.", "") .toLowerCase()), fontWeight: FontWeight.w700, diff --git a/lib/widgets/shared/app_loader_widget.dart b/lib/widgets/shared/app_loader_widget.dart index 4b6d753b..48ae1774 100644 --- a/lib/widgets/shared/app_loader_widget.dart +++ b/lib/widgets/shared/app_loader_widget.dart @@ -4,7 +4,7 @@ import 'package:progress_hud_v2/progress_hud.dart'; import 'loader/gif_loader_container.dart'; class AppLoaderWidget extends StatefulWidget { - AppLoaderWidget({Key key, this.title, this.containerColor}) : super(key: key); + AppLoaderWidget({Key ? key, this.title, this.containerColor}) : super(key: key); final String title; final Color containerColor; diff --git a/lib/widgets/shared/bottom_nav_bar.dart b/lib/widgets/shared/bottom_nav_bar.dart index dca59ee0..182dad4e 100644 --- a/lib/widgets/shared/bottom_nav_bar.dart +++ b/lib/widgets/shared/bottom_nav_bar.dart @@ -13,7 +13,7 @@ class BottomNavBar extends StatefulWidget { DashboardViewModel dashboardViewModel = DashboardViewModel(); - BottomNavBar({Key key, this.changeIndex, this.index}) : super(key: key); + BottomNavBar({Key ? key, this.changeIndex, this.index}) : super(key: key); @override _BottomNavBarState createState() => _BottomNavBarState(); diff --git a/lib/widgets/shared/buttons/secondary_button.dart b/lib/widgets/shared/buttons/secondary_button.dart index 48c65baf..e2dd72bd 100644 --- a/lib/widgets/shared/buttons/secondary_button.dart +++ b/lib/widgets/shared/buttons/secondary_button.dart @@ -15,7 +15,7 @@ import 'package:provider/provider.dart'; /// [noBorderRadius] remove border radius class SecondaryButton extends StatefulWidget { SecondaryButton( - {Key key, + {Key ? key, this.label = "", this.icon, this.iconOnly = false, diff --git a/lib/widgets/shared/charts/app_line_chart.dart b/lib/widgets/shared/charts/app_line_chart.dart index 422468d7..abb0cdc5 100644 --- a/lib/widgets/shared/charts/app_line_chart.dart +++ b/lib/widgets/shared/charts/app_line_chart.dart @@ -10,7 +10,7 @@ import 'package:flutter/material.dart'; */ class AppLineChart extends StatelessWidget { const AppLineChart({ - Key key, + Key ? key, @required this.seriesList, this.chartTitle, }) : super(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 f4bd354e..76fd56f9 100644 --- a/lib/widgets/shared/charts/app_time_series_chart.dart +++ b/lib/widgets/shared/charts/app_time_series_chart.dart @@ -14,7 +14,7 @@ import '../../../widgets/shared/rounded_container_widget.dart'; */ class AppTimeSeriesChart extends StatelessWidget { AppTimeSeriesChart( - {Key key, + {Key ? key, @required this.vitalList, @required this.viewKey, this.chartName = ''}); diff --git a/lib/widgets/shared/dialogs/ShowImageDialog.dart b/lib/widgets/shared/dialogs/ShowImageDialog.dart index 302366b7..bb418d28 100644 --- a/lib/widgets/shared/dialogs/ShowImageDialog.dart +++ b/lib/widgets/shared/dialogs/ShowImageDialog.dart @@ -4,7 +4,7 @@ import 'package:flutter/material.dart'; class ShowImageDialog extends StatelessWidget { final String imageUrl; - const ShowImageDialog({Key key, this.imageUrl}) : super(key: key); + const ShowImageDialog({Key ? key, this.imageUrl}) : super(key: key); @override Widget build(BuildContext context) { return SimpleDialog( diff --git a/lib/widgets/shared/dialogs/dailog-list-select.dart b/lib/widgets/shared/dialogs/dailog-list-select.dart index dfaf9143..4fabbded 100644 --- a/lib/widgets/shared/dialogs/dailog-list-select.dart +++ b/lib/widgets/shared/dialogs/dailog-list-select.dart @@ -29,7 +29,7 @@ class ListSelectDialog extends StatefulWidget { } class _ListSelectDialogState extends State { - List items = List(); + List items = []; @override void initState() { @@ -122,10 +122,10 @@ class _ListSelectDialogState extends State { } void filterSearchResults(String query) { - List dummySearchList = List(); + List dummySearchList = []; dummySearchList.addAll(widget.list); if (query.isNotEmpty) { - List dummyListData = List(); + List dummyListData = []; dummySearchList.forEach((item) { if ("${item[widget.attributeName].toString()}".toLowerCase().contains(query.toLowerCase())) { dummyListData.add(item); diff --git a/lib/widgets/shared/divider_with_spaces_around.dart b/lib/widgets/shared/divider_with_spaces_around.dart index b43557cb..a126d128 100644 --- a/lib/widgets/shared/divider_with_spaces_around.dart +++ b/lib/widgets/shared/divider_with_spaces_around.dart @@ -2,7 +2,7 @@ import 'package:flutter/material.dart'; class DividerWithSpacesAround extends StatelessWidget { DividerWithSpacesAround({ - Key key, this.height = 0, + Key ? key, this.height = 0, }); final double height ; diff --git a/lib/widgets/shared/dr_app_circular_progress_Indeicator.dart b/lib/widgets/shared/dr_app_circular_progress_Indeicator.dart index 2c476ec8..4dbd7d79 100644 --- a/lib/widgets/shared/dr_app_circular_progress_Indeicator.dart +++ b/lib/widgets/shared/dr_app_circular_progress_Indeicator.dart @@ -1,7 +1,7 @@ import 'package:flutter/material.dart'; class DrAppCircularProgressIndeicator extends StatelessWidget { const DrAppCircularProgressIndeicator({ - Key key, + Key ? key, }) : super(key: key); @override diff --git a/lib/widgets/shared/errors/dr_app_embedded_error.dart b/lib/widgets/shared/errors/dr_app_embedded_error.dart index de9fd698..f97c1e93 100644 --- a/lib/widgets/shared/errors/dr_app_embedded_error.dart +++ b/lib/widgets/shared/errors/dr_app_embedded_error.dart @@ -11,7 +11,7 @@ import '../app_texts_widget.dart'; */ class DrAppEmbeddedError extends StatelessWidget { const DrAppEmbeddedError({ - Key key, + Key ? key, @required this.error, }) : super(key: key); diff --git a/lib/widgets/shared/errors/error_message.dart b/lib/widgets/shared/errors/error_message.dart index 2930ae84..2a58518e 100644 --- a/lib/widgets/shared/errors/error_message.dart +++ b/lib/widgets/shared/errors/error_message.dart @@ -5,7 +5,7 @@ import '../app_texts_widget.dart'; class ErrorMessage extends StatelessWidget { const ErrorMessage({ - Key key, + Key ? key, @required this.error, }) : super(key: key); diff --git a/lib/widgets/shared/master_key_checkbox_search_widget.dart b/lib/widgets/shared/master_key_checkbox_search_widget.dart index c61913a4..dbba1da2 100644 --- a/lib/widgets/shared/master_key_checkbox_search_widget.dart +++ b/lib/widgets/shared/master_key_checkbox_search_widget.dart @@ -23,7 +23,7 @@ class MasterKeyCheckboxSearchWidget extends StatefulWidget { final String hintSearchText; MasterKeyCheckboxSearchWidget( - {Key key, + {Key ? key, this.model, this.addSelectedHistories, this.removeHistory, @@ -41,7 +41,7 @@ class MasterKeyCheckboxSearchWidget extends StatefulWidget { class _MasterKeyCheckboxSearchWidgetState extends State { - List items = List(); + List items = []; TextEditingController filteredSearchController = TextEditingController(); @@ -162,10 +162,10 @@ class _MasterKeyCheckboxSearchWidgetState } void filterSearchResults(String query) { - List dummySearchList = List(); + List dummySearchList = []; dummySearchList.addAll(widget.masterList); if (query.isNotEmpty) { - List dummyListData = List(); + List dummyListData = []; dummySearchList.forEach((item) { if (item.nameAr.toLowerCase().contains(query.toLowerCase()) || item.nameEn.toLowerCase().contains(query.toLowerCase())) { diff --git a/lib/widgets/shared/network_base_view.dart b/lib/widgets/shared/network_base_view.dart index 32232628..1e7b00fd 100644 --- a/lib/widgets/shared/network_base_view.dart +++ b/lib/widgets/shared/network_base_view.dart @@ -10,7 +10,7 @@ class NetworkBaseView extends StatelessWidget { final BaseViewModel baseViewModel; final Widget child; - NetworkBaseView({Key key, this.baseViewModel, this.child}); + NetworkBaseView({Key ? key, this.baseViewModel, this.child}); @override Widget build(BuildContext context) { diff --git a/lib/widgets/shared/text_fields/app_text_field_custom_serach.dart b/lib/widgets/shared/text_fields/app_text_field_custom_serach.dart index 9d82bdad..cb73a143 100644 --- a/lib/widgets/shared/text_fields/app_text_field_custom_serach.dart +++ b/lib/widgets/shared/text_fields/app_text_field_custom_serach.dart @@ -9,7 +9,7 @@ import 'app-textfield-custom.dart'; class AppTextFieldCustomSearch extends StatelessWidget { const AppTextFieldCustomSearch({ - Key key, + Key ? key, this.onChangeFun, this.positionedChild, this.marginTop, diff --git a/lib/widgets/shared/text_fields/auto_complete_text_field.dart b/lib/widgets/shared/text_fields/auto_complete_text_field.dart index 3b563f3f..386ec459 100644 --- a/lib/widgets/shared/text_fields/auto_complete_text_field.dart +++ b/lib/widgets/shared/text_fields/auto_complete_text_field.dart @@ -8,7 +8,7 @@ class CustomAutoCompleteTextField extends StatelessWidget { final Widget child; const CustomAutoCompleteTextField({ - Key key, + Key ? key, this.isShowError, this.child, }) : super(key: key); diff --git a/lib/widgets/shared/text_fields/country_textfield_custom.dart b/lib/widgets/shared/text_fields/country_textfield_custom.dart index baed4995..603bcc26 100644 --- a/lib/widgets/shared/text_fields/country_textfield_custom.dart +++ b/lib/widgets/shared/text_fields/country_textfield_custom.dart @@ -16,7 +16,7 @@ class CountryTextField extends StatefulWidget { final Function(dynamic) okFunction; CountryTextField( - {Key key, + {Key ? key, @required this.element, @required this.elementError, this.width, diff --git a/lib/widgets/shared/text_fields/new_text_Field.dart b/lib/widgets/shared/text_fields/new_text_Field.dart index 6392efe9..3319719a 100644 --- a/lib/widgets/shared/text_fields/new_text_Field.dart +++ b/lib/widgets/shared/text_fields/new_text_Field.dart @@ -41,7 +41,7 @@ final _mobileFormatter = NumberTextInputFormatter(); class NewTextFields extends StatefulWidget { NewTextFields( - {Key key, + {Key ? key, this.type, this.hintText, this.suffixIcon, diff --git a/lib/widgets/shared/text_fields/text_field_error.dart b/lib/widgets/shared/text_fields/text_field_error.dart index 9c781db0..95c6ff9a 100644 --- a/lib/widgets/shared/text_fields/text_field_error.dart +++ b/lib/widgets/shared/text_fields/text_field_error.dart @@ -6,7 +6,7 @@ import '../app_texts_widget.dart'; class TextFieldsError extends StatelessWidget { const TextFieldsError({ - Key key, + Key ? key, @required this.error, }) : super(key: key); diff --git a/lib/widgets/shared/user-guid/CusomRow.dart b/lib/widgets/shared/user-guid/CusomRow.dart index 21875e4d..9ab5d8ae 100644 --- a/lib/widgets/shared/user-guid/CusomRow.dart +++ b/lib/widgets/shared/user-guid/CusomRow.dart @@ -5,7 +5,7 @@ import '../app_texts_widget.dart'; class CustomRow extends StatelessWidget { const CustomRow({ - Key key, + Key ? key, this.label, this.value, this.labelSize, diff --git a/lib/widgets/shared/user-guid/app_showcase.dart b/lib/widgets/shared/user-guid/app_showcase.dart index 38625279..377172c8 100644 --- a/lib/widgets/shared/user-guid/app_showcase.dart +++ b/lib/widgets/shared/user-guid/app_showcase.dart @@ -313,7 +313,7 @@ class _TargetWidget extends StatelessWidget { final ShapeBorder shapeBorder; _TargetWidget({ - Key key, + Key ? key, @required this.offset, this.size, this.widthAnimation, diff --git a/lib/widgets/shared/user-guid/custom_validation_error.dart b/lib/widgets/shared/user-guid/custom_validation_error.dart index fd1f2125..abfac6c4 100644 --- a/lib/widgets/shared/user-guid/custom_validation_error.dart +++ b/lib/widgets/shared/user-guid/custom_validation_error.dart @@ -7,7 +7,7 @@ import 'package:flutter/material.dart'; class CustomValidationError extends StatelessWidget { String error; CustomValidationError({ - Key key, this.error, + Key ? key, this.error, }) : super(key: key); @override