From fc82e230662b4d0f881f2d9e0fa0ffa9de3c07b0 Mon Sep 17 00:00:00 2001 From: Valentin Deniaud Date: Tue, 18 Oct 2022 11:56:43 +0200 Subject: [PATCH 1/7] manager: remove obsolete user_can_manage in exception list (#70185) Permission is already checked by ManagedDeskMixin. --- .../templates/chrono/manager_time_period_exception_list.html | 4 ++-- chrono/manager/views.py | 5 ----- 2 files changed, 2 insertions(+), 7 deletions(-) diff --git a/chrono/manager/templates/chrono/manager_time_period_exception_list.html b/chrono/manager/templates/chrono/manager_time_period_exception_list.html index 9591c5c3..20029047 100644 --- a/chrono/manager/templates/chrono/manager_time_period_exception_list.html +++ b/chrono/manager/templates/chrono/manager_time_period_exception_list.html @@ -20,8 +20,8 @@ diff --git a/chrono/manager/views.py b/chrono/manager/views.py index e9b12aed..60d2258f 100644 --- a/chrono/manager/views.py +++ b/chrono/manager/views.py @@ -2921,11 +2921,6 @@ class TimePeriodExceptionListView(ManagedDeskMixin, ListView): Q(desk=self.desk) | Q(unavailability_calendar__desks=self.desk), end_datetime__gte=now() ) - def get_context_data(self, **kwargs): - context = super().get_context_data(**kwargs) - context['user_can_manage'] = self.desk.agenda.can_be_managed(self.request.user) - return context - time_period_exception_list = TimePeriodExceptionListView.as_view() -- 2.35.1