E-Cens sign off

merge-update-with-lab-changes
haroon amjad 4 years ago
parent 4cbccd8efb
commit 7018696328

@ -274,10 +274,10 @@ class Appointment{
// R053 // R053
// Note : - Payment flow beyond this step are same as listed under Advance Payment section of this document // Note : - Payment flow beyond this step are same as listed under Advance Payment section of this document
appointment_details_cancel({@required AppoitmentAllHistoryResultList appointment}){ appointment_details_cancel({@required AppoitmentAllHistoryResultList appointment, appointment_type}){
logger('cancel_appointment', parameters: { logger('cancel_appointment', parameters: {
'flow_type' : GAnalytics.APPOINTMENT_DETAIL_FLOW_TYPE, 'flow_type' : GAnalytics.APPOINTMENT_DETAIL_FLOW_TYPE,
'appointment_type' : appointment.appointmentType, 'appointment_type' : appointment_type,
'clinic_type_online' : appointment.clinicName, 'clinic_type_online' : appointment.clinicName,
'hospital_name' : appointment.projectName, 'hospital_name' : appointment.projectName,
'doctor_name' : (appointment.doctorName == null || appointment.doctorName == '') ? appointment.doctorNameObj : appointment.doctorName 'doctor_name' : (appointment.doctorName == null || appointment.doctorName == '') ? appointment.doctorNameObj : appointment.doctorName

@ -20,8 +20,8 @@ var PACKAGES_ORDERS = '/api/orders';
var PACKAGES_ORDER_HISTORY = '/api/orders/items'; var PACKAGES_ORDER_HISTORY = '/api/orders/items';
var PACKAGES_TAMARA_OPT = '/api/orders/paymentoptions/tamara'; var PACKAGES_TAMARA_OPT = '/api/orders/paymentoptions/tamara';
// var BASE_URL = 'http://10.50.100.198:3334/'; // var BASE_URL = 'http://10.50.100.198:3334/';
var BASE_URL = 'https://uat.hmgwebservices.com/'; // var BASE_URL = 'https://uat.hmgwebservices.com/';
// var BASE_URL = 'https://hmgwebservices.com/'; var BASE_URL = 'https://hmgwebservices.com/';
// Pharmacy UAT URLs // Pharmacy UAT URLs
// var BASE_PHARMACY_URL = 'https://uat.hmgwebservices.com/epharmacy/api/'; // var BASE_PHARMACY_URL = 'https://uat.hmgwebservices.com/epharmacy/api/';

@ -46,6 +46,7 @@ class _BookSuccessState extends State<BookSuccess> {
AuthenticatedUser authUser; AuthenticatedUser authUser;
ProjectViewModel projectViewModel; ProjectViewModel projectViewModel;
String selectedPaymentMethod = "";
@override @override
initState() { initState() {
@ -546,7 +547,7 @@ class _BookSuccessState extends State<BookSuccess> {
openPayment(List<String> paymentMethod, AuthenticatedUser authenticatedUser, double amount, PatientShareResponse patientShareResponse, AppoitmentAllHistoryResultList appo) async { openPayment(List<String> paymentMethod, AuthenticatedUser authenticatedUser, double amount, PatientShareResponse patientShareResponse, AppoitmentAllHistoryResultList appo) async {
widget.browser = new MyInAppBrowser(onExitCallback: onBrowserExit, appo: appo, onLoadStartCallback: onBrowserLoadStart, context: context); widget.browser = new MyInAppBrowser(onExitCallback: onBrowserExit, appo: appo, onLoadStartCallback: onBrowserLoadStart, context: context);
selectedPaymentMethod = paymentMethod[0];
widget.browser.openPaymentBrowser( widget.browser.openPaymentBrowser(
amount, amount,
"Appointment check in", "Appointment check in",
@ -615,10 +616,10 @@ class _BookSuccessState extends State<BookSuccess> {
AppToast.showErrorToast(message: res['Response_Message']); AppToast.showErrorToast(message: res['Response_Message']);
projectViewModel.analytics.appointment.payment_fail( projectViewModel.analytics.appointment.payment_fail(
appointment_type: 'regular', appointment_type: 'regular',
payment_method: payment_method, payment_method: selectedPaymentMethod,
clinic: appo.clinicName, clinic: appo.clinicName,
hospital: appo.projectName, hospital: appo.projectName,
txn_amount: "$amount", txn_amount: widget.patientShareResponse.patientShareWithTax.toString(),
txn_currency: currency, txn_currency: currency,
error_type: res['Response_Message']); error_type: res['Response_Message']);
} }

@ -614,7 +614,7 @@ class _AppointmentDetailsState extends State<AppointmentDetails> with SingleTick
} else { } else {
AppToast.showErrorToast(message: res['ErrorEndUserMessage']); AppToast.showErrorToast(message: res['ErrorEndUserMessage']);
} }
projectViewModel.analytics.appointment.appointment_details_cancel(appointment: widget.appo); projectViewModel.analytics.appointment.appointment_details_cancel(appointment: widget.appo, appointment_type: widget.appo.isLiveCareAppointment ? "livecare" : "regular");
}).catchError((err) { }).catchError((err) {
GifLoaderDialogUtils.hideDialog(context); GifLoaderDialogUtils.hideDialog(context);
print(err); print(err);

@ -895,15 +895,32 @@ class _ToDoState extends State<ToDo> with SingleTickerProviderStateMixin {
} }
checkPaymentStatus(AppoitmentAllHistoryResultList appo) { checkPaymentStatus(AppoitmentAllHistoryResultList appo) {
String txn_ref;
String amount;
String payment_method;
final currency = projectViewModel.user.outSA == 0 ? "sar" : 'aed';
GifLoaderDialogUtils.showMyDialog(context); GifLoaderDialogUtils.showMyDialog(context);
DoctorsListService service = new DoctorsListService(); DoctorsListService service = new DoctorsListService();
service.checkPaymentStatus(Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo), context).then((res) { service.checkPaymentStatus(Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo), context).then((res) {
GifLoaderDialogUtils.hideDialog(context); GifLoaderDialogUtils.hideDialog(context);
String paymentInfo = res['Response_Message']; String paymentInfo = res['Response_Message'];
if (paymentInfo == 'Success') { if (paymentInfo == 'Success') {
txn_ref = res['Merchant_Reference'];
amount = res['Amount'];
payment_method = res['PaymentMethod'];
createAdvancePayment(res, appo); createAdvancePayment(res, appo);
projectViewModel.analytics.appointment.payment_success(
appointment_type: 'regular', payment_method: payment_method, clinic: appo.clinicName, hospital: appo.projectName, txn_amount: "$amount", txn_currency: currency, txn_number: txn_ref);
} else { } else {
AppToast.showErrorToast(message: res['Response_Message']); AppToast.showErrorToast(message: res['Response_Message']);
projectViewModel.analytics.appointment.payment_fail(
appointment_type: 'regular',
payment_method: payment_method,
clinic: appo.clinicName,
hospital: appo.projectName,
txn_amount: "$amount",
txn_currency: currency,
error_type: res['Response_Message']);
} }
}).catchError((err) { }).catchError((err) {
GifLoaderDialogUtils.hideDialog(context); GifLoaderDialogUtils.hideDialog(context);

@ -42,6 +42,7 @@ import 'package:provider/provider.dart';
class ConfirmLogin extends StatefulWidget { class ConfirmLogin extends StatefulWidget {
final Function changePageViewIndex; final Function changePageViewIndex;
final fromRegistration; final fromRegistration;
const ConfirmLogin({Key key, this.changePageViewIndex, this.fromRegistration = false}) : super(key: key); const ConfirmLogin({Key key, this.changePageViewIndex, this.fromRegistration = false}) : super(key: key);
@override @override
@ -301,6 +302,7 @@ class _ConfirmLogin extends State<ConfirmLogin> {
} }
int login_method = 0; int login_method = 0;
authenticateUser(int type, {int isActive}) { authenticateUser(int type, {int isActive}) {
GifLoaderDialogUtils.showMyDialog(context); GifLoaderDialogUtils.showMyDialog(context);
if (type == 2 || type == 3) { if (type == 2 || type == 3) {
@ -310,8 +312,8 @@ class _ConfirmLogin extends State<ConfirmLogin> {
login_method = type; login_method = type;
LoginRegistration.verificationMethod = type; LoginRegistration.verificationMethod = type;
if(!widget.fromRegistration) // if(!widget.fromRegistration)
projectViewModel.analytics.loginRegistration.login_verfication(forRegistration: widget.fromRegistration); projectViewModel.analytics.loginRegistration.login_verfication(forRegistration: widget.fromRegistration);
switch (type) { switch (type) {
case 1: case 1:

@ -57,7 +57,7 @@ class PrescriptionItemsPage extends StatelessWidget {
"", "",
prescriptions.name, prescriptions.name,
DateUtil.convertStringToDate(prescriptions.appointmentDate), DateUtil.convertStringToDate(prescriptions.appointmentDate),
DateUtil.formatDateToTime(DateUtil.convertStringToDate(model.prescriptionReportEnhList[0].orderDate)), DateUtil.formatDateToTime(DateUtil.convertStringToDate(model.prescriptionReportEnhList.length > 0 ? model.prescriptionReportEnhList[0].orderDate : model.prescriptionReportListINP[0].orderDate)),
prescriptions.nationalityFlagURL, prescriptions.nationalityFlagURL,
prescriptions.doctorRate, prescriptions.doctorRate,
prescriptions.actualDoctorRate, prescriptions.actualDoctorRate,

@ -37,13 +37,13 @@ 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 LIVE
static String APPLE_PAY_PAYFORT_URL = 'https://hmgwebservices.com/PayFortWebLive/PayFortApi/MakeApplePayRequest'; // Payfort Payment Gateway URL UAT 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 PREAUTH_SERVICE_URL = 'https://hmgwebservices.com/PayFortWeb/pages/SendPayFortRequest.aspx'; // Payfort PreAuth Payment Gateway URL UAT // 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 PREAUTH_SERVICE_URL = 'https://hmgwebservices.com/PayFortWebLive/pages/SendPayFortRequest.aspx'; //Payfort PreAuth Payment Gateway URL Live Store
// static String PRESCRIPTION_PAYMENT_WITH_ORDERID = // static String PRESCRIPTION_PAYMENT_WITH_ORDERID =
// 'https://uat.hmgwebservices.com/epharmacy/checkout/OpcCompleteRedirectionPaymentClientbyOrder?orderID='; // 'https://uat.hmgwebservices.com/epharmacy/checkout/OpcCompleteRedirectionPaymentClientbyOrder?orderID=';

@ -202,8 +202,6 @@ dependencies:
sms_otp_auto_verify: ^2.1.0 sms_otp_auto_verify: ^2.1.0
flutter_ios_voip_kit: ^0.0.5 flutter_ios_voip_kit: ^0.0.5
# payfort_plugin: ^0.3.1
dependency_overrides: dependency_overrides:
provider : ^5.0.0 provider : ^5.0.0
permission_handler : ^6.0.1+1 permission_handler : ^6.0.1+1

Loading…
Cancel
Save