add: Pro jistotu v DetailView i kontrola u orga

This commit is contained in:
Jonas Havelka 2022-12-19 23:12:23 +01:00
parent 9bb0bcf3ca
commit 1f16f194f7

View file

@ -259,8 +259,9 @@ class EditReseniView(DetailReseniView):
return ctx
def check_access(self):
""" Na orga máme nároky už v urls.py """
pass
# Na orga máme nároky už v urls.py ale better safe then sorry
if not self.request.user.je_org:
raise PermissionDenied()
def hodnoceniReseniView(request, pk, *args, **kwargs):