diff --git a/app/Http/Controllers/Backend/CalendarController.php b/app/Http/Controllers/Backend/CalendarController.php index 77006c8..d5474e3 100644 --- a/app/Http/Controllers/Backend/CalendarController.php +++ b/app/Http/Controllers/Backend/CalendarController.php @@ -47,7 +47,9 @@ public function __construct(CalendarRepository $calendarRepository, EventsReposi public function index(): View { return view('backend.calendar.index', [ - 'events' => $this->eventRepository->entity()->with(['dates'])->simplePaginate(15), + 'events' => $this->eventRepository->entity()->with(['dates'=> function ($query) { + $query->orderBy('start_date', 'DESC'); + }])->simplePaginate(15), ]); }