From 25af2c23ef4df0e1ad950bef1deee0564a2e3382 Mon Sep 17 00:00:00 2001 From: haroon amjad Date: Tue, 6 Dec 2022 13:22:48 +0300 Subject: [PATCH] Sick leave CR, LiveCare support call, Appo calendar changes --- lib/config/config.dart | 5 + lib/config/localized_values.dart | 4 + lib/core/model/sick_leave/sick_leave.dart | 5 +- lib/core/model/vaccine/my_vaccine.dart | 10 +- lib/core/service/client/base_app_client.dart | 2 +- .../medical/PatientSickLeaveService.dart | 2 +- lib/core/service/medical/labs_service.dart | 20 ++ .../components/DocAvailableAppointments.dart | 3 +- .../widgets/LiveCarePendingRequest.dart | 18 +- .../medical/labs/passport_update_page.dart | 1 - .../medical/patient_sick_leave_page.dart | 35 +++ .../sickleave_workplace_update_page.dart | 232 ++++++++++++++++++ lib/pages/vaccine/my_vaccines_screen.dart | 5 +- lib/uitl/translations_delegate_base.dart | 4 + lib/widgets/in_app_browser/InAppBrowser.dart | 10 +- 15 files changed, 332 insertions(+), 24 deletions(-) create mode 100644 lib/pages/medical/sickleave_workplace_update_page.dart diff --git a/lib/config/config.dart b/lib/config/config.dart index 288d7fd3..a7676855 100644 --- a/lib/config/config.dart +++ b/lib/config/config.dart @@ -102,6 +102,9 @@ var COVID_PASSPORT_UPDATE = var GET_PATIENT_PASSPORT_NUMBER = 'Services/Patients.svc/REST/Covid19_Certificate_GetPassport'; +var UPDATE_WORKPLACE_NAME = + 'Services/Patients.svc/REST/ActivateSickLeave_FromVida'; + /// var GET_PATIENT_ORDERS = 'Services/Patients.svc/REST/GetPatientRadOrders'; var GET_PATIENT_LAB_ORDERS_BY_APPOINTMENT = @@ -450,6 +453,8 @@ var GET_VACCINATION_ONHAND = "/Services/ERP.svc/REST/GET_VACCINATION_ONHAND"; var GET_PATIENT_SICK_LEAVE = 'Services/Patients.svc/REST/GetPatientSickLeave'; +var GET_PATIENT_SICK_LEAVE_STATUS = 'Services/Patients.svc/REST/GetPatientSickLeave_Status'; + var SendSickLeaveEmail = 'Services/Notifications.svc/REST/SendSickLeaveEmail'; var GET_PATIENT_AdVANCE_BALANCE_AMOUNT = diff --git a/lib/config/localized_values.dart b/lib/config/localized_values.dart index 509a415d..915ebaa6 100644 --- a/lib/config/localized_values.dart +++ b/lib/config/localized_values.dart @@ -1862,4 +1862,8 @@ const Map localizedValues = { "insuranceClassName": { "en": "Insurance Class", "ar": "فئة التأمين" }, "insuranceRequestSubmit": { "en": "Your insurance update request has been submitted successfully.", "ar": "تم تقديم طلب تحديث التأمين الخاص بك بنجاح." }, "NFCNotSupported": { "en": "Your device does not support NFC. Please visit reception to Check-In", "ar": "جهازك لا يدعم NFC. يرجى زيارة مكتب الاستقبال لتسجيل الوصول" }, + "enter-workplace-name": {"en": "Please enter your workplace name:", "ar": "رجاء إدخال مكان العمل:"}, + "workplaceName": {"en": "Workplace name:", "ar": "مكان العمل:"}, + "callLiveCareSupport": {"en": "Call LiveCare Support", "ar": "اتصل بدعم لايف كير"}, + "needApproval": {"en": "Your sick leave needs approval, please contact a medical report department.", "ar": "جازتك المرضيه تحتاج الى الموافقة, يرجى التواصل مع قسم التقارير الطبية.:"}, }; diff --git a/lib/core/model/sick_leave/sick_leave.dart b/lib/core/model/sick_leave/sick_leave.dart index 1d396e18..10862230 100644 --- a/lib/core/model/sick_leave/sick_leave.dart +++ b/lib/core/model/sick_leave/sick_leave.dart @@ -33,6 +33,7 @@ class SickLeave { String qR; List speciality; bool isLiveCareAppointment; + int status; SickLeave( {this.setupID, @@ -65,7 +66,7 @@ class SickLeave { this.patientName, this.projectName, this.qR, - this.speciality,this.isLiveCareAppointment}); + this.speciality,this.isLiveCareAppointment, this.status}); SickLeave.fromJson(Map json) { setupID = json['SetupID']; @@ -98,6 +99,7 @@ class SickLeave { patientName = json['PatientName']; projectName = json['ProjectName']; qR = json['QR']; + status = json['Status']; isLiveCareAppointment = json['IsLiveCareAppointment']; if(json['Speciality']!=null) speciality = json['Speciality'].cast(); @@ -135,6 +137,7 @@ class SickLeave { data['PatientName'] = this.patientName; data['ProjectName'] = this.projectName; data['QR'] = this.qR; + data['Status'] = this.status; data['Speciality'] = this.speciality; return data; } diff --git a/lib/core/model/vaccine/my_vaccine.dart b/lib/core/model/vaccine/my_vaccine.dart index dc921c12..da1b243d 100644 --- a/lib/core/model/vaccine/my_vaccine.dart +++ b/lib/core/model/vaccine/my_vaccine.dart @@ -5,16 +5,16 @@ class VaccineModel { int invoiceNo; String procedureID; String vaccineName; - Null vaccineNameN; + dynamic vaccineNameN; String invoiceDate; int doctorID; int clinicID; String firstName; String middleName; String lastName; - Null firstNameN; - Null middleNameN; - Null lastNameN; + dynamic firstNameN; + dynamic middleNameN; + dynamic lastNameN; String dateofBirth; int actualDoctorRate; String age; @@ -106,7 +106,7 @@ class VaccineModel { patientName = json['PatientName']; projectName = json['ProjectName']; qR = json['QR']; - speciality = json['Speciality'].cast(); + speciality = json['Speciality'] != null ? json['Speciality'].cast() : []; vaccinationDate = json['VaccinationDate']; } diff --git a/lib/core/service/client/base_app_client.dart b/lib/core/service/client/base_app_client.dart index 009ed4ad..bb6e4d96 100644 --- a/lib/core/service/client/base_app_client.dart +++ b/lib/core/service/client/base_app_client.dart @@ -149,7 +149,7 @@ class BaseAppClient { // body['IdentificationNo'] = 1023854217; // body['MobileNo'] = "531940021"; - // body['PatientID'] = 3126070; //3844083 + // body['PatientID'] = 870215; //3844083 // body['TokenID'] = "@dm!n"; // Patient ID: 3027574 diff --git a/lib/core/service/medical/PatientSickLeaveService.dart b/lib/core/service/medical/PatientSickLeaveService.dart index bb60ee3b..10d30606 100644 --- a/lib/core/service/medical/PatientSickLeaveService.dart +++ b/lib/core/service/medical/PatientSickLeaveService.dart @@ -8,7 +8,7 @@ class PatientSickLeaveService extends BaseService { getSickLeave() async { hasError = false; super.error = ""; - await baseAppClient.post(GET_PATIENT_SICK_LEAVE, + await baseAppClient.post(GET_PATIENT_SICK_LEAVE_STATUS, onSuccess: (response, statusCode) async { sickLeaveList.clear(); response['List_SickLeave'].forEach((sickLeave) { diff --git a/lib/core/service/medical/labs_service.dart b/lib/core/service/medical/labs_service.dart index 3ee02017..a3274380 100644 --- a/lib/core/service/medical/labs_service.dart +++ b/lib/core/service/medical/labs_service.dart @@ -115,6 +115,26 @@ class LabsService extends BaseService { return Future.value(localRes); } + Future updateWorkplaceName(String workplaceName, int requestNumber, String setupID) async { + hasError = false; + Map body = Map(); + + body['Placeofwork'] = workplaceName; + body['Placeofworkar'] = workplaceName; + body['Req_ID'] = requestNumber; + body['TargetSetupID'] = setupID; + + dynamic localRes; + + await baseAppClient.post(UPDATE_WORKPLACE_NAME, onSuccess: (dynamic response, int statusCode) { + localRes = response; + }, onFailure: (String error, int statusCode) { + hasError = true; + super.error = error; + }, body: body); + return Future.value(localRes); + } + Future getCovidPassportNumber() async { hasError = false; Map body = Map(); diff --git a/lib/pages/BookAppointment/components/DocAvailableAppointments.dart b/lib/pages/BookAppointment/components/DocAvailableAppointments.dart index 2836be0f..9b5374ef 100644 --- a/lib/pages/BookAppointment/components/DocAvailableAppointments.dart +++ b/lib/pages/BookAppointment/components/DocAvailableAppointments.dart @@ -174,7 +174,8 @@ class _DocAvailableAppointmentsState extends State wit headerStyle: CalendarHeaderStyle(textAlign: TextAlign.center, textStyle: TextStyle(fontSize: 14.0, fontWeight: FontWeight.w600, letterSpacing: -0.46)), viewHeaderStyle: ViewHeaderStyle(dayTextStyle: TextStyle(fontSize: 12.0, fontWeight: FontWeight.w600, letterSpacing: -0.46, color: CustomColors.black)), view: CalendarView.month, - todayHighlightColor: CustomColors.green, + todayHighlightColor: Colors.transparent, + todayTextStyle: TextStyle(color: Colors.black), selectionDecoration: containerColorRadiusBorderWidthCircular(Colors.transparent, 4, CustomColors.green, 2.5), cellBorderColor: Colors.white, dataSource: MeetingDataSource(_getDataSource()), diff --git a/lib/pages/livecare/widgets/LiveCarePendingRequest.dart b/lib/pages/livecare/widgets/LiveCarePendingRequest.dart index c5628276..12be6bc2 100644 --- a/lib/pages/livecare/widgets/LiveCarePendingRequest.dart +++ b/lib/pages/livecare/widgets/LiveCarePendingRequest.dart @@ -8,9 +8,11 @@ import 'package:diplomaticquarterapp/uitl/date_uitl.dart'; import 'package:diplomaticquarterapp/uitl/gif_loader_dialog_utils.dart'; import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart'; import 'package:diplomaticquarterapp/uitl/utils_new.dart'; +import 'package:diplomaticquarterapp/widgets/buttons/defaultButton.dart'; import 'package:diplomaticquarterapp/widgets/my_rich_text.dart'; import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; +import 'package:url_launcher/url_launcher.dart'; class LiveCarePendingRequest extends StatefulWidget { ErRequestHistoryList pendingERRequestHistoryList; @@ -94,11 +96,13 @@ class _LiveCarePendingRequestState extends State { child: Text(TranslationBase.of(context).yourTurn + " " + widget.pendingERRequestHistoryList.patCount.toString() + " " + TranslationBase.of(context).patients, style: TextStyle(fontSize: 12.0, fontWeight: FontWeight.w600, letterSpacing: -0.48)), ), - // Container( - // child: DefaultButton(TranslationBase.of(context).cancel, () { - // cancelLiveCareRequest(); - // }), - // ), + mHeight(12.0), + Container( + child: DefaultButton(TranslationBase.of(context).callLiveCareSupport, () { + launchUrl(Uri.parse("tel://" + "011 525 9553")); + // cancelLiveCareRequest(); + }), + ), ], ), ), @@ -216,6 +220,10 @@ class _LiveCarePendingRequestState extends State { ); } + callLiveCareSupport() { + + } + cancelLiveCareRequest() { LiveCareService service = new LiveCareService(); GifLoaderDialogUtils.showMyDialog(context); diff --git a/lib/pages/medical/labs/passport_update_page.dart b/lib/pages/medical/labs/passport_update_page.dart index 0f512982..585d7d3f 100644 --- a/lib/pages/medical/labs/passport_update_page.dart +++ b/lib/pages/medical/labs/passport_update_page.dart @@ -33,7 +33,6 @@ class _PassportUpdatePageState extends State { return AppScaffold( appBarTitle: TranslationBase.of(context).passportNumber, isShowAppBar: true, - isBottomBar: true, showNewAppBar: true, showNewAppBarTitle: true, backgroundColor: CustomColors.appBackgroudGrey2Color, diff --git a/lib/pages/medical/patient_sick_leave_page.dart b/lib/pages/medical/patient_sick_leave_page.dart index 401bf694..b68badd8 100644 --- a/lib/pages/medical/patient_sick_leave_page.dart +++ b/lib/pages/medical/patient_sick_leave_page.dart @@ -2,10 +2,13 @@ import 'package:diplomaticquarterapp/core/model/ImagesInfo.dart'; import 'package:diplomaticquarterapp/core/viewModels/medical/patient_sick_leave_view_model.dart'; import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart'; import 'package:diplomaticquarterapp/pages/base/base_view.dart'; +import 'package:diplomaticquarterapp/pages/medical/sickleave_workplace_update_page.dart'; import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart'; import 'package:diplomaticquarterapp/widgets/data_display/medical/doctor_card.dart'; +import 'package:diplomaticquarterapp/widgets/dialogs/confirm_dialog.dart'; import 'package:diplomaticquarterapp/widgets/dialogs/confirm_send_email_dialog.dart'; import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart'; +import 'package:diplomaticquarterapp/widgets/transitions/fade_page.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:provider/provider.dart'; @@ -64,6 +67,29 @@ class _PatientSickLeavePageState extends State { } void showConfirmMessage(PatientSickLeaveViewMode model, int index) { + // if (model.sickLeaveList[index].status == 1) { + // openWorkPlaceUpdatePage(model.sickLeaveList[index].requestNo, model.sickLeaveList[index].setupID, model, index); + // } else if (model.sickLeaveList[index].status == 2) { + showEmailDialog(model, index); + // } else { + // showApprovalDialog(); + // } + } + + void showApprovalDialog() { + ConfirmDialog dialog = new ConfirmDialog( + context: context, + confirmMessage: TranslationBase.of(context).needApproval, + okText: TranslationBase.of(context).ok, + cancelText: TranslationBase.of(context).cancel_nocaps, + okFunction: () { + Navigator.of(context).pop(); + }, + cancelFunction: () => {}); + dialog.showAlertDialog(context); + } + + void showEmailDialog(PatientSickLeaveViewMode model, int index) { showDialog( context: context, builder: (cxt) => ConfirmSendEmailDialog( @@ -80,4 +106,13 @@ class _PatientSickLeavePageState extends State { ), ); } + + void openWorkPlaceUpdatePage(int requestNumber, String setupID, PatientSickLeaveViewMode model, int index) { + Navigator.push(context, FadePage(page: WorkplaceUpdatePage(requestNumber: requestNumber, setupID: setupID))).then((value) { + print(value); + if (value != null && value == true) { + showEmailDialog(model, index); + } + }); + } } diff --git a/lib/pages/medical/sickleave_workplace_update_page.dart b/lib/pages/medical/sickleave_workplace_update_page.dart new file mode 100644 index 00000000..4e17d1de --- /dev/null +++ b/lib/pages/medical/sickleave_workplace_update_page.dart @@ -0,0 +1,232 @@ +import 'package:diplomaticquarterapp/core/service/medical/labs_service.dart'; +import 'package:diplomaticquarterapp/core/viewModels/project_view_model.dart'; +import 'package:diplomaticquarterapp/theme/colors.dart'; +import 'package:diplomaticquarterapp/uitl/app_toast.dart'; +import 'package:diplomaticquarterapp/uitl/gif_loader_dialog_utils.dart'; +import 'package:diplomaticquarterapp/uitl/translations_delegate_base.dart'; +import 'package:diplomaticquarterapp/uitl/utils_new.dart'; +import 'package:diplomaticquarterapp/widgets/dialogs/confirm_dialog.dart'; +import 'package:diplomaticquarterapp/widgets/others/app_scaffold_widget.dart'; +import 'package:flutter/material.dart'; +import 'package:flutter_svg/flutter_svg.dart'; +import 'package:provider/provider.dart'; + +class WorkplaceUpdatePage extends StatefulWidget { + final int requestNumber; + final String setupID; + + WorkplaceUpdatePage({@required this.requestNumber, @required this.setupID}); + + @override + _WorkplaceUpdatePageState createState() => _WorkplaceUpdatePageState(); +} + +class _WorkplaceUpdatePageState extends State { + TextEditingController workplaceName = new TextEditingController(); + bool _isButtonDisabled; + ProjectViewModel projectViewModel; + + @override + void initState() { + super.initState(); + } + + @override + Widget build(BuildContext context) { + projectViewModel = Provider.of(context); + return AppScaffold( + appBarTitle: TranslationBase.of(context).sickLeaves, + isShowAppBar: true, + showNewAppBar: true, + showNewAppBarTitle: true, + backgroundColor: CustomColors.appBackgroudGrey2Color, + body: Container( + child: Column( + children: [ + Expanded( + child: SingleChildScrollView( + child: Padding( + padding: const EdgeInsets.all(12.0), + child: Column( + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + mHeight(12), + SvgPicture.asset("assets/images/new/workplace-icon.svg", width: 40.0, fit: BoxFit.fill), + mHeight(12), + Text( + TranslationBase.of(context).enterWorkplaceName, + textAlign: TextAlign.start, + style: TextStyle( + fontSize: 16.0, + fontWeight: FontWeight.bold, + color: Colors.black, + letterSpacing: -0.64, + ), + ), + mHeight(8), + inputWidget(TranslationBase.of(context).workplaceName, "", workplaceName), + ], + ), + ), + ), + ), + Card( + margin: EdgeInsets.zero, + elevation: 0, + child: Container( + padding: EdgeInsets.all(12), + child: FractionallySizedBox( + widthFactor: 1, + child: MaterialButton( + height: 50, + elevation: 0, + color: CustomColors.accentColor, + disabledColor: Theme.of(context).appBarTheme.color.withOpacity(0.25), + shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(10)), + child: Text( + TranslationBase.of(context).submit, + style: TextStyle( + fontSize: 16.0, + letterSpacing: -0.64, + color: Colors.white, + ), + ), + onPressed: () { + if (_isButtonDisabled == false) + updateWorkplaceNameDialog(); + else + AppToast.showErrorToast(message: TranslationBase.of(context).enterWorkplaceName); + }, + ), + ), + ), + ), + ], + ), + ), + ); + } + + Widget inputWidget(String _labelText, String _hintText, TextEditingController _controller, {String prefix, bool isEnable = true, bool hasSelection = false}) { + return Container( + padding: EdgeInsets.only(left: 16, right: 16, bottom: 15, top: 15), + alignment: Alignment.center, + decoration: BoxDecoration( + borderRadius: BorderRadius.circular(15), + color: Colors.white, + border: Border.all( + color: Color(0xffefefef), + width: 1, + ), + ), + child: InkWell( + onTap: hasSelection ? () {} : null, + child: Row( + children: [ + Expanded( + child: Column( + mainAxisSize: MainAxisSize.min, + crossAxisAlignment: CrossAxisAlignment.start, + children: [ + Text( + _labelText, + style: TextStyle( + fontSize: 11, + fontWeight: FontWeight.w600, + color: Color(0xff2B353E), + letterSpacing: -0.44, + ), + ), + TextField( + enabled: isEnable, + scrollPadding: EdgeInsets.zero, + keyboardType: TextInputType.name, + controller: _controller, + onChanged: (value) => {_onPassportTextChanged(value)}, + style: TextStyle( + fontSize: 14, + height: 21 / 14, + fontWeight: FontWeight.w400, + color: Color(0xff2B353E), + letterSpacing: -0.44, + ), + decoration: InputDecoration( + isDense: true, + hintText: _hintText, + hintStyle: TextStyle( + fontSize: 14, + height: 21 / 14, + fontWeight: FontWeight.w400, + color: Color(0xff575757), + letterSpacing: -0.56, + ), + prefixIconConstraints: BoxConstraints(minWidth: 50), + prefixIcon: prefix == null + ? null + : Text( + "+" + prefix, + style: TextStyle( + fontSize: 14, + height: 21 / 14, + fontWeight: FontWeight.w500, + color: Color(0xff2E303A), + letterSpacing: -0.56, + ), + ), + contentPadding: EdgeInsets.zero, + border: InputBorder.none, + focusedBorder: InputBorder.none, + enabledBorder: InputBorder.none, + ), + ), + ], + ), + ), + if (hasSelection) Icon(Icons.keyboard_arrow_down_outlined), + ], + ), + ), + ); + } + + _onPassportTextChanged(content) { + if (content.length >= 1) { + setState(() { + _isButtonDisabled = false; + }); + } else { + setState(() { + _isButtonDisabled = true; + }); + } + } + + updateWorkplaceNameDialog() { + var messageEn = "The workplace name you entered is: " + workplaceName.text + ". Please confirm!"; + var messageAr = "اسم مكان العمل الذي أدخلته هو: " + workplaceName.text + ". يرجى تأكيد!"; + ConfirmDialog dialog = new ConfirmDialog( + context: context, + confirmMessage: projectViewModel.isArabic ? messageAr : messageEn, + okText: TranslationBase.of(context).confirm, + cancelText: TranslationBase.of(context).cancel_nocaps, + okFunction: () { + Navigator.of(context).pop(); + updateWorkplaceName(); + }, + cancelFunction: () => {}); + dialog.showAlertDialog(context); + } + + void updateWorkplaceName() { + LabsService service = new LabsService(); + GifLoaderDialogUtils.showMyDialog(context); + + service.updateWorkplaceName(workplaceName.text, widget.requestNumber, widget.setupID).then((res) { + GifLoaderDialogUtils.hideDialog(context); + Navigator.of(context).pop(true); + }).catchError((err) { + GifLoaderDialogUtils.hideDialog(context); + print(err); + }); + } +} diff --git a/lib/pages/vaccine/my_vaccines_screen.dart b/lib/pages/vaccine/my_vaccines_screen.dart index 52096746..d89fa870 100644 --- a/lib/pages/vaccine/my_vaccines_screen.dart +++ b/lib/pages/vaccine/my_vaccines_screen.dart @@ -37,8 +37,7 @@ class _MyVaccinesState extends State { imagesInfo: [ ImagesInfo(imageEn: 'https://hmgwebservices.com/Images/MobileApp/imges-info/my-vacceines/en/0.png', imageAr: 'https://hmgwebservices.com/Images/MobileApp/imges-info/my-vacceines/ar/0.png'), ], - body: Container( - margin: EdgeInsets.only(top: 20.0), + body: SingleChildScrollView( child: Column( children: [ AppExpandableNotifier( @@ -46,6 +45,7 @@ class _MyVaccinesState extends State { title: model.state == ViewState.Idle ? DateUtil.convertStringToDate(model.vaccineList[0].vaccinationDate).year.toString() : "", bodyWidget: Container( child: ListView.separated( + physics: ScrollPhysics(), scrollDirection: Axis.vertical, shrinkWrap: true, itemCount: model.vaccineList == null ? 0 : model.vaccineList.length, @@ -69,6 +69,7 @@ class _MyVaccinesState extends State { ), ), ), + SizedBox(height: 40.0,) // SpaceBetweenTexts(space: 165.0), ], ), diff --git a/lib/uitl/translations_delegate_base.dart b/lib/uitl/translations_delegate_base.dart index 032ad072..0043623d 100644 --- a/lib/uitl/translations_delegate_base.dart +++ b/lib/uitl/translations_delegate_base.dart @@ -2870,6 +2870,10 @@ class TranslationBase { String get paymentOnly => localizedValues["paymentOnly"][locale.languageCode]; String get pendingOnly => localizedValues["pendingOnly"][locale.languageCode]; String get insuranceRequestSubmit => localizedValues["insuranceRequestSubmit"][locale.languageCode]; + String get enterWorkplaceName => localizedValues["enter-workplace-name"][locale.languageCode]; + String get workplaceName => localizedValues["workplaceName"][locale.languageCode]; + String get needApproval => localizedValues["needApproval"][locale.languageCode]; + String get callLiveCareSupport => localizedValues["callLiveCareSupport"][locale.languageCode]; } diff --git a/lib/widgets/in_app_browser/InAppBrowser.dart b/lib/widgets/in_app_browser/InAppBrowser.dart index 47fc885b..3bdf50ce 100644 --- a/lib/widgets/in_app_browser/InAppBrowser.dart +++ b/lib/widgets/in_app_browser/InAppBrowser.dart @@ -41,10 +41,6 @@ class MyInAppBrowser extends InAppBrowser { static String SERVICE_URL = 'https://hmgwebservices.com/PayFortWebLive/pages/SendPayFortRequest.aspx'; //Payfort Payment Gateway URL LIVE - // static String PREAUTH_SERVICE_URL = 'https://hmgwebservices.com/PayFortWeb/pages/SendPayFortRequest.aspx'; // Payfort PreAuth Payment Gateway URL UAT - - static String PREAUTH_SERVICE_URL = 'https://hmgwebservices.com/PayFortWebLive/pages/SendPayFortRequest.aspx'; //Payfort PreAuth Payment Gateway URL Live Store - // static String PRESCRIPTION_PAYMENT_WITH_ORDERID = // 'https://uat.hmgwebservices.com/epharmacy/checkout/OpcCompleteRedirectionPaymentClientbyOrder?orderID='; @@ -300,9 +296,9 @@ class MyInAppBrowser extends InAppBrowser { form = form.replaceFirst('LATITUDE_VALUE', this.lat.toString()); form = form.replaceFirst('LONGITUDE_VALUE', this.long.toString()); - if (servID == "4") - form = form.replaceFirst('SERVICE_URL_VALUE', MyInAppBrowser.PREAUTH_SERVICE_URL); - else + // if (servID == "4") + // form = form.replaceFirst('SERVICE_URL_VALUE', MyInAppBrowser.PREAUTH_SERVICE_URL); + // else form = form.replaceFirst('SERVICE_URL_VALUE', MyInAppBrowser.SERVICE_URL); if (servID != null) {