diff --git a/lib/pages/InPatientServices/components/inpatient_paid_advance_payment.dart b/lib/pages/InPatientServices/components/inpatient_paid_advance_payment.dart index 0a7bf878..460c7309 100644 --- a/lib/pages/InPatientServices/components/inpatient_paid_advance_payment.dart +++ b/lib/pages/InPatientServices/components/inpatient_paid_advance_payment.dart @@ -34,7 +34,7 @@ class _InPatientPaidAdvancePaymentState extends State createState() => _InPatientPendingAdvancePaymentState(); @@ -57,93 +58,95 @@ class _InPatientPendingAdvancePaymentState extends State createState() => _InPatientAdvancePaymentState(); @@ -67,7 +65,7 @@ class _InPatientAdvancePaymentState extends State with physics: BouncingScrollPhysics(), controller: _tabController, children: [ - InPatientPendingAdvancePayment(inPatientAdvanceResponseModel: widget.inPatientAdvanceResponseModel), + InPatientPendingAdvancePayment(isHasData: widget.isHasData, inPatientAdvanceResponseModel: widget.inPatientAdvanceResponseModel), InPatientPaidAdvancePayment(), ], ), diff --git a/lib/pages/InPatientServices/inpatient_home.dart b/lib/pages/InPatientServices/inpatient_home.dart index 2dafde6e..ff1ae40d 100644 --- a/lib/pages/InPatientServices/inpatient_home.dart +++ b/lib/pages/InPatientServices/inpatient_home.dart @@ -336,12 +336,14 @@ class _InPatientServicesHomeState extends State { if (res["MessageStatus"] == 1) { if (res['responseInpatient'] != null) { inPatientAdvanceResponseModel = InPatientAdvanceResponseModel.fromJson(res["responseInpatient"]); - Navigator.push(context, FadePage(page: InPatientAdvancePayment(inPatientAdvanceResponseModel: inPatientAdvanceResponseModel))); + Navigator.push(context, FadePage(page: InPatientAdvancePayment(isHasData: true, inPatientAdvanceResponseModel: inPatientAdvanceResponseModel))); } else { + // Navigator.push(context, FadePage(page: InPatientAdvancePayment(isHasData: false, inPatientAdvanceResponseModel: inPatientAdvanceResponseModel))); AppToast.showErrorToast(message: TranslationBase.of(context).noData); } } else { - AppToast.showErrorToast(message: res["endUserMessage"]); + // AppToast.showErrorToast(message: res["ErrorEndUserMessage"]); + Navigator.push(context, FadePage(page: InPatientAdvancePayment(isHasData: false, inPatientAdvanceResponseModel: inPatientAdvanceResponseModel))); } }).catchError((err) { GifLoaderDialogUtils.hideDialog(context); diff --git a/lib/pages/login/confirm-login.dart b/lib/pages/login/confirm-login.dart index 3af64363..b4591886 100644 --- a/lib/pages/login/confirm-login.dart +++ b/lib/pages/login/confirm-login.dart @@ -636,8 +636,8 @@ class _ConfirmLogin extends State { loginTokenID = result.logInTokenID, sharedPref.setObject(LOGIN_TOKEN_ID, result.logInTokenID), sharedPref.setString(TOKEN, result.authenticationTokenID), - checkIfUserAgreedBefore(result), projectViewModel.analytics.loginRegistration.login_successful(), + checkIfUserAgreedBefore(result), } } else @@ -668,7 +668,6 @@ class _ConfirmLogin extends State { if (result.isNeedUserAgreement == true) { //move to agreement page. } else { - checkIfIsInPatient(); goToHome(); } } @@ -736,6 +735,7 @@ class _ConfirmLogin extends State { .getIsLastAppointmentRatedList() .then((value) => { getToDoCount(), + checkIfIsInPatient(), GifLoaderDialogUtils.hideDialog(AppGlobal.context), if (appointmentRateViewModel.isHaveAppointmentNotRate) {