mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange.git
synced 2026-08-21 13:24:27 +00:00
added chinabankslip return on show booking query
updated upload po page with booking info, china bankslip and user bankslip
This commit is contained in:
@@ -134,9 +134,7 @@ class BookingController extends Controller
|
||||
$booking = Booking::where('user_id',Auth::user()->id)->where('id', $id)->first();
|
||||
// just added to try
|
||||
$user_bankslip = $booking->userBankSlip()->first();
|
||||
|
||||
|
||||
|
||||
$china_bankslip = $booking->chinaBankSlip()->first();
|
||||
|
||||
if($booking){
|
||||
|
||||
@@ -148,6 +146,10 @@ class BookingController extends Controller
|
||||
$date1 = new DateTime($user_bankslip->updated_at);
|
||||
}
|
||||
|
||||
if($china_bankslip){
|
||||
$booking->china_bankslip_path = Storage::url($china_bankslip->china_bank_slip_path);
|
||||
}
|
||||
|
||||
$date2 = new DateTime();
|
||||
$difference_in_seconds = ($date1->format('U') + 600) - ($date2->format('U'));
|
||||
|
||||
@@ -455,7 +457,7 @@ class BookingController extends Controller
|
||||
return response()->json(['user_po_path'=> $user_po->image_path ],200);
|
||||
}
|
||||
|
||||
return response()->json(['message'=> 'waiting customer to upload their po'],400);
|
||||
return response()->json(['message'=> 'waiting customer to upload their po'], 200);
|
||||
}
|
||||
|
||||
public function delete(Booking $book_id)
|
||||
|
||||
Reference in New Issue
Block a user