mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0.git
synced 2026-08-22 05:53:58 +00:00
Merge branch 'vapor/production' of https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0 into vapor/development
This commit is contained in:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user