some fixes to go flutter 2

merge-requests/888/head
Elham Rababh 3 years ago
parent 47437c8637
commit 7f9969b6cf

@ -252,7 +252,7 @@ class LiveCarePatientViewModel extends BaseViewModel {
setState(ViewState.BusyLocal); setState(ViewState.BusyLocal);
await _liveCarePatientServices.addPatientToDoctorList(vcID: vcID); await _liveCarePatientServices.addPatientToDoctorList(vcID: vcID);
if (_liveCarePatientServices.hasError) { if (_liveCarePatientServices.hasError) {
error = _liveCarePatientServices.error; error = _liveCarePatientServices.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);
@ -264,7 +264,7 @@ class LiveCarePatientViewModel extends BaseViewModel {
setState(ViewState.BusyLocal); setState(ViewState.BusyLocal);
await _liveCarePatientServices.removePatientFromDoctorList(vcID: vcID); await _liveCarePatientServices.removePatientFromDoctorList(vcID: vcID);
if (_liveCarePatientServices.hasError) { if (_liveCarePatientServices.hasError) {
error = _liveCarePatientServices.error; error = _liveCarePatientServices.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);

@ -59,7 +59,7 @@ class PatientMedicalReportViewModel extends BaseViewModel {
setState(ViewState.Busy); setState(ViewState.Busy);
await _service.addMedicalReport(patient, htmlText); await _service.addMedicalReport(patient, htmlText);
if (_service.hasError) { if (_service.hasError) {
error = _service.error; error = _service.error!;
await getMedicalReportList(patient); await getMedicalReportList(patient);
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
@ -72,7 +72,7 @@ class PatientMedicalReportViewModel extends BaseViewModel {
setState(ViewState.Busy); setState(ViewState.Busy);
await _service.updateMedicalReport(patient, htmlText, limitNumber, invoiceNumber); await _service.updateMedicalReport(patient, htmlText, limitNumber, invoiceNumber);
if (_service.hasError) { if (_service.hasError) {
error = _service.error; error = _service.error!;
await getMedicalReportList(patient); await getMedicalReportList(patient);
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else

@ -30,7 +30,7 @@ class PatientRegistrationViewModel extends BaseViewModel {
await _patientRegistrationService await _patientRegistrationService
.checkPatientForRegistration(registrationModel); .checkPatientForRegistration(registrationModel);
if (_patientRegistrationService.hasError) { if (_patientRegistrationService.hasError) {
error = _patientRegistrationService.error; error = _patientRegistrationService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);
@ -135,7 +135,7 @@ class PatientRegistrationViewModel extends BaseViewModel {
// await _patientRegistrationService. // await _patientRegistrationService.
// getPatientInfo(getPatientInfoRequestModel); // getPatientInfo(getPatientInfoRequestModel);
// if (_patientRegistrationService.hasError) { // if (_patientRegistrationService.hasError) {
// error = _patientRegistrationService.error; // error = _patientRegistrationService.error!;
// setState(ViewState.ErrorLocal); // setState(ViewState.ErrorLocal);
// } else // } else
setState(ViewState.Idle); setState(ViewState.Idle);
@ -155,7 +155,7 @@ class PatientRegistrationViewModel extends BaseViewModel {
model: this, model: this,
checkPatientForRegistrationModel: checkPatientForRegistrationModel); checkPatientForRegistrationModel: checkPatientForRegistrationModel);
if (_patientRegistrationService.hasError) { if (_patientRegistrationService.hasError) {
error = _patientRegistrationService.error; error = _patientRegistrationService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);
@ -191,7 +191,7 @@ class PatientRegistrationViewModel extends BaseViewModel {
setState(ViewState.BusyLocal); setState(ViewState.BusyLocal);
await _patientRegistrationService.checkActivationCode(model); await _patientRegistrationService.checkActivationCode(model);
if (_patientRegistrationService.hasError) { if (_patientRegistrationService.hasError) {
error = _patientRegistrationService.error; error = _patientRegistrationService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);
@ -201,7 +201,7 @@ class PatientRegistrationViewModel extends BaseViewModel {
setState(ViewState.BusyLocal); setState(ViewState.BusyLocal);
await _patientRegistrationService.registrationPatient(registrationModel); await _patientRegistrationService.registrationPatient(registrationModel);
if (_patientRegistrationService.hasError) { if (_patientRegistrationService.hasError) {
error = _patientRegistrationService.error; error = _patientRegistrationService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);

@ -354,7 +354,7 @@ class SOAPViewModel extends BaseViewModel {
patientTypeID: 1); patientTypeID: 1);
await _SOAPService.getEpisodeForInpatient(getEpisodeForInpatientReqModel); await _SOAPService.getEpisodeForInpatient(getEpisodeForInpatientReqModel);
if (_SOAPService.hasError) { if (_SOAPService.hasError) {
error = _SOAPService.error; error = _SOAPService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
patient.episodeNo = _SOAPService.episodeID; patient.episodeNo = _SOAPService.episodeID;
@ -584,7 +584,7 @@ class SOAPViewModel extends BaseViewModel {
final results = await Future.wait(services ?? []); final results = await Future.wait(services ?? []);
if (_SOAPService.hasError) { if (_SOAPService.hasError) {
error = _SOAPService.error; error = _SOAPService.error!;
setState(ViewState.Error); setState(ViewState.Error);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);
@ -644,7 +644,7 @@ class SOAPViewModel extends BaseViewModel {
final results = await Future.wait(services ?? []); final results = await Future.wait(services ?? []);
if (_SOAPService.hasError || _prescriptionService.hasError) { if (_SOAPService.hasError || _prescriptionService.hasError) {
error = _SOAPService.error + _prescriptionService.error; error = _SOAPService.error + _prescriptionService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);
@ -684,7 +684,7 @@ class SOAPViewModel extends BaseViewModel {
final results = await Future.wait(services ?? []); final results = await Future.wait(services ?? []);
if (allowSetState) { if (allowSetState) {
if (_SOAPService.hasError) { if (_SOAPService.hasError) {
error = _SOAPService.error; error = _SOAPService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);
@ -708,7 +708,7 @@ class SOAPViewModel extends BaseViewModel {
} }
if (_SOAPService.hasError) { if (_SOAPService.hasError) {
error = _SOAPService.error; error = _SOAPService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);
@ -766,7 +766,7 @@ class SOAPViewModel extends BaseViewModel {
final results = await Future.wait(services); final results = await Future.wait(services);
if (_SOAPService.hasError) { if (_SOAPService.hasError) {
error = _SOAPService.error; error = _SOAPService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);

@ -332,7 +332,7 @@ class AuthenticationViewModel extends BaseViewModel {
await _authService.selectDeviceImei(localToken); await _authService.selectDeviceImei(localToken);
if (_authService.hasError) { if (_authService.hasError) {
error = _authService.error; error = _authService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
if (_authService.dashboardItemsList.length > 0) { if (_authService.dashboardItemsList.length > 0) {

@ -42,7 +42,7 @@ List<GetSpecialClinicalCareListResponseModel> get specialClinicalCareList =>
]); ]);
if (_dashboardService.hasError) { if (_dashboardService.hasError) {
error = _dashboardService.error; error = _dashboardService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);
@ -91,7 +91,7 @@ List<GetSpecialClinicalCareListResponseModel> get specialClinicalCareList =>
); );
await authProvider.getDoctorProfileBasedOnClinic(clinicModel); await authProvider.getDoctorProfileBasedOnClinic(clinicModel);
if (authProvider.state == ViewState.ErrorLocal) { if (authProvider.state == ViewState.ErrorLocal) {
error = authProvider.error; error = authProvider.error!;
} }
} }
@ -118,7 +118,7 @@ List<GetSpecialClinicalCareListResponseModel> get specialClinicalCareList =>
await getDoctorProfile(); await getDoctorProfile();
await _doctorReplyService.getNotRepliedCount(); await _doctorReplyService.getNotRepliedCount();
if (_doctorReplyService.hasError) { if (_doctorReplyService.hasError) {
error = _doctorReplyService.error; error = _doctorReplyService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
notifyListeners(); notifyListeners();

@ -163,7 +163,7 @@ class LabsViewModel extends BaseViewModel {
await _labsService.getPatientLabOrdersResultHistoryByDescription( await _labsService.getPatientLabOrdersResultHistoryByDescription(
patientLabOrder: patientLabOrder, procedureDescription: procedureDescription, patient: patient); patientLabOrder: patientLabOrder, procedureDescription: procedureDescription, patient: patient);
if (_labsService.hasError) { if (_labsService.hasError) {
error = _labsService.error; error = _labsService.error!;
setState(ViewState.Error); setState(ViewState.Error);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);
@ -182,7 +182,7 @@ class LabsViewModel extends BaseViewModel {
setState(ViewState.Busy); setState(ViewState.Busy);
await _labsService.getAllSpecialLabResult(mrn: patientId); await _labsService.getAllSpecialLabResult(mrn: patientId);
if (_labsService.hasError) { if (_labsService.hasError) {
error = _labsService.error; error = _labsService.error!;
setState(ViewState.Error); setState(ViewState.Error);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);

@ -323,7 +323,7 @@ class PatientViewModel extends BaseViewModel {
await _patientService.getNursingProgressNote(requestModel); await _patientService.getNursingProgressNote(requestModel);
if (_patientService.hasError) { if (_patientService.hasError) {
error = _patientService.error; error = _patientService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);
@ -337,7 +337,7 @@ class PatientViewModel extends BaseViewModel {
await _patientService.getDiagnosisForInPatient(requestModel); await _patientService.getDiagnosisForInPatient(requestModel);
if (_patientService.hasError) { if (_patientService.hasError) {
error = _patientService.error; error = _patientService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);
@ -362,7 +362,7 @@ class PatientViewModel extends BaseViewModel {
setupID: "010266"); setupID: "010266");
await _patientService.getDiabeticChartValues(requestModel); await _patientService.getDiabeticChartValues(requestModel);
if (_patientService.hasError) { if (_patientService.hasError) {
error = _patientService.error; error = _patientService.error!;
if (isLocalBusy) if (isLocalBusy)
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
else else

@ -21,7 +21,7 @@ class PendingOrdersViewModel extends BaseViewModel {
await _pendingOrderService.getPendingOrders( await _pendingOrderService.getPendingOrders(
patientId: patientId, admissionNo: admissionNo); patientId: patientId, admissionNo: admissionNo);
if (_pendingOrderService.hasError) { if (_pendingOrderService.hasError) {
error = _pendingOrderService.error; error = _pendingOrderService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);
@ -34,7 +34,7 @@ class PendingOrdersViewModel extends BaseViewModel {
await _pendingOrderService.getAdmissionOrders( await _pendingOrderService.getAdmissionOrders(
patientId: patientId, admissionNo: admissionNo); patientId: patientId, admissionNo: admissionNo);
if (_pendingOrderService.hasError) { if (_pendingOrderService.hasError) {
error = _pendingOrderService.error; error = _pendingOrderService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);

@ -256,7 +256,7 @@ class PrescriptionViewModel extends BaseViewModel {
setState(ViewState.Busy); setState(ViewState.Busy);
await _prescriptionsService.getMedicationForInPatient(patient); await _prescriptionsService.getMedicationForInPatient(patient);
if (_prescriptionsService.hasError) { if (_prescriptionsService.hasError) {
error = _prescriptionsService.error; error = _prescriptionsService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);

@ -132,7 +132,7 @@ class PrescriptionsViewModel extends BaseViewModel {
getMedicationForInPatient(PatiantInformtion patient) async { getMedicationForInPatient(PatiantInformtion patient) async {
await _prescriptionsService.getMedicationForInPatient(patient); await _prescriptionsService.getMedicationForInPatient(patient);
if (_prescriptionsService.hasError) { if (_prescriptionsService.hasError) {
error = _prescriptionsService.error; error = _prescriptionsService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);

@ -21,7 +21,7 @@ class DischargeSummaryViewModel extends BaseViewModel {
setState(ViewState.Busy); setState(ViewState.Busy);
await _dischargeSummaryService.getPendingDischargeSummary(getDischargeSummaryReqModel: getDischargeSummaryReqModel); await _dischargeSummaryService.getPendingDischargeSummary(getDischargeSummaryReqModel: getDischargeSummaryReqModel);
if (_dischargeSummaryService.hasError) { if (_dischargeSummaryService.hasError) {
error = _dischargeSummaryService.error; error = _dischargeSummaryService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);

@ -23,7 +23,7 @@ class OperationReportViewModel extends BaseViewModel {
setState(ViewState.Busy); setState(ViewState.Busy);
await _operationReportService.getReservations(patientId: patientId); await _operationReportService.getReservations(patientId: patientId);
if (_operationReportService.hasError) { if (_operationReportService.hasError) {
error = _operationReportService.error; error = _operationReportService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);
@ -36,7 +36,7 @@ class OperationReportViewModel extends BaseViewModel {
GetOperationDetailsRequestModel getOperationReportRequestModel = GetOperationDetailsRequestModel(reservationNo:reservation.oTReservationID, patientID: reservation.patientID, setupID: "010266" ); GetOperationDetailsRequestModel getOperationReportRequestModel = GetOperationDetailsRequestModel(reservationNo:reservation.oTReservationID, patientID: reservation.patientID, setupID: "010266" );
await _operationReportService.getOperationReportDetails(getOperationReportRequestModel:getOperationReportRequestModel); await _operationReportService.getOperationReportDetails(getOperationReportRequestModel:getOperationReportRequestModel);
if (_operationReportService.hasError) { if (_operationReportService.hasError) {
error = _operationReportService.error; error = _operationReportService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else { } else {
setState(ViewState.Idle); setState(ViewState.Idle);
@ -51,7 +51,7 @@ class OperationReportViewModel extends BaseViewModel {
setState(ViewState.BusyLocal); setState(ViewState.BusyLocal);
await _operationReportService.updateOperationReport(createUpdateOperationReport); await _operationReportService.updateOperationReport(createUpdateOperationReport);
if (_operationReportService.hasError) { if (_operationReportService.hasError) {
error = _operationReportService.error; error = _operationReportService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);

@ -98,7 +98,7 @@ class SickLeaveViewModel extends BaseViewModel {
final results = await Future.wait(services); final results = await Future.wait(services);
if (_sickLeaveService.hasError) { if (_sickLeaveService.hasError) {
error = _sickLeaveService.error; error = _sickLeaveService.error!;
// if (isLocalBusy) // if (isLocalBusy)
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
// else // else
@ -112,7 +112,7 @@ class SickLeaveViewModel extends BaseViewModel {
setState(ViewState.Busy); setState(ViewState.Busy);
await _sickLeaveService.getSickLeaveDoctor(patientMRN); await _sickLeaveService.getSickLeaveDoctor(patientMRN);
if (_sickLeaveService.hasError) { if (_sickLeaveService.hasError) {
error = _sickLeaveService.error; error = _sickLeaveService.error!;
setState(ViewState.ErrorLocal); setState(ViewState.ErrorLocal);
} else } else
setState(ViewState.Idle); setState(ViewState.Idle);

@ -13,7 +13,7 @@ class ProfileMedicalInfoWidgetSearch extends StatefulWidget {
final PatiantInformtion patient; final PatiantInformtion patient;
final String patientType; final String patientType;
final String? arrivalType; final String? arrivalType;
final bool? isInpatient; final bool isInpatient;
final bool? isDischargedPatient; final bool? isDischargedPatient;
ProfileMedicalInfoWidgetSearch( ProfileMedicalInfoWidgetSearch(
@ -23,7 +23,7 @@ class ProfileMedicalInfoWidgetSearch extends StatefulWidget {
this.arrivalType, this.arrivalType,
required this.from, required this.from,
required this.to, required this.to,
this.isInpatient, this.isInpatient = false,
this.isDischargedPatient}); this.isDischargedPatient});
@override @override
@ -62,22 +62,21 @@ class _ProfileMedicalInfoWidgetSearchState extends State<ProfileMedicalInfoWidge
crossAxisCount: 3, crossAxisCount: 3,
children: [ children: [
PatientProfileButton( PatientProfileButton(
key: key, patient: widget.patient,
patient: patient, patientType: widget.patientType,
patientType: patientType, arrivalType: widget.arrivalType??"",
arrivalType: arrivalType, from: widget.from,
from: from, to: widget.to,
to: to, nameLine1: TranslationBase.of(context).vital??'',
nameLine1: TranslationBase.of(context).vital, nameLine2: TranslationBase.of(context).signs??'',
nameLine2: TranslationBase.of(context).signs,
route: VITAL_SIGN_DETAILS, route: VITAL_SIGN_DETAILS,
icon: 'patient/vital_signs.png'), icon: 'patient/vital_signs.png'),
// if (selectedPatientType != 7) // if (selectedPatientType != 7)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: HEALTH_SUMMARY, route: HEALTH_SUMMARY,
nameLine1: nameLine1:
"Health", //TranslationBase.of(context).medicalReport, "Health", //TranslationBase.of(context).medicalReport,
@ -85,128 +84,128 @@ class _ProfileMedicalInfoWidgetSearchState extends State<ProfileMedicalInfoWidge
"Summary", //TranslationBase.of(context).summaryReport, "Summary", //TranslationBase.of(context).summaryReport,
icon: 'patient/health_summary.png'), icon: 'patient/health_summary.png'),
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: LAB_RESULT, route: LAB_RESULT,
nameLine1: TranslationBase.of(context).lab, nameLine1: TranslationBase.of(context).lab??'',
nameLine2: TranslationBase.of(context).result, nameLine2: TranslationBase.of(context).result??'',
icon: 'patient/lab_results.png'), icon: 'patient/lab_results.png'),
// if (int.parse(patientType) == 7 || int.parse(patientType) == 6) // if (int.parse(patientType) == 7 || int.parse(patientType) == 6)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
isInPatient: isInpatient, isInPatient: widget.isInpatient,
route: RADIOLOGY_PATIENT, route: RADIOLOGY_PATIENT,
nameLine1: TranslationBase.of(context).radiology, nameLine1: TranslationBase.of(context).radiology??'',
nameLine2: TranslationBase.of(context).service, nameLine2: TranslationBase.of(context).service??'',
icon: 'patient/health_summary.png'), icon: 'patient/health_summary.png'),
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: PATIENT_ECG, route: PATIENT_ECG,
nameLine1: TranslationBase.of(context).patient, nameLine1: TranslationBase.of(context).patient??'',
nameLine2: "ECG", nameLine2: "ECG",
icon: 'patient/patient_sick_leave.png'), icon: 'patient/patient_sick_leave.png'),
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: ORDER_PRESCRIPTION_NEW, route: ORDER_PRESCRIPTION_NEW,
nameLine1: TranslationBase.of(context).orders, nameLine1: TranslationBase.of(context).orders??'',
nameLine2: TranslationBase.of(context).prescription, nameLine2: TranslationBase.of(context).prescription??'',
icon: 'patient/order_prescription.png'), icon: 'patient/order_prescription.png'),
// if (int.parse(patientType) == 7 || int.parse(patientType) == 6) // if (int.parse(patientType) == 7 || int.parse(patientType) == 6)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: ORDER_PROCEDURE, route: ORDER_PROCEDURE,
nameLine1: TranslationBase.of(context).orders, nameLine1: TranslationBase.of(context).orders??'',
nameLine2: TranslationBase.of(context).procedures, nameLine2: TranslationBase.of(context).procedures??'',
icon: 'patient/Order_Procedures.png'), icon: 'patient/Order_Procedures.png'),
//if (int.parse(patientType) == 7 || int.parse(patientType) == 6) //if (int.parse(patientType) == 7 || int.parse(patientType) == 6)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: PATIENT_INSURANCE_APPROVALS_NEW, route: PATIENT_INSURANCE_APPROVALS_NEW,
nameLine1: TranslationBase.of(context).insurance, nameLine1: TranslationBase.of(context).insurance??'',
nameLine2: TranslationBase.of(context).service, nameLine2: TranslationBase.of(context).service??'',
icon: 'patient/vital_signs.png'), icon: 'patient/vital_signs.png'),
// if (int.parse(patientType) == 7 || int.parse(patientType) == 6) // if (int.parse(patientType) == 7 || int.parse(patientType) == 6)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: ADD_SICKLEAVE, route: ADD_SICKLEAVE,
nameLine1: TranslationBase.of(context).patientSick, nameLine1: TranslationBase.of(context).patientSick??'',
nameLine2: TranslationBase.of(context).leave, nameLine2: TranslationBase.of(context).leave??'',
icon: 'patient/patient_sick_leave.png'), icon: 'patient/patient_sick_leave.png'),
if (patient.appointmentNo != null && if (widget.patient.appointmentNo != null &&
patient.appointmentNo != 0) widget.patient.appointmentNo != 0)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: PATIENT_UCAF_REQUEST, route: PATIENT_UCAF_REQUEST,
isDisable: isDisable:
patient.patientStatusType != 43 ? true : false, widget.patient.patientStatusType != 43 ? true : false,
nameLine1: TranslationBase.of(context).patient, nameLine1: TranslationBase.of(context).patient??'',
nameLine2: TranslationBase.of(context).ucaf, nameLine2: TranslationBase.of(context).ucaf??'',
icon: 'patient/ucaf.png'), icon: 'patient/ucaf.png'),
if (patient.appointmentNo != null && if (widget.patient.appointmentNo != null &&
patient.appointmentNo != 0) widget.patient.appointmentNo != 0)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: REFER_PATIENT_TO_DOCTOR, route: REFER_PATIENT_TO_DOCTOR,
isDisable: isDisable:
patient.patientStatusType != 43 ? true : false, widget.patient.patientStatusType != 43 ? true : false,
nameLine1: TranslationBase.of(context).referral, nameLine1: TranslationBase.of(context).referral??'',
nameLine2: TranslationBase.of(context).patient, nameLine2: TranslationBase.of(context).patient??'',
icon: 'patient/refer_patient.png'), icon: 'patient/refer_patient.png'),
if (patient.appointmentNo != null && if (widget.patient.appointmentNo != null &&
patient.appointmentNo != 0) widget.patient.appointmentNo != 0)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: PATIENT_ADMISSION_REQUEST, route: PATIENT_ADMISSION_REQUEST,
isDisable: isDisable:
patient.patientStatusType != 43 ? true : false, widget.patient.patientStatusType != 43 ? true : false,
nameLine1: TranslationBase.of(context).admission, nameLine1: TranslationBase.of(context).admission??'',
nameLine2: TranslationBase.of(context).request, nameLine2: TranslationBase.of(context).request??'',
icon: 'patient/admission_req.png'), icon: 'patient/admission_req.png'),
if (isInpatient) if (widget.isInpatient)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: PROGRESS_NOTE, route: PROGRESS_NOTE,
nameLine1: TranslationBase.of(context).progress, nameLine1: TranslationBase.of(context).progress??'',
nameLine2: TranslationBase.of(context).note, nameLine2: TranslationBase.of(context).note??'',
icon: 'patient/Progress_notes.png'), icon: 'patient/Progress_notes.png'),
if (isInpatient) if (widget.isInpatient)
PatientProfileButton( PatientProfileButton(
key: key,
patient: patient, patient: widget.patient,
patientType: patientType, patientType: widget.patientType,
arrivalType: arrivalType, arrivalType: widget.arrivalType??"",
route: ORDER_NOTE, route: ORDER_NOTE,
nameLine1: "Order", //"Text", nameLine1: "Order", //"Text",
nameLine2: "Sheet", nameLine2: "Sheet",

Loading…
Cancel
Save