mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-06-04 19:47:22 +02:00
Fix migrations + readonly views
This commit is contained in:
parent
afe498978c
commit
280bc23fa6
10 changed files with 118 additions and 13 deletions
|
@ -10,6 +10,10 @@ class UserPortfolioRoleChoices(models.TextChoices):
|
|||
ORGANIZATION_ADMIN_READ_ONLY = "organization_admin_read_only", "Admin read only"
|
||||
ORGANIZATION_MEMBER = "organization_member", "Member"
|
||||
|
||||
@classmethod
|
||||
def get_user_portfolio_role_label(cls, user_portfolio_role):
|
||||
return cls(user_portfolio_role).label if user_portfolio_role else None
|
||||
|
||||
|
||||
class UserPortfolioPermissionChoices(models.TextChoices):
|
||||
""" """
|
||||
|
@ -29,3 +33,7 @@ class UserPortfolioPermissionChoices(models.TextChoices):
|
|||
# Domain: field specific permissions
|
||||
VIEW_SUBORGANIZATION = "view_suborganization", "View suborganization"
|
||||
EDIT_SUBORGANIZATION = "edit_suborganization", "Edit suborganization"
|
||||
|
||||
@classmethod
|
||||
def get_user_portfolio_permission_label(cls, user_portfolio_permission):
|
||||
return cls(user_portfolio_permission).label if user_portfolio_permission else None
|
Loading…
Add table
Add a link
Reference in a new issue