Use keys in members_by_role dict to get the CSP roles
This commit is contained in:
parent
6e64287e3a
commit
4f954117c8
@ -75,7 +75,6 @@ def settings(application_id):
|
||||
# refactor like portfolio admin render function
|
||||
application = Applications.get(application_id)
|
||||
form = ApplicationForm(name=application.name, description=application.description)
|
||||
csp_roles = [role.value for role in CSPRole]
|
||||
|
||||
return render_template(
|
||||
"portfolios/applications/settings.html",
|
||||
@ -83,7 +82,6 @@ def settings(application_id):
|
||||
form=form,
|
||||
environments_obj=get_environments_obj_for_app(application=application),
|
||||
env_forms=serialize_env_member_forms(application=application),
|
||||
csp_roles=csp_roles,
|
||||
)
|
||||
|
||||
|
||||
|
@ -87,10 +87,10 @@
|
||||
<div>
|
||||
{{ RolePanel(users=unassigned) }}
|
||||
|
||||
{% for role in csp_roles %}
|
||||
{{ RolePanel(users=members_by_role[role], role=role) }}
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% for role, members in members_by_role.items() %}
|
||||
{{ RolePanel(users=members, role=role) }}
|
||||
{% endfor %}
|
||||
</div>
|
||||
{% endcall %}
|
||||
|
||||
{% call ToggleSection(section_name="edit") %}
|
||||
|
Loading…
x
Reference in New Issue
Block a user