mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-19 18:04:25 -05:00
In pages specific to a service (e.g. dashboard and sub pages) the title needs to distinguish which service it applies to. This is mainly to give context to screen reader users who could be managing multiple services. Implementing this uses template inheritance: `page_title` includes `per_page_title` includes `service_page_title` ‘GOV.UK Notify’ is inserted into every page title. Pages that set `service_page_title` get the service name inserted too.
42 lines
1.3 KiB
HTML
42 lines
1.3 KiB
HTML
{% extends "withoutnav_template.html" %}
|
|
{% from "components/table.html" import list_table, row, field %}
|
|
|
|
{% block per_page_title %}
|
|
Your profile
|
|
{% endblock %}
|
|
|
|
{% block maincolumn_content %}
|
|
|
|
<h1 class="heading-large">Your profile</h1>
|
|
|
|
{% call(item, row_number) list_table(
|
|
[
|
|
{'label': 'Name', 'value': current_user.name, 'url': url_for('.user_profile_name')},
|
|
{'label': 'Email address', 'value': current_user.email_address, 'url': url_for('.user_profile_email')},
|
|
{'label': 'Mobile number', 'value': current_user.mobile_number, 'url': url_for('.user_profile_mobile_number')},
|
|
{'label': 'Password', 'value': 'Last changed ' + current_user.password_changed_at |format_datetime_short, 'url': url_for('.user_profile_password')},
|
|
],
|
|
caption='Account settings',
|
|
field_headings=['Setting', 'Value', 'Link to change'],
|
|
field_headings_visible=False,
|
|
caption_visible=False
|
|
) %}
|
|
{% call field() %}
|
|
{{ item.label }}
|
|
{% endcall %}
|
|
{% call field() %}
|
|
{{ item.value }}
|
|
{% endcall %}
|
|
{% call field(align='right') %}
|
|
{% if item.label == 'Email address' %}
|
|
{% if can_see_edit %}
|
|
<a href="{{ item.url }}">Change</a>
|
|
{% endif %}
|
|
{% else %}
|
|
<a href="{{ item.url }}">Change</a>
|
|
{% endif %}
|
|
{% endcall %}
|
|
{% endcall %}
|
|
|
|
{% endblock %}
|