fix bug with amount not matching

This commit is contained in:
omair saleh
2020-09-29 17:18:12 +08:00
parent 5c5f7c5828
commit df3972cf54
+1 -1
View File
@@ -99,7 +99,7 @@ class InvoiceController extends Controller
$adjustment = $request->adjustment;
$billing_charges = $booking->billing_charge;
$total = $subtotal + $adjustment + $billing_charges;
echo dd(abs($total-$booking->bia));
if (abs($total-$booking->bia) < PHP_FLOAT_EPSILON) {
return response()->json([
'message' => 'Booking amount expected is '.$booking->bia.'. Your Invoice amount is '.$total