use shortened names for orgs in the choicefield which satisfies the admin requirement, replace short name with a long name in the user facing app in the form, summary page, manage app page

This commit is contained in:
Rachid Mrad 2023-10-12 15:32:10 -04:00
parent 1550fde832
commit 003db40e58
No known key found for this signature in database
GPG key ID: EF38E4CEC4A8F3CF
10 changed files with 171 additions and 20 deletions

View file

@ -219,9 +219,9 @@ class MyUserAdmin(BaseUserAdmin):
# (which should in theory be the ONLY group)
def group(self, obj):
if obj.groups.filter(name="full_access_group").exists():
return "Full access"
return "full_access_group"
elif obj.groups.filter(name="cisa_analysts_group").exists():
return "Analyst"
return "cisa_analysts_group"
return ""
def get_list_display(self, request):