Rename unclear "permissions" attributes

These are more than a list of permissions: each item includes the
label to use when displaying it as an option on a form. Switching
to a name that reflects how the attributes are used will help to
avoid confusion when we rename some of the other attributes in the
same file in later commits.
This commit is contained in:
Ben Thorner
2021-07-22 14:15:24 +01:00
parent f5580b87dc
commit a38baa0bd8
3 changed files with 17 additions and 10 deletions

View File

@@ -13,7 +13,7 @@ roles = {
all_permissions = set(roles.keys())
all_database_permissions = set(chain(*roles.values()))
permissions = (
permission_options = (
('view_activity', 'See dashboard'),
('send_messages', 'Send messages'),
('manage_templates', 'Add and edit templates'),
@@ -21,7 +21,7 @@ permissions = (
('manage_api_keys', 'Manage API integration'),
)
broadcast_permissions = (
broadcast_permission_options = (
('manage_templates', 'Add and edit templates'),
('create_broadcasts', 'Create new alerts'),
('approve_broadcasts', 'Approve alerts'),