From de9eca07b20dd383a6153ccaad614515a0cc1ec2 Mon Sep 17 00:00:00 2001 From: Thomas Steen Rasmussen Date: Tue, 4 Aug 2020 22:40:17 +0200 Subject: [PATCH] when scheduling, only show slots from sessions with slots of equal or longer duration than the event --- src/backoffice/views.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/backoffice/views.py b/src/backoffice/views.py index fcf01299..be849f84 100644 --- a/src/backoffice/views.py +++ b/src/backoffice/views.py @@ -930,7 +930,8 @@ class EventScheduleView(CampViewMixin, ContentTeamPermissionMixin, FormView): slotindex = 0 # loop over sessions, get free slots for session in self.camp.event_sessions.filter( - event_type=self.event.event_type + event_type=self.event.event_type, + event_duration_minutes__gte=self.event.duration_minutes, ): for slot in session.get_available_slots(): # loop over speakers to see if they are all available