|
|
|
|
@ -268,7 +268,6 @@ class _BookSuccessState extends State<BookSuccess> {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
Widget getNextActionWidget() {
|
|
|
|
|
print(widget.patientShareResponse.nextAction);
|
|
|
|
|
switch (widget.patientShareResponse.nextAction) {
|
|
|
|
|
case 0:
|
|
|
|
|
return Container();
|
|
|
|
|
@ -483,7 +482,6 @@ class _BookSuccessState extends State<BookSuccess> {
|
|
|
|
|
appo.appointmentNo = widget.patientShareResponse.appointmentNo;
|
|
|
|
|
|
|
|
|
|
Navigator.push(context, FadePage(page: PaymentMethod())).then((value) {
|
|
|
|
|
print(value);
|
|
|
|
|
if (value != null) {
|
|
|
|
|
openPayment(value, authUser, double.parse(patientShareResponse.patientShareWithTax.toString()), patientShareResponse, appo);
|
|
|
|
|
}
|
|
|
|
|
@ -519,7 +517,6 @@ class _BookSuccessState extends State<BookSuccess> {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
onBrowserLoadStart(String url) {
|
|
|
|
|
print("onBrowserLoadStart");
|
|
|
|
|
print(url);
|
|
|
|
|
|
|
|
|
|
MyInAppBrowser.successURLS.forEach((element) {
|
|
|
|
|
@ -540,7 +537,6 @@ class _BookSuccessState extends State<BookSuccess> {
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
onBrowserExit(AppoitmentAllHistoryResultList appo, bool isPaymentMade) {
|
|
|
|
|
print("onBrowserExit Called!!!!");
|
|
|
|
|
if (isPaymentMade) checkPaymentStatus(appo);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@ -548,8 +544,7 @@ class _BookSuccessState extends State<BookSuccess> {
|
|
|
|
|
GifLoaderDialogUtils.showMyDialog(context);
|
|
|
|
|
DoctorsListService service = new DoctorsListService();
|
|
|
|
|
service.checkPaymentStatus(Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo), context).then((res) {
|
|
|
|
|
print("Printing Payment Status Reponse!!!!");
|
|
|
|
|
print(res);
|
|
|
|
|
|
|
|
|
|
String paymentInfo = res['Response_Message'];
|
|
|
|
|
if (paymentInfo == 'Success') {
|
|
|
|
|
createAdvancePayment(res, appo);
|
|
|
|
|
@ -569,8 +564,7 @@ class _BookSuccessState extends State<BookSuccess> {
|
|
|
|
|
DoctorsListService service = new DoctorsListService();
|
|
|
|
|
service.checkPaymentStatus(Utils.getAppointmentTransID(appo.projectID, appo.clinicID, appo.appointmentNo), context).then((res) {
|
|
|
|
|
GifLoaderDialogUtils.hideDialog(context);
|
|
|
|
|
print("Printing Payment Status Reponse!!!!");
|
|
|
|
|
print(res);
|
|
|
|
|
|
|
|
|
|
String paymentInfo = res['Response_Message'];
|
|
|
|
|
if (paymentInfo == 'Success') {
|
|
|
|
|
createAdvancePayment(res, appo);
|
|
|
|
|
@ -588,7 +582,6 @@ class _BookSuccessState extends State<BookSuccess> {
|
|
|
|
|
DoctorsListService service = new DoctorsListService();
|
|
|
|
|
String paymentReference = res['Fort_id'].toString();
|
|
|
|
|
service.createAdvancePayment(appo, appo.projectID.toString(), res['Amount'], res['Fort_id'], res['PaymentMethod'], context).then((res) {
|
|
|
|
|
print(res['OnlineCheckInAppointments'][0]['AdvanceNumber']);
|
|
|
|
|
addAdvancedNumberRequest(res['OnlineCheckInAppointments'][0]['AdvanceNumber'].toString(), paymentReference, appo.appointmentNo.toString());
|
|
|
|
|
}).catchError((err) {
|
|
|
|
|
GifLoaderDialogUtils.hideDialog(context);
|
|
|
|
|
|