From 83c05e1064adc01a1c030e40f775be8a955ebccb Mon Sep 17 00:00:00 2001 From: Jack Goh Date: Mon, 18 Jun 2018 11:18:21 +0800 Subject: [PATCH] update get calculation rate --- app/Http/Controllers/BookingController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Http/Controllers/BookingController.php b/app/Http/Controllers/BookingController.php index d0173377..179dfcb3 100644 --- a/app/Http/Controllers/BookingController.php +++ b/app/Http/Controllers/BookingController.php @@ -241,7 +241,7 @@ class BookingController extends Controller $amount = $request->input('amount'); $term = $request->input('term'); $china_beneficiary = $request->input('china_beneficiary'); - $rates = Rate::all()->last(); + $rates = Rate::orderby('updated_at','desc')->first(); // TODO : get marking $marking = "123X";