From 8f20c7d021dc7e4c3cc05b7d173cb6c7282debb1 Mon Sep 17 00:00:00 2001 From: JiaSheng Date: Fri, 19 Jan 2024 21:45:07 +0800 Subject: [PATCH] update create booking payment with wallet logic --- .../Bookings/ControllersLogic/CreateBookingPaymentLogic.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/Classes/Modules/Bookings/ControllersLogic/CreateBookingPaymentLogic.php b/app/Classes/Modules/Bookings/ControllersLogic/CreateBookingPaymentLogic.php index 6cf63d39..e6b56f44 100644 --- a/app/Classes/Modules/Bookings/ControllersLogic/CreateBookingPaymentLogic.php +++ b/app/Classes/Modules/Bookings/ControllersLogic/CreateBookingPaymentLogic.php @@ -131,6 +131,10 @@ class CreateBookingPaymentLogic extends AbstractControllerLogic $this->updatesTransactionStatus->execute($transaction, ApprovalStatus::PENDING_VERIFICATION); } + if(PaymentMethodType::PAYMENT_METHODS[$request->input('payment_method')] == PaymentMethodType::WALLET){ + $this->updatesTransactionStatus->execute($transaction, ApprovalStatus::APPROVED); + } + return $this->resourceResponse(new TransactionResource($transaction)); }