mirror of
https://gitlab.com/animath/si/plateforme.git
synced 2025-01-24 09:01:26 +00:00
Fix permission to download all authorizations of a tournament
Signed-off-by: Emmy D'Anello <emmy.danello@animath.fr>
This commit is contained in:
parent
0bc5ef0a7f
commit
a594b268ea
@ -391,7 +391,7 @@ class TeamAuthorizationsView(LoginRequiredMixin, View):
|
|||||||
tournament = Tournament.objects.get(pk=kwargs["tournament_id"])
|
tournament = Tournament.objects.get(pk=kwargs["tournament_id"])
|
||||||
|
|
||||||
if user.registration.is_admin or user.registration.is_volunteer \
|
if user.registration.is_admin or user.registration.is_volunteer \
|
||||||
and (user.registration in tournament.organizers
|
and (user.registration in tournament.organizers.all()
|
||||||
or (team is not None and team.participation.final
|
or (team is not None and team.participation.final
|
||||||
and user.registration in Tournament.final_tournament().organizers)):
|
and user.registration in Tournament.final_tournament().organizers)):
|
||||||
return super().dispatch(request, *args, **kwargs)
|
return super().dispatch(request, *args, **kwargs)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user