From d1d0e7e9b4c1d3ac39105883080595162c9c48a2 Mon Sep 17 00:00:00 2001 From: Emanuel Schuetze Date: Sun, 4 Sep 2011 12:21:58 +0200 Subject: [PATCH] Updated permissions. --- openslides/agenda/models.py | 6 ++--- openslides/agenda/views.py | 2 +- openslides/application/models.py | 8 +++---- .../application/base_application.html | 2 +- openslides/application/views.py | 8 +++---- openslides/assignment/models.py | 9 ++++---- .../assignment/templates/assignment/view.html | 2 +- openslides/assignment/views.py | 4 ++-- openslides/participant/models.py | 4 ++-- .../participant/base_participant.html | 8 +++---- .../templates/participant/overview.html | 4 ++-- openslides/participant/views.py | 22 +++++++++---------- openslides/system/models.py | 2 +- openslides/templates/base.html | 8 +++---- openslides/utils/pdf.py | 12 +++++----- 15 files changed, 50 insertions(+), 51 deletions(-) diff --git a/openslides/agenda/models.py b/openslides/agenda/models.py index 3ccb20131..b94925bc1 100644 --- a/openslides/agenda/models.py +++ b/openslides/agenda/models.py @@ -176,9 +176,9 @@ class Item(InheritanceCastModel): class Meta: permissions = ( - ('can_view_agenda', "Can see the agenda"), - ('can_manage_agenda', "Can manage the agenda and its items"), - ('can_see_beamer', "Can see the Beamer"), + ('can_see_agenda', "Can see agenda"), + ('can_manage_agenda', "Can manage agenda"), + ('can_see_beamer', "Can see projector"), ) diff --git a/openslides/agenda/views.py b/openslides/agenda/views.py index e72de845f..519219d26 100644 --- a/openslides/agenda/views.py +++ b/openslides/agenda/views.py @@ -130,7 +130,7 @@ def assignment_votes(item): return votes -@permission_required('agenda.can_view_agenda') +@permission_required('agenda.can_see_agenda') @template('agenda/overview.html') def overview(request): """ diff --git a/openslides/application/models.py b/openslides/application/models.py index 4affe00a5..827fb8de9 100644 --- a/openslides/application/models.py +++ b/openslides/application/models.py @@ -396,10 +396,10 @@ class Application(models.Model): class Meta: permissions = ( - ('can_view_application', _("Can see applications")), - ('can_insert_application', _("Can insert new applications")), - ('can_support_application', _("Can support applications")), - ('can_manage_application', _("Can manage applications")), + ('can_see_application', "Can see application"), + ('can_create_application', "Can create application"), + ('can_support_application', "Can support application"), + ('can_manage_application', "Can manage application"), ) diff --git a/openslides/application/templates/application/base_application.html b/openslides/application/templates/application/base_application.html index 98040c52e..dcf89242b 100644 --- a/openslides/application/templates/application/base_application.html +++ b/openslides/application/templates/application/base_application.html @@ -6,7 +6,7 @@

{%trans "Applications" %}