Merge branch 'vapor/production' of https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0 into vapor/development

This commit is contained in:
Edmond Lang
2025-07-15 14:25:05 +08:00
2 changed files with 4 additions and 1 deletions
@@ -34,4 +34,7 @@ class CalculatesBookingOutstanding
return $booking->fix_amount - $this->calculatesBookingFloatingAmount->execute($booking, $booking->fix_currency_id) - $this->calculatesBookingPayableAmount->execute($booking, $booking->fix_currency_id) + $this->calculatesBookingRefundAmount->execute($booking, $booking->fix_currency_id);
}
public function executeWithoutFloatingAmount(Booking $booking){
return $booking->fix_amount - $this->calculatesBookingPayableAmount->execute($booking, $booking->fix_currency_id) + $this->calculatesBookingRefundAmount->execute($booking, $booking->fix_currency_id);
}
}
@@ -113,7 +113,7 @@ class CalculatesTransactionExpiryDateTime
private function getNewBookingExpiresAt2($booking, $paymentAttemptLimit){
$newBookingExpiresAt = null;
$amountOutstanding = $this->calculatesBookingOutstanding->execute($booking);
$amountOutstanding = $this->calculatesBookingOutstanding->executeWithoutFloatingAmount($booking);
$amountPaid = $this->calculatesBookingPaidAmount->execute($booking);
if($amountPaid > 0.01 && $amountOutstanding > 0){
$newBookingExpiresAt = Carbon::now()->addMinutes($paymentAttemptLimit);