ER Online CheckIn & InPatient CR implemented

merge-update-with-lab-changes
haroon amjad 1 year ago
parent 42dbe066fd
commit 6a555ace41

@ -1964,6 +1964,12 @@ const Map localizedValues = {
"admissionReqNo": {"en": "Admission Request No", "ar": "رقم طلب القبول:"},
"dischargeDate": {"en": "Discharge Date", "ar": "تاريخ التفريغ"},
"selectAdmissionText": {"en": "Please select one of the admissions from below to view medical reports:", "ar": "يرجى تحديد أحد حالات القبول من الأسفل لعرض التقارير الطبية:"},
"onlyAdmitted": {"en": "This service is only available for admitted patients", "ar": "هذه الخدمة متاحة فقط للمرضى المقبولين"},
"assistYou": {"en": "How we may assist you?", "ar": "كيف يمكننا مساعدتك؟"},
"receive": {"en": "Receive", "ar": "تجهيز"},
"PRO": {"en": "PRO", "ar": "علاقات المرضى"},
"patientRelationOffice": {"en": "Patient Relation Office", "ar": "علاقات المرضى"},
"roomNo": {"en": "Room No.", "ar": "رقم الغرفة"},
"invalidEligibility": {
"en": "You cannot make online payment because you are not eligible to use the provided service.",
"ar": "لا يمكنك إجراء الدفع عبر الإنترنت لأنك غير مؤهل لاستخدام الخدمة المقدمة."
@ -2016,4 +2022,5 @@ const Map localizedValues = {
"continueAgreeTerms": {"en": "By continuing, You agree to the above Terms and Conditions.", "ar": "من خلال المتابعة، فإنك توافق على الشروط والأحكام المذكورة أعلاه."},
"agreeText": {"en": "Agree", "ar": "أوافق"},
"ERCheckInSuccess": {"en": "Your ER Online Check-In has been successfully done.", "ar": "لقد تم تسجيل وصولك للطوارئ عبر الإنترنت بنجاح."},
};

@ -1,25 +1,25 @@
class EROnlineCheckInPaymentDetailsResponse {
num cashPrice;
num cashPriceTax;
num cashPriceWithTax;
int companyId;
String companyName;
num companyShareWithTax;
Null errCode;
int groupID;
String insurancePolicyNo;
String message;
String patientCardID;
num patientShare;
num patientShareWithTax;
num patientTaxAmount;
int policyId;
String policyName;
String procedureId;
String procedureName;
Null setupID;
int statusCode;
String subPolicyNo;
num? cashPrice;
num? cashPriceTax;
num? cashPriceWithTax;
int? companyId;
String? companyName;
num? companyShareWithTax;
dynamic errCode;
int? groupID;
String? insurancePolicyNo;
String? message;
String? patientCardID;
num? patientShare;
num? patientShareWithTax;
num? patientTaxAmount;
int? policyId;
String? policyName;
String? procedureId;
String? procedureName;
dynamic setupID;
int? statusCode;
String? subPolicyNo;
EROnlineCheckInPaymentDetailsResponse(
{this.cashPrice,

@ -21,10 +21,10 @@ class EROnlineCheckInBookAppointment extends StatefulWidget {
}
class _EROnlineCheckInBookAppointmentState extends State<EROnlineCheckInBookAppointment> with SingleTickerProviderStateMixin {
ProjectViewModel projectViewModel;
late ProjectViewModel projectViewModel;
List<HospitalsModel> projectsList = [];
final GlobalKey projectDropdownKey = GlobalKey();
HospitalsModel selectedHospital;
HospitalsModel? selectedHospital;
String projectDropdownValue = "";
@override
@ -85,13 +85,13 @@ class _EROnlineCheckInBookAppointmentState extends State<EROnlineCheckInBookAppo
items: projectsList.map((item) {
return new DropdownMenuItem<HospitalsModel>(
value: item,
child: new Text(item.name),
child: new Text(item.name!),
);
}).toList(),
onChanged: (newValue) async {
setState(() {
selectedHospital = newValue;
projectDropdownValue = newValue.mainProjectID.toString();
projectDropdownValue = newValue!.mainProjectID.toString();
});
},
),
@ -145,9 +145,9 @@ class _EROnlineCheckInBookAppointmentState extends State<EROnlineCheckInBookAppo
context,
FadePage(
page: EROnlineCheckInPaymentDetails(
projectID: selectedHospital.iD,
projectID: selectedHospital!.iD,
isERBookAppointment: true,
projectName: selectedHospital.name,
projectName: selectedHospital!.name ?? "",
),
),
);
@ -183,21 +183,21 @@ class _EROnlineCheckInBookAppointmentState extends State<EROnlineCheckInBookAppo
}
void openDropdown(GlobalKey key) {
GestureDetector detector;
GestureDetector? detector;
void searchForGestureDetector(BuildContext element) {
element.visitChildElements((element) {
if (element.widget != null && element.widget is GestureDetector) {
detector = element.widget;
return false;
detector = element.widget as GestureDetector?;
// return false;
} else {
searchForGestureDetector(element);
}
return true;
// return true;
});
}
searchForGestureDetector(key.currentContext);
searchForGestureDetector(key.currentContext!);
assert(detector != null);
detector.onTap();
detector!.onTap!();
}
}

@ -1,3 +1,4 @@
import 'package:diplomaticquarterapp/core/model/ImagesInfo.dart';
import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart';
import 'package:diplomaticquarterapp/pages/ErService/EROnlineCheckIn/EROnlineCheckInBookAppointment.dart';
import 'package:diplomaticquarterapp/pages/ErService/EROnlineCheckIn/EROnlineCheckInPaymentDetails.dart';
@ -26,7 +27,7 @@ class EROnlineCheckInHomePage extends StatefulWidget {
}
class _EROnlineCheckInHomePageState extends State<EROnlineCheckInHomePage> with SingleTickerProviderStateMixin {
ProjectViewModel projectViewModel;
late ProjectViewModel projectViewModel;
bool _supportsNFC = false;
bool isPatientArrived = false;
@ -34,7 +35,7 @@ class _EROnlineCheckInHomePageState extends State<EROnlineCheckInHomePage> with
void initState() {
WidgetsBinding.instance.addPostFrameCallback((_) {
// checkIfPatientHasArrived();
checkPatientERAdvanceBalance();
if (projectViewModel.isLogin) checkPatientERAdvanceBalance();
});
super.initState();
}
@ -48,9 +49,11 @@ class _EROnlineCheckInHomePageState extends State<EROnlineCheckInHomePage> with
return AppScaffold(
isShowAppBar: true,
appBarTitle: TranslationBase.of(context).emergency + " ${TranslationBase.of(context).checkinOptions}",
isShowDecPage: false,
isShowDecPage: true,
showNewAppBar: true,
showNewAppBarTitle: true,
description: TranslationBase.of(context).HHCNotAuthMsg,
imagesInfo: [ImagesInfo(imageAr: 'https://hmgwebservices.com/Images/MobileApp/HHC/ar/0.png', imageEn: 'https://hmgwebservices.com/Images/MobileApp/HHC/en/0.png')],
backgroundColor: Color(0xffF8F8F8),
body: SingleChildScrollView(
child: Padding(
@ -273,7 +276,7 @@ class _EROnlineCheckInHomePageState extends State<EROnlineCheckInHomePage> with
),
),
bottomSheet: Container(
height: 80,
height: projectViewModel.isLogin ? 80 : 1,
color: CustomColors.white,
padding: EdgeInsets.fromLTRB(12.0, 12.0, 12.0, 25.0),
child: isPatientArrived
@ -445,5 +448,4 @@ class _EROnlineCheckInHomePageState extends State<EROnlineCheckInHomePage> with
GifLoaderDialogUtils.hideDialog(context);
});
}
}

@ -34,19 +34,19 @@ class EROnlineCheckInPaymentDetails extends StatefulWidget {
bool isERBookAppointment = false;
String projectName = "";
EROnlineCheckInPaymentDetails({@required this.projectID, @required this.isERBookAppointment, @required this.projectName});
EROnlineCheckInPaymentDetails({required this.projectID, required this.isERBookAppointment, required this.projectName});
@override
State<EROnlineCheckInPaymentDetails> createState() => _EROnlineCheckInPaymentDetailsState();
}
class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDetails> with SingleTickerProviderStateMixin {
ProjectViewModel projectViewModel;
EROnlineCheckInPaymentDetailsResponse erOnlineCheckInPaymentDetailsResponse;
String selectedPaymentMethod;
String selectedInstallmentPlan;
late ProjectViewModel projectViewModel;
EROnlineCheckInPaymentDetailsResponse? erOnlineCheckInPaymentDetailsResponse;
String? selectedPaymentMethod;
String? selectedInstallmentPlan;
String transID = "";
MyInAppBrowser browser;
late MyInAppBrowser browser;
@override
void initState() {
@ -109,7 +109,7 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
),
mWidth(3),
Text(
projectViewModel.user.firstName + " " + projectViewModel.user.lastName,
projectViewModel.user.firstName! + " " + projectViewModel.user.lastName!,
style: TextStyle(
fontWeight: FontWeight.w600,
fontSize: 14,
@ -278,7 +278,7 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
width: MediaQuery.of(context).size.width * 0.75,
child: getPaymentMethods(),
),
_amountView(TranslationBase.of(context).patientShareTotalToDo, erOnlineCheckInPaymentDetailsResponse.patientShareWithTax.toString() + " " + TranslationBase.of(context).sar,
_amountView(TranslationBase.of(context).patientShareTotalToDo, erOnlineCheckInPaymentDetailsResponse!.patientShareWithTax.toString() + " " + TranslationBase.of(context).sar,
isBold: true, isTotal: true),
SizedBox(height: 12),
DefaultButton(
@ -300,7 +300,7 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
showDraggableDialog(
context,
PaymentMethod(
onSelectedMethod: (String method, [String selectedInstallmentPlan]) {
onSelectedMethod: (String method, [String? selectedInstallmentPlan]) {
selectedPaymentMethod = method;
this.selectedInstallmentPlan = selectedInstallmentPlan;
if (selectedPaymentMethod == "ApplePay") {
@ -309,25 +309,25 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
} else {
AppoitmentAllHistoryResultList appo = new AppoitmentAllHistoryResultList();
appo.projectID = widget.projectID;
openPayment(selectedPaymentMethod, projectViewModel.user, erOnlineCheckInPaymentDetailsResponse.patientShareWithTax, null);
openPayment(selectedPaymentMethod!, projectViewModel.user, erOnlineCheckInPaymentDetailsResponse!.patientShareWithTax!, AppoitmentAllHistoryResultList());
}
} else {
openPayment(selectedPaymentMethod, projectViewModel.user, erOnlineCheckInPaymentDetailsResponse.patientShareWithTax, null);
openPayment(selectedPaymentMethod!, projectViewModel.user, erOnlineCheckInPaymentDetailsResponse!.patientShareWithTax!, AppoitmentAllHistoryResultList());
}
},
patientShare: erOnlineCheckInPaymentDetailsResponse.patientShareWithTax,
patientShare: erOnlineCheckInPaymentDetailsResponse!.patientShareWithTax,
isFromAdvancePayment: false,
),
);
}
openPayment(String paymentMethod, AuthenticatedUser authenticatedUser, num amount, AppoitmentAllHistoryResultList appo) {
transID = Utils.getAdvancePaymentTransID(widget.projectID, projectViewModel.user.patientID);
transID = Utils.getAdvancePaymentTransID(widget.projectID, projectViewModel.user.patientID!);
browser = new MyInAppBrowser(onExitCallback: onBrowserExit, appo: appo, onLoadStartCallback: onBrowserLoadStart);
browser.openPaymentBrowser(amount, "ER Online Check-In Payment", transID, widget.projectID.toString(), authenticatedUser.emailAddress, paymentMethod, authenticatedUser.patientType,
authenticatedUser.firstName, authenticatedUser.patientID, authenticatedUser, browser, false, "3", "", null);
browser.openPaymentBrowser(amount, "ER Online Check-In Payment", transID, widget.projectID.toString(), authenticatedUser.emailAddress!, paymentMethod, authenticatedUser.patientType,
authenticatedUser.firstName!, authenticatedUser.patientID, authenticatedUser, browser, false, "3", "", context);
}
onBrowserLoadStart(String url) {
@ -357,7 +357,7 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
}
void startApplePay() async {
transID = Utils.getAdvancePaymentTransID(widget.projectID, projectViewModel.user.patientID);
transID = Utils.getAdvancePaymentTransID(widget.projectID, projectViewModel.user.patientID!);
print("TransactionID: $transID");
GifLoaderDialogUtils.showMyDialog(context);
@ -365,9 +365,9 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
LiveCareService service = new LiveCareService();
ApplePayInsertRequest applePayInsertRequest = new ApplePayInsertRequest();
PayfortProjectDetailsRespModel payfortProjectDetailsRespModel;
PayfortProjectDetailsRespModel? payfortProjectDetailsRespModel;
await context.read<PayfortViewModel>().getProjectDetailsForPayfort(projectId: widget.projectID, serviceId: ServiceTypeEnum.appointmentPayment.getIdFromServiceEnum()).then((value) {
payfortProjectDetailsRespModel = value;
payfortProjectDetailsRespModel = value!;
});
applePayInsertRequest.clientRequestID = transID;
@ -376,7 +376,7 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
// applePayInsertRequest.customerEmail = projectViewModel.authenticatedUserObject.user.emailAddress;
applePayInsertRequest.customerEmail = "CustID_${projectViewModel.user.patientID}@HMG.com";
applePayInsertRequest.customerID = projectViewModel.user.patientID;
applePayInsertRequest.customerName = projectViewModel.user.firstName + " " + projectViewModel.user.lastName;
applePayInsertRequest.customerName = projectViewModel.user.firstName! + " " + projectViewModel.user.lastName!;
applePayInsertRequest.deviceToken = await AppSharedPreferences().getString(PUSH_TOKEN);
applePayInsertRequest.voipToken = await AppSharedPreferences().getString(ONESIGNAL_APNS_TOKEN);
applePayInsertRequest.doctorID = 0;
@ -392,7 +392,7 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
applePayInsertRequest.liveServiceID = "0";
applePayInsertRequest.latitude = "0.0";
applePayInsertRequest.longitude = "0.0";
applePayInsertRequest.amount = erOnlineCheckInPaymentDetailsResponse.patientShareWithTax.toString();
applePayInsertRequest.amount = erOnlineCheckInPaymentDetailsResponse!.patientShareWithTax.toString();
applePayInsertRequest.isSchedule = "0";
applePayInsertRequest.language = projectViewModel.isArabic ? 'ar' : 'en';
applePayInsertRequest.languageID = projectViewModel.isArabic ? 1 : 2;
@ -403,22 +403,22 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
applePayInsertRequest.isMobSDK = true;
applePayInsertRequest.merchantReference = transID;
applePayInsertRequest.merchantIdentifier = payfortProjectDetailsRespModel.merchantIdentifier;
applePayInsertRequest.merchantIdentifier = payfortProjectDetailsRespModel!.merchantIdentifier;
applePayInsertRequest.commandType = "PURCHASE";
applePayInsertRequest.signature = payfortProjectDetailsRespModel.signature;
applePayInsertRequest.accessCode = payfortProjectDetailsRespModel.accessCode;
applePayInsertRequest.shaRequestPhrase = payfortProjectDetailsRespModel.shaRequest;
applePayInsertRequest.shaResponsePhrase = payfortProjectDetailsRespModel.shaResponse;
applePayInsertRequest.signature = payfortProjectDetailsRespModel!.signature;
applePayInsertRequest.accessCode = payfortProjectDetailsRespModel!.accessCode;
applePayInsertRequest.shaRequestPhrase = payfortProjectDetailsRespModel!.shaRequest;
applePayInsertRequest.shaResponsePhrase = payfortProjectDetailsRespModel!.shaResponse;
applePayInsertRequest.returnURL = "";
service.applePayInsertRequest(applePayInsertRequest, context).then((res) async {
if (res["MessageStatus"] == 1) {
await context.read<PayfortViewModel>().initiateApplePayWithPayfort(
customerName: projectViewModel.user.firstName + " " + projectViewModel.user.lastName,
customerName: projectViewModel.user.firstName! + " " + projectViewModel.user.lastName!,
// customerEmail: projectViewModel.authenticatedUserObject.user.emailAddress,
customerEmail: "CustID_${projectViewModel.user.patientID}@HMG.com",
orderDescription: "ER Online Check-In Payment",
orderAmount: erOnlineCheckInPaymentDetailsResponse.patientShareWithTax,
orderAmount: erOnlineCheckInPaymentDetailsResponse!.patientShareWithTax,
merchantReference: transID,
payfortProjectDetailsRespModel: payfortProjectDetailsRespModel,
currency: projectViewModel.user.outSA == 1 ? "AED" : "SAR",
@ -428,7 +428,7 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
},
onSuccess: (successResult) async {
log("Payfort: ${successResult.responseMessage}");
await context.read<PayfortViewModel>().addPayfortApplePayResponse(projectViewModel.user.patientID, result: successResult);
await context.read<PayfortViewModel>().addPayfortApplePayResponse(projectViewModel.user.patientID!, result: successResult);
GifLoaderDialogUtils.hideDialog(context);
checkPaymentStatus(AppoitmentAllHistoryResultList());
},
@ -497,7 +497,7 @@ class _EROnlineCheckInPaymentDetailsState extends State<EROnlineCheckInPaymentDe
DoctorsListService service = new DoctorsListService();
String paymentReference = paymentRes['Fort_id'].toString();
service.HIS_createAdvancePayment(appo, widget.projectID.toString(), paymentRes['Amount'], paymentRes['Fort_id'], paymentRes['PaymentMethod'], projectViewModel.user.patientType,
projectViewModel.user.firstName + " " + projectViewModel.user.lastName, projectViewModel.user.patientID, context)
projectViewModel.user.firstName! + " " + projectViewModel.user.lastName!, projectViewModel.user.patientID, context)
.then((res) {
addAdvancedNumberRequest(
Utils.isVidaPlusProject(projectViewModel, widget.projectID)

@ -241,18 +241,18 @@ class _InPatientServicesHomeState extends State<InPatientServicesHome> {
void checkDischargeMedications(BuildContext context) {
ClinicListService service = new ClinicListService();
GifLoaderDialogUtils.showMyDialog(context);
// service.getDischargeMedicationOrder(projectViewModel.getAdmissionInfoResponseModel).then((res) {
// print(res["PatientHasDischargeMedicineList"].length);
// setState(() {
// if (res["PatientHasDischargeMedicineList"].length != 0) {
// isReceivePrescriptionEnabled = true;
// }
// });
// GifLoaderDialogUtils.hideDialog(context);
// }).catchError((err) {
// GifLoaderDialogUtils.hideDialog(context);
// print(err);
// });
service.getDischargeMedicationOrder(projectViewModel.getAdmissionInfoResponseModel).then((res) {
print(res["PatientHasDischargeMedicineList"].length);
setState(() {
if (res["PatientHasDischargeMedicineList"].length != 0) {
isReceivePrescriptionEnabled = true;
}
});
GifLoaderDialogUtils.hideDialog(context);
}).catchError((err) {
GifLoaderDialogUtils.hideDialog(context);
print(err);
});
}
void callReceivePrescriptionAPI(BuildContext context) {
@ -298,6 +298,7 @@ class _InPatientServicesHomeState extends State<InPatientServicesHome> {
print(res['generalInstructions']);
Navigator.push(context, FadePage(page: GeneralInstructions(getGeneralInstructionsList: getGeneralInstructionsList)));
} else {
GifLoaderDialogUtils.hideDialog(context);
AppToast.showErrorToast(message: TranslationBase.of(context).noGeneralInstructions);
}
}).catchError((err) {

@ -60,6 +60,7 @@ class _HomePageFragment2State extends State<HomePageFragment2> {
? hmgServices.add(HmgServices(2, TranslationBase.of(context).hospitalNavigationTitle, TranslationBase.of(context).hospitalNavigationSubtitle, "assets/images/new/indoor_nav_home.svg", isLogin))
: hmgServices.add(HmgServices(2, TranslationBase.of(context).emergencyTitle, TranslationBase.of(context).emergencySubtitle, "assets/images/new/emergency.svg", isLogin));
hmgServices.add(HmgServices(9, TranslationBase.of(context).emergency, TranslationBase.of(context).checkinOptions, "assets/images/new/emergency.svg", isLogin));
hmgServices.add(HmgServices(3, TranslationBase.of(context).hhcHome, TranslationBase.of(context).healthCare, "assets/images/new/HHC.svg", isLogin));
hmgServices.add(HmgServices(4, TranslationBase.of(context).checkup, TranslationBase.of(context).comprehensive, "assets/images/new/comprehensive_checkup.svg", isLogin));
hmgServices.add(HmgServices(5, TranslationBase.of(context).online, TranslationBase.of(context).payment, "assets/images/new/paymentMethods.png", isLogin));
@ -73,13 +74,20 @@ class _HomePageFragment2State extends State<HomePageFragment2> {
// hmgServices.add(new HmgServices(0, TranslationBase.of(context).liveCare, TranslationBase.of(context).onlineConsulting, "assets/images/new/Live_Care.svg", isLogin));
// hmgServices.add(new HmgServices(1, TranslationBase.of(context).covidTest, TranslationBase.of(context).driveThru, "assets/images/new/CoronaIcon.svg", isLogin));
// hmgServices.add(new HmgServices(2, TranslationBase.of(context).online, TranslationBase.of(context).payment, "assets/images/new/paymentMethods.png", isLogin));
hmgServices.add(new HmgServices(9, TranslationBase.of(context).emergency, TranslationBase.of(context).checkinOptions, "assets/images/new/emergency.svg", isLogin));
projectViewModel.isIndoorNavigationEnabled
? hmgServices.add(HmgServices(2, TranslationBase.of(context).hospitalNavigationTitle, TranslationBase.of(context).hospitalNavigationSubtitle, "assets/images/new/indoor_nav_home.svg", isLogin))
: hmgServices.add(HmgServices(2, TranslationBase.of(context).emergencyTitle, TranslationBase.of(context).emergencySubtitle, "assets/images/new/emergency.svg", isLogin));
hmgServices.add(new HmgServices(3, TranslationBase.of(context).hhcHome, TranslationBase.of(context).healthCare, "assets/images/new/HHC.svg", isLogin));
hmgServices.add(new HmgServices(4, TranslationBase.of(context).checkup, TranslationBase.of(context).comprehensive, "assets/images/new/comprehensive_checkup.svg", isLogin));
hmgServices.add(new HmgServices(2, TranslationBase.of(context).emergencyTitle, TranslationBase.of(context).emergencySubtitle, "assets/images/new/emergency.svg", isLogin));
// hmgServices.add(new HmgServices(2, TranslationBase.of(context).emergencyTitle, TranslationBase.of(context).emergencySubtitle, "assets/images/new/emergency.svg", isLogin));
hmgServices.add(new HmgServices(6, TranslationBase.of(context).ereferralTitle, TranslationBase.of(context).ereferralSubtitle, "assets/images/new/E_Referral.svg", isLogin));
hmgServices.add(new HmgServices(7, "H\u2082O", TranslationBase.of(context).dailyWater, "assets/images/new/h2o.svg", isLogin));
hmgServices.add(new HmgServices(8, TranslationBase.of(context).connectTitle, TranslationBase.of(context).connectSubtitle, "assets/images/new/reach_us.svg", isLogin));
hmgServices.add(new HmgServices(9, TranslationBase.of(context).emergency, TranslationBase.of(context).checkinOptions, "assets/images/new/emergency.svg", isLogin));
}
@override
@ -350,7 +358,8 @@ class _HomePageFragment2State extends State<HomePageFragment2> {
itemCount: hmgServices.length,
padding: EdgeInsets.zero,
itemBuilder: (BuildContext context, int index) {
return ServicesView(hmgServices[index], index, true, projectViewModel, isLocked: (hmgServices[index].action == 2 && projectViewModel.isIndoorNavigationEnabled) ? !projectViewModel.havePrivilege(107) : false);
return ServicesView(hmgServices[index], index, true, projectViewModel,
isLocked: (hmgServices[index].action == 2 && projectViewModel.isIndoorNavigationEnabled) ? !projectViewModel.havePrivilege(107) : false);
},
),
),

@ -754,7 +754,8 @@ class _ConfirmLogin extends State<ConfirmLogin> {
if (hasAdmissionRequest) {
if (res['MedicalInstruction'].length != 0) {
getAdmissionRequestInfoResponseModel = GetAdmissionRequestInfoResponseModel.fromJson(res['MedicalInstruction'][0]);
projectViewModel.setInPatientProjectID(res['MedicalInstruction'][0]['ProjectID']);
// projectViewModel.setInPatientProjectID(res['MedicalInstruction'][0]['ProjectID']);
projectViewModel.setInPatientProjectID(res['MedicalInstruction'][0]['projectId']);
projectViewModel.setInPatientAdmissionRequest(getAdmissionRequestInfoResponseModel);
projectViewModel.setPatientHasAdmissionRequest(true);
}
@ -791,6 +792,7 @@ class _ConfirmLogin extends State<ConfirmLogin> {
// GifLoaderDialogUtils.hideDialog(context);
getToDoCount();
checkIfIsInPatient();
appointmentRateViewModel
.getIsLastAppointmentRatedList(projectViewModel.isArabic ? 1 : 2)
.then((value) => {

@ -386,6 +386,7 @@ class _Login extends State<Login> {
// ),
// (r) => false);
getToDoCount();
checkIfIsInPatient();
appointmentRateViewModel
.getIsLastAppointmentRatedList(projectViewModel.isArabic ? 1 : 2)
.then((value) => {

@ -1880,7 +1880,7 @@ class DoctorsListService extends BaseService {
return Future.value(localRes);
}
Future<Map> autoGenerateInvoiceERClinic(int projectID, int paymentMethod, String paymentReferenceNo, num amount, String cardType, String cardNumber, String orderID, String rrn, bool isAdvanceAvailable) async {
Future<Map> autoGenerateInvoiceERClinic(int? projectID, int? paymentMethod, String? paymentReferenceNo, num? amount, String? cardType, String? cardNumber, String? orderID, String? rrn, bool isAdvanceAvailable) async {
Map<String, dynamic> request;
request = {
"ProjectID": projectID,

@ -495,4 +495,43 @@ class ClinicListService extends BaseService {
}, body: request, isAllowAny: true);
return Future.value(localRes);
}
Future<Map> getDischargeMedicationOrder(GetAdmissionInfoResponseModel getAdmissionInfoResponseModel) async {
Map<String, dynamic> request;
request = {
"ProjectID": getAdmissionInfoResponseModel.projectID,
"ClinicID": getAdmissionInfoResponseModel.clinicID,
"DoctorID": getAdmissionInfoResponseModel.doctorID,
"AdmissionNo": getAdmissionInfoResponseModel.admissionNo
};
// request = {
// "ProjectID": 12,
// "VersionID": 10.8,
// "Channel": 3,
// "LanguageID": 2,
// "IPAdress": "10.20.10.20",
// "generalid": "Cs2020@2016\$2958",
// "DeviceTypeID": 2,
// "PatientType": 1,
// "PatientTypeID": 1,
// "TokenID": "@dm!n",
// "PatientID": 869588,
// "PatientOutSA": 0,
// "SessionID": "rVuK3nzN4UKN0SW95un0jQ==",
// "ClinicID": 2,
// "DoctorID": "7600",
// "AdmissionNo": 2011001258
// };
dynamic localRes;
await baseAppClient.post(INPATIENT_DISCHARGE_MEDICATIONS, onSuccess: (response, statusCode) async {
localRes = response;
}, onFailure: (String error, int statusCode) {
throw error;
}, body: request, isAllowAny: true);
return Future.value(localRes);
}
}

@ -38,9 +38,9 @@ class MyInAppBrowser extends InAppBrowser {
static String APPLE_PAY_PAYFORT_URL = 'https://hmgwebservices.com/PayFortWebLive/PayFortApi/MakeApplePayRequest'; // Payfort Payment Gateway URL LIVE
// static String APPLE_PAY_PAYFORT_URL = 'https://hmgwebservices.com/PayFortWebLive/PayFortApi/MakeApplePayRequest'; // Payfort Payment Gateway URL UAT
// static String SERVICE_URL = 'https://hmgwebservices.com/PayFortWeb/pages/SendPayFortRequest.aspx'; // Payfort Payment Gateway URL UAT
static String SERVICE_URL = 'https://hmgwebservices.com/PayFortWeb/pages/SendPayFortRequest.aspx'; // Payfort Payment Gateway URL UAT
static String SERVICE_URL = 'https://hmgwebservices.com/PayFortWebLive/pages/SendPayFortRequest.aspx'; //Payfort Payment Gateway URL LIVE
// static String SERVICE_URL = 'https://hmgwebservices.com/PayFortWebLive/pages/SendPayFortRequest.aspx'; //Payfort Payment Gateway URL LIVE
// static String SERVICE_URL = 'https://uat.hmgwebservices.com/payfortforvidaplus/pages/SendPayFortRequest.aspx'; //Payfort Payment Gateway URL UAT VIDA PLUS

Loading…
Cancel
Save