From fb58e1db77aa7cb6c03b4337cc7467ccf59b2440 Mon Sep 17 00:00:00 2001 From: Luca Date: Tue, 14 May 2024 23:56:16 +0200 Subject: [PATCH] fix(checkin): ordering of table --- shiftregister/team/views.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/shiftregister/team/views.py b/shiftregister/team/views.py index 2bd041a..0fdff7c 100644 --- a/shiftregister/team/views.py +++ b/shiftregister/team/views.py @@ -284,7 +284,6 @@ class RoomShiftList(ShiftList): class CheckinList(LoginRequiredMixin, ListView): - model = Shift paginate_by = 30 template_name = "checkin_list.html" title = "Ankommende Helfer*innen" @@ -294,6 +293,7 @@ class CheckinList(LoginRequiredMixin, ListView): ShiftRegistration.objects.select_related("helper", "shift") .prefetch_related("shift__event__calendar") .filter(shift__deleted=False, state=ShiftRegistration.RegState.REGISTERED) + .order_by("shift__start_at", "shift__room__name") ) def get_context_data(self, **kwargs): @@ -304,9 +304,6 @@ class CheckinList(LoginRequiredMixin, ListView): context["title"] = self.title return context - def get_ordering(self): - return ("start_at", "room__name") - @login_required def checkin(request, pk):