mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-16 20:49:00 -04:00
This takes the original prototype version of this page, and, using the same fake data (ie nothing is wired up): - adds an invite users page - adds an edit (and delete) user page Both these pages allow the user to set another user’s permissions. This commit adds images for the ticks and crosses, so we have control over their appearance.
57 lines
1.7 KiB
HTML
57 lines
1.7 KiB
HTML
{% extends "withnav_template.html" %}
|
||
{% from "components/table.html" import list_table, row, field, boolean_field, hidden_field_heading %}
|
||
{% from "components/page-footer.html" import page_footer %}
|
||
|
||
{% set table_options = {
|
||
'field_headings': [
|
||
'Name', 'Send messages', 'Manage service', 'Manage API keys', hidden_field_heading('Link to change')
|
||
],
|
||
'field_headings_visible': True,
|
||
'caption_visible': True
|
||
} %}
|
||
|
||
{% block page_title %}
|
||
Manage users – GOV.UK Notify
|
||
{% endblock %}
|
||
|
||
{% block maincolumn_content %}
|
||
|
||
<h1 class="heading-large">
|
||
Manage team
|
||
</h1>
|
||
|
||
{% call(item) list_table(
|
||
users, caption='Active', **table_options
|
||
) %}
|
||
{% call field() %}
|
||
{{ item.name }}
|
||
{% endcall %}
|
||
{{ boolean_field(item.permission_send_messages) }}
|
||
{{ boolean_field(item.permission_manage_service) }}
|
||
{{ boolean_field(item.permission_manage_api_keys) }}
|
||
{% call field(align='right') %}
|
||
<a href="{{ url_for('.edit_user', service_id=service_id, user_id=item.id)}}">Change</a>
|
||
{% endcall %}
|
||
{% endcall %}
|
||
<p class='table-show-more-link'>
|
||
<a href="{{ url_for('.invite_user', service_id=service_id) }}">Add a new team member</a>
|
||
</p>
|
||
|
||
{% if invited_users %}
|
||
{% call(item) list_table(
|
||
invited_users, caption='Invited', **table_options
|
||
) %}
|
||
{% call field() %}
|
||
{{ item.email_localpart }}
|
||
{% endcall %}
|
||
{{ boolean_field(item.permission_send_messages) }}
|
||
{{ boolean_field(item.permission_manage_service) }}
|
||
{{ boolean_field(item.permission_manage_api_keys) }}
|
||
{% call field(align='right') %}
|
||
<a href="{{ url_for('.edit_user', service_id=service_id, user_id=item.id)}}">Change</a>
|
||
{% endcall %}
|
||
{% endcall %}
|
||
{% endif %}
|
||
|
||
{% endblock %}
|