From 81e409c34548e9ba9fa27801a6f78e93b41b67f1 Mon Sep 17 00:00:00 2001 From: omair saleh Date: Wed, 2 Mar 2022 12:02:37 +0800 Subject: [PATCH] fix wallet bug --- .../Modules/Wallets/ControllersLogic/CreditWalletLogic.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Classes/Modules/Wallets/ControllersLogic/CreditWalletLogic.php b/app/Classes/Modules/Wallets/ControllersLogic/CreditWalletLogic.php index faccd38d..01859e4a 100644 --- a/app/Classes/Modules/Wallets/ControllersLogic/CreditWalletLogic.php +++ b/app/Classes/Modules/Wallets/ControllersLogic/CreditWalletLogic.php @@ -107,9 +107,9 @@ class CreditWalletLogic extends AbstractControllerLogic $transaction = $this->createsTransaction->execute($wallet, $transaction_object); $updateWalletAmount = $type === 2 ? ($wallet->amount - $transaction->amount) : ($wallet->amount + $transaction->amount); - + dd($wallet->company); $walletObject = new WalletObject($wallet->company->id, $wallet->currency_id, $wallet->code, $updateWalletAmount); - dd($walletObject); + $wallet = $this->updatesWallet->execute($wallet, $walletObject); return $this->resourceResponse(new WalletResource($wallet));