mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange.git
synced 2026-08-19 12:24:09 +00:00
admin user bookings
This commit is contained in:
@@ -190,12 +190,23 @@ class BookingController extends Controller
|
||||
public function adminIndex(?string $userId = null){
|
||||
$user = Auth::user();
|
||||
$bookings = Booking::UserBooking($userId)->select('user_id', 'id', 'created_at', 'admin_status', 'rate', 'term', 'amount', 'bia', 'verification_status')
|
||||
->where('admin_status', '<', '6')
|
||||
->orwhere(function ($query) {
|
||||
$query->where('admin_status', '=', '6')
|
||||
->where('term', '!=', 'x2_cheque')
|
||||
->where('term', '!=', 'x2_ba')
|
||||
->where('term', '!=', 'x2_cash');
|
||||
->where(function ($query) {
|
||||
$query->where(function ($query) {
|
||||
$query->where('admin_status', '<', '6')
|
||||
->where(function ($query) {
|
||||
$query->where('term', 'x2_cash')
|
||||
->orwhere('term', 'x2_cheque')
|
||||
->orwhere('term', 'x2_ba');
|
||||
});
|
||||
})
|
||||
->orwhere(function ($query) {
|
||||
$query->where('status', '<', '7')
|
||||
->where(function ($query) {
|
||||
$query->where('term', 'x1_cash')
|
||||
->orwhere('term', 'x1_cheque')
|
||||
->orwhere('term', 'x1_ba');
|
||||
});
|
||||
});
|
||||
})
|
||||
->orderby('updated_at','desc')
|
||||
->paginate(30);
|
||||
|
||||
Reference in New Issue
Block a user