|
|
|
|
@ -1,4 +1,3 @@
|
|
|
|
|
|
|
|
|
|
import 'dart:io';
|
|
|
|
|
|
|
|
|
|
import 'package:easy_localization/easy_localization.dart';
|
|
|
|
|
@ -185,7 +184,8 @@ class ImmediateLiveCarePaymentDetails extends StatelessWidget {
|
|
|
|
|
children: [
|
|
|
|
|
LocaleKeys.amountBeforeTax.tr(context: context).toText14(isBold: true),
|
|
|
|
|
Utils.getPaymentAmountWithSymbol(immediateLiveCareVM.liveCareImmediateAppointmentFeesList.amount!.toText16(isBold: true), AppColors.blackColor, 13,
|
|
|
|
|
isSaudiCurrency: immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "sar" || immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "ريال"),
|
|
|
|
|
isSaudiCurrency: immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "sar" ||
|
|
|
|
|
immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "ريال"),
|
|
|
|
|
],
|
|
|
|
|
).paddingSymmetrical(24.h, 0.h),
|
|
|
|
|
Row(
|
|
|
|
|
@ -194,7 +194,8 @@ class ImmediateLiveCarePaymentDetails extends StatelessWidget {
|
|
|
|
|
LocaleKeys.vat15.tr(context: context).toText14(isBold: true, color: AppColors.greyTextColor),
|
|
|
|
|
Utils.getPaymentAmountWithSymbol(
|
|
|
|
|
immediateLiveCareVM.liveCareImmediateAppointmentFeesList.tax!.toText14(isBold: true, color: AppColors.greyTextColor), AppColors.greyTextColor, 13,
|
|
|
|
|
isSaudiCurrency: (immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "sar" || immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "ريال")),
|
|
|
|
|
isSaudiCurrency: (immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "sar" ||
|
|
|
|
|
immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "ريال")),
|
|
|
|
|
],
|
|
|
|
|
).paddingSymmetrical(24.h, 0.h),
|
|
|
|
|
SizedBox(height: 17.h),
|
|
|
|
|
@ -203,7 +204,8 @@ class ImmediateLiveCarePaymentDetails extends StatelessWidget {
|
|
|
|
|
children: [
|
|
|
|
|
SizedBox(width: 150.h, child: Utils.getPaymentMethods()),
|
|
|
|
|
Utils.getPaymentAmountWithSymbol(immediateLiveCareVM.liveCareImmediateAppointmentFeesList.total!.toText24(isBold: true), AppColors.blackColor, 17,
|
|
|
|
|
isSaudiCurrency: (immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "sar" || immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "ريال")),
|
|
|
|
|
isSaudiCurrency: (immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "sar" ||
|
|
|
|
|
immediateLiveCareVM.liveCareImmediateAppointmentFeesList.currency!.toLowerCase() == "ريال")),
|
|
|
|
|
],
|
|
|
|
|
).paddingSymmetrical(24.h, 0.h),
|
|
|
|
|
(immediateLiveCareVM.liveCareImmediateAppointmentFeesList.total == "0" || immediateLiveCareVM.liveCareImmediateAppointmentFeesList.total == "0.0")
|
|
|
|
|
@ -214,18 +216,16 @@ class ImmediateLiveCarePaymentDetails extends StatelessWidget {
|
|
|
|
|
if (val) {
|
|
|
|
|
LoaderBottomSheet.showLoader(loadingText: LocaleKeys.confirmingLiveCareRequest.tr(context: context));
|
|
|
|
|
|
|
|
|
|
await immediateLiveCareVM.addNewCallRequestForImmediateLiveCare("${appState.getAuthenticatedUser()!.patientId}${DateTime
|
|
|
|
|
.now()
|
|
|
|
|
.millisecondsSinceEpoch}");
|
|
|
|
|
await immediateLiveCareVM.getPatientLiveCareHistory();
|
|
|
|
|
LoaderBottomSheet.hideLoader();
|
|
|
|
|
if (immediateLiveCareVM.patientHasPendingLiveCareRequest) {
|
|
|
|
|
Navigator.pushAndRemoveUntil(
|
|
|
|
|
context,
|
|
|
|
|
CustomPageRoute(
|
|
|
|
|
page: LandingNavigation(),
|
|
|
|
|
),
|
|
|
|
|
(r) => false);
|
|
|
|
|
await immediateLiveCareVM.addNewCallRequestForImmediateLiveCare("${appState.getAuthenticatedUser()!.patientId}${DateTime.now().millisecondsSinceEpoch}");
|
|
|
|
|
await immediateLiveCareVM.getPatientLiveCareHistory();
|
|
|
|
|
LoaderBottomSheet.hideLoader();
|
|
|
|
|
if (immediateLiveCareVM.patientHasPendingLiveCareRequest) {
|
|
|
|
|
Navigator.pushAndRemoveUntil(
|
|
|
|
|
context,
|
|
|
|
|
CustomPageRoute(
|
|
|
|
|
page: LandingNavigation(),
|
|
|
|
|
),
|
|
|
|
|
(r) => false);
|
|
|
|
|
Navigator.of(context).push(
|
|
|
|
|
CustomPageRoute(
|
|
|
|
|
page: ImmediateLiveCarePendingRequestPage(),
|
|
|
|
|
|