diff --git a/app/Classes/Jobs/UpdatePerfexCRMPrelude.php b/app/Classes/Jobs/UpdatePerfexCRMPrelude.php index 1bf9dede..d9fd5961 100644 --- a/app/Classes/Jobs/UpdatePerfexCRMPrelude.php +++ b/app/Classes/Jobs/UpdatePerfexCRMPrelude.php @@ -41,7 +41,7 @@ class UpdatePerfexCRMPrelude implements ShouldQueue { $serviceTypeName = $this->transaction->owner->company->services()->where('id', $this->transaction->owner->service_id)->first()->name; $booking = $this->transaction->booking; - $bank = $booking->bank; //cief todo: 66 + $bank = $booking->bank; if($this->transaction->bank){ $bank = $this->transaction->bank; } diff --git a/app/Classes/Modules/Exports/Services/ExportsAnalyticBillingTransactions.php b/app/Classes/Modules/Exports/Services/ExportsAnalyticBillingTransactions.php index 093997d3..e60d6120 100644 --- a/app/Classes/Modules/Exports/Services/ExportsAnalyticBillingTransactions.php +++ b/app/Classes/Modules/Exports/Services/ExportsAnalyticBillingTransactions.php @@ -70,7 +70,7 @@ class ExportsAnalyticBillingTransactions implements FromCollection, WithHeadings $bill = $transaction; $payment = $transaction->owner; $booking = $payment->owner; - $bank = $booking->bank; //cief todo: 66 + $bank = $booking->bank; if($payment->bank){ $bank = $payment->bank; } diff --git a/app/Http/Resources/PaymentTransactionResource.php b/app/Http/Resources/PaymentTransactionResource.php index 01da84b2..3f9ac491 100644 --- a/app/Http/Resources/PaymentTransactionResource.php +++ b/app/Http/Resources/PaymentTransactionResource.php @@ -18,7 +18,7 @@ class PaymentTransactionResource extends JsonResource */ public function toArray($request) { - $booking = null; //cief todo: 66 + $booking = null; $bank = null; //Check if Transaction of type PAYMENT has an override for recipient bank - starts if(in_array((int)$this->type, [TransactionType::BILL, TransactionType::REFUND])){ diff --git a/app/Http/Resources/TransactionResource.php b/app/Http/Resources/TransactionResource.php index c2d20a85..4271f030 100644 --- a/app/Http/Resources/TransactionResource.php +++ b/app/Http/Resources/TransactionResource.php @@ -19,7 +19,7 @@ class TransactionResource extends JsonResource */ public function toArray($request) { - $booking = null; //cief todo: 66 + $booking = null; $bank = null; //Check if Transaction of type PAYMENT has an override for recipient bank - starts diff --git a/app/Http/Resources/TransactionUrgentResource.php b/app/Http/Resources/TransactionUrgentResource.php index 04edd0d1..ca3b98b4 100644 --- a/app/Http/Resources/TransactionUrgentResource.php +++ b/app/Http/Resources/TransactionUrgentResource.php @@ -19,7 +19,7 @@ class TransactionUrgentResource extends JsonResource */ public function toArray($request) { - $booking = null; //cief todo: 66 + $booking = null; $bank = null; //Check if Transaction of type PAYMENT has an override for recipient bank - starts if(in_array((int)$this->type, [TransactionType::BILL, TransactionType::REFUND, TransactionType::SUPPLIER_REFUND])){ diff --git a/app/Http/Resources/V2/ListTransactionJobResource.php b/app/Http/Resources/V2/ListTransactionJobResource.php index 6a0f23d3..e7e4a3cc 100644 --- a/app/Http/Resources/V2/ListTransactionJobResource.php +++ b/app/Http/Resources/V2/ListTransactionJobResource.php @@ -18,7 +18,7 @@ class ListTransactionJobResource extends JsonResource */ public function toArray($request) { - $booking = null; //cief todo: 66 + $booking = null; $bank = null; //Check if Transaction of type PAYMENT has an override for recipient bank - starts if(in_array((int)$this->type, [TransactionType::BILL, TransactionType::REFUND])){ diff --git a/resources/assets/vue/components/bookings/forms/BookingPaymentQuotationComponent.vue b/resources/assets/vue/components/bookings/forms/BookingPaymentQuotationComponent.vue index 9208852c..5f77e1d4 100644 --- a/resources/assets/vue/components/bookings/forms/BookingPaymentQuotationComponent.vue +++ b/resources/assets/vue/components/bookings/forms/BookingPaymentQuotationComponent.vue @@ -684,9 +684,6 @@ this.calculation = null; this.expandPayment = false; }, - // updatedBankDetails(bank){ //cief todo: 66 - this need to move to vuex, too many levels of passings between parent and child - // this.item.bank = bank; - // }, removeVoucher(){ this.voucherCodeFailedReason = ''; this.voucherCode = ''; diff --git a/routes/web.php b/routes/web.php index 5631bfb4..cf352dd6 100644 --- a/routes/web.php +++ b/routes/web.php @@ -37,6 +37,8 @@ use App\Classes\Modules\Transactions\Services\DeletesTransaction; use Illuminate\Support\Facades\DB; use Illuminate\Support\Facades\Log; use App\Classes\General\AWSS3Helper; +use Illuminate\Support\Facades\File; + /* |-------------------------------------------------------------------------- @@ -427,7 +429,7 @@ Route::get('/pending_orders', function(){ $i = 0; foreach ($payments as $payment){ $booking = $payment->owner; - $bank = $payment->bank ?? $booking->bank; //cief todo: 66 + $bank = $payment->bank ?? $booking->bank; $original_refunds = floatval((App()->make(CalculatesBookingRefundAmount::class))->calculateRefundAmount($payment, $booking->fix_currency_id)); $refunds = $original_refunds / $payment->currency_rate; @@ -532,7 +534,7 @@ Route::get('/approve_refunds', function(Request $request){ foreach ($approve_refunds->orderBy('created_at', 'DESC')->get() as $index => $refund){ $payment = $refund->owner; $booking = $refund->owner->owner; - $bank = $payment->bank ?? $booking->bank; //cief todo: 66 + $bank = $payment->bank ?? $booking->bank; if(!$booking instanceof Booking){ dd($refund); @@ -588,7 +590,7 @@ Route::get('/group/text/{id}', function($id){ foreach ($group->transactions as $transaction){ $i++; $booking = $transaction->owner->owner; - $bank = $transaction->owner->bank ?? $booking->bank; //cief todo: 66 + $bank = $transaction->owner->bank ?? $booking->bank; echo 'No.'.$i.'
'; echo 'Bank Details:'.$bank->holder_name.'
';