fix generate invoice

This commit is contained in:
edmondlang
2023-07-03 10:06:09 +08:00
parent b8cfbba0ad
commit be3111400c
+4 -1
View File
@@ -175,7 +175,10 @@
<td class="right middle">Total</td>
<td class="total right middle">
@if($transaction->booking()->first()->fix_currency_id !== 1)
{{ number_format( number_format($subtotal, 2) + $transaction->service_charge + $transaction->tax + $voucher_discount, 2) }}
@php
$rounded_subtotal = number_format($subtotal, 2);
@endphp
{{ number_format($rounded_subtotal + $transaction->service_charge + $transaction->tax + $voucher_discount, 2) }}
@else
{{ number_format($transaction->amount + $transaction->service_charge + $transaction->tax + $voucher_discount, 2) }}
@endif