Sort flights by flight_number
This commit is contained in:
@@ -127,7 +127,10 @@ class FlightController extends Controller
|
|||||||
*/
|
*/
|
||||||
public function index(Request $request)
|
public function index(Request $request)
|
||||||
{
|
{
|
||||||
$flights = $this->flightRepo->searchCriteria($request, false)->paginate();
|
$flights = $this->flightRepo
|
||||||
|
->searchCriteria($request, false)
|
||||||
|
->orderBy('flight_number', 'asc')
|
||||||
|
->paginate();
|
||||||
|
|
||||||
return view('admin.flights.index', [
|
return view('admin.flights.index', [
|
||||||
'flights' => $flights,
|
'flights' => $flights,
|
||||||
|
|||||||
@@ -65,7 +65,9 @@ class FlightController extends Controller
|
|||||||
Log::emergency($e);
|
Log::emergency($e);
|
||||||
}
|
}
|
||||||
|
|
||||||
$flights = $this->flightRepo->paginate();
|
$flights = $this->flightRepo
|
||||||
|
->orderBy('flight_number', 'asc')
|
||||||
|
->paginate();
|
||||||
|
|
||||||
$saved_flights = Bid::where('user_id', Auth::id())
|
$saved_flights = Bid::where('user_id', Auth::id())
|
||||||
->pluck('flight_id')->toArray();
|
->pluck('flight_id')->toArray();
|
||||||
|
|||||||
Reference in New Issue
Block a user