Merge branch 'master' into convert-all-links-to-govuk-frontend

This commit is contained in:
Tom Byers
2020-02-24 10:12:58 +00:00
committed by GitHub
34 changed files with 468 additions and 135 deletions

View File

@@ -2,19 +2,32 @@
{% from "components/message-count-label.html" import message_count_label %}
<div class="ajax-block">
{% if inbound_sms_summary != None %}
<a id="total-received" class="govuk-link govuk-link--no-visited-state banner-dashboard" href="{{ url_for('.inbox', service_id=current_service.id) }}">
{% if current_service.inbound_sms_summary != None %}
<a id="total-received" class="govuk-link govuk-link--no-visited-state banner-dashboard" class="banner-dashboard" href="{{ url_for('.inbox', service_id=current_service.id) }}">
<span class="banner-dashboard-count">
{{ inbound_sms_summary.count|format_thousands }}
{{ current_service.inbound_sms_summary.count|format_thousands }}
</span>
<span class="banner-dashboard-count-label">
{{ message_count_label(inbound_sms_summary.count, 'sms', suffix='received') }}
{{ message_count_label(current_service.inbound_sms_summary.count, 'sms', suffix='received') }}
</span>
{% if inbound_sms_summary.most_recent %}
{% if current_service.inbound_sms_summary.most_recent %}
<span class="banner-dashboard-meta">
latest message {{ inbound_sms_summary.most_recent | format_delta }}
latest message {{ current_service.inbound_sms_summary.most_recent | format_delta }}
</span>
{% endif %}
</a>
{% endif %}
{% if current_service.returned_letter_summary %}
<a id="total-returned-letters" class="govuk-link govuk-link--no-visited-state banner-dashboard" href="{{ url_for('main.returned_letter_summary', service_id=current_service.id) }}">
<span class="banner-dashboard-count">
{{ current_service.count_of_returned_letters_in_last_7_days|format_thousands }}
</span>
<span class="banner-dashboard-count-label">
returned {{ message_count_label(current_service.count_of_returned_letters_in_last_7_days, 'letter', suffix='') }}
</span>
<span class="banner-dashboard-meta">
latest report {{ current_service.most_recent_returned_letter_report|format_delta_days }}
</span>
</a>
{% endif %}
</div>

View File

@@ -1,4 +1,5 @@
{% from "components/ajax-block.html" import ajax_block %}
{% from "components/page-header.html" import page_header %}
{% extends "withnav_template.html" %}
@@ -8,9 +9,10 @@
{% block maincolumn_content %}
<h1 class="heading-large">
Received text messages
</h1>
{{ page_header(
'Received text messages',
back_link=url_for('main.service_dashboard', service_id=current_service.id)
) }}
{{ ajax_block(
partials,

View File

@@ -43,17 +43,17 @@
<li class="get-started-list__item">
<h2 class="get-started-list__heading">Write some messages</h2>
<p>Add <a class="govuk-link govuk-link--no-visited-state" href="{{ url_for('main.features', _anchor='templates') }}">message templates</a> with examples of the content you plan to send. You can use our <a class="govuk-link govuk-link--no-visited-state" href="{{ url_for('main.guidance_index') }}">guidance</a> to help you.</p>
<p>Add message templates with examples of the content you plan to send. You can use our <a class="govuk-link govuk-link--no-visited-state" href="{{ url_for('main.guidance_index') }}">guidance</a> to help you.</p>
</li>
<li class="get-started-list__item">
<h2 class="get-started-list__heading">Set up your service</h2>
{% if not current_user.is_authenticated or not current_service %}
<p>Review your settings to add message branding, reply-to addresses and sender information.</p>
<p>Add team members and check their <a class="govuk-link govuk-link--no-visited-state" href="{{ url_for('main.features', _anchor='permissions') }}">permissions</a>.</p>
<p>Add team members and check their permissions.</p>
{% else %}
<p>Review your <a class="govuk-link govuk-link--no-visited-state" href="{{ url_for('.service_settings', service_id=current_service.id) }}">settings</a> to add message branding, reply-to addresses and sender information.</p>
<p>Add <a class="govuk-link govuk-link--no-visited-state" href="{{ url_for('.manage_users', service_id=current_service.id) }}">team members</a> and check their <a class="govuk-link govuk-link--no-visited-state" href="{{ url_for('main.features', _anchor='permissions') }}">permissions</a>.</p>
<p>Add <a class="govuk-link govuk-link--no-visited-state" href="{{ url_for('.manage_users', service_id=current_service.id) }}">team members</a> and check their permissions.</p>
{% endif %}
</li>

View File

@@ -1,5 +1,5 @@
{% extends "content_template.html" %}
{% from "components/current-service-link.html" import current_service_link %}
{% from "components/service-link.html" import service_link %}
{% block per_page_title %}
Branding and customisation
@@ -25,7 +25,7 @@
<p>To change your email branding:</p>
<ol class="list list-number">
<li>Go to the <b class="govuk-!-font-weight-bold">Email settings</b> section of the {{ current_service_link('main.service_settings', 'settings') }} page.</li>
<li>Go to the <b class="govuk-!-font-weight-bold">Email settings</b> section of the {{ service_link(current_service, 'main.service_settings', 'settings') }} page.</li>
<li>Select <b class="govuk-!-font-weight-bold">Change</b> on the <b class="govuk-!-font-weight-bold">Email branding</b> row.</li>
</ol>
@@ -36,7 +36,7 @@
<p>To add a reply-to email address:</p>
<ol class="list list-number">
<li>Go to the <b class="govuk-!-font-weight-bold">Email settings</b> section of the {{ current_service_link('main.service_settings', 'settings') }} page.</li>
<li>Go to the <b class="govuk-!-font-weight-bold">Email settings</b> section of the {{ service_link(current_service, 'main.service_settings', 'settings') }} page.</li>
<li>Select <b class="govuk-!-font-weight-bold">Manage</b> on the <b class="govuk-!-font-weight-bold">Reply-to email addresses</b> row.</li>
<li>Select <b class="govuk-!-font-weight-bold">Add reply-to address</b>.</li>
</ol>
@@ -48,7 +48,7 @@
<p>To change the text message sender from the default of GOVUK:</p>
<ol class="list list-number">
<li>Go to the <b class="govuk-!-font-weight-bold">Text message settings</b> section of the {{ current_service_link('main.service_settings', 'settings') }} page.</li>
<li>Go to the <b class="govuk-!-font-weight-bold">Text message settings</b> section of the {{ service_link(current_service, 'main.service_settings', 'settings') }} page.</li>
<li>Select <b class="govuk-!-font-weight-bold">Manage</b> on the <b class="govuk-!-font-weight-bold">Text message senders</b> row.</li>
<li>Select <b class="govuk-!-font-weight-bold">Change</b> or <b class="govuk-!-font-weight-bold">Add text message sender</b>.</li>
</ol>
@@ -60,7 +60,7 @@
<p>To add a logo to your letters:</p>
<ol class="list list-number">
<li>Go to the <b class="govuk-!-font-weight-bold">Letter settings</b> section of the {{ current_service_link('main.service_settings', 'settings') }} page.</li>
<li>Go to the <b class="govuk-!-font-weight-bold">Letter settings</b> section of the {{ service_link(current_service, 'main.service_settings', 'settings') }} page.</li>
<li>Select <b class="govuk-!-font-weight-bold">Change</b> on the <b class="govuk-!-font-weight-bold">Letter branding</b> row.</li>
</ol>

View File

@@ -1,5 +1,5 @@
{% extends "content_template.html" %}
{% from "components/current-service-link.html" import current_service_link %}
{% from "components/service-link.html" import service_link %}
{% block per_page_title %}
Send messages
@@ -15,7 +15,7 @@
<p>To send a batch of messages at once:</p>
<ol class="list list-number">
<li>Go to the {{ current_service_link('main.choose_template', 'templates') }} page and choose an existing template.</li>
<li>Go to the {{ service_link(current_service, 'main.choose_template', 'templates') }} page and choose an existing template.</li>
<li>Select <b class="govuk-!-font-weight-bold">Send</b>.</li>
<li>If youre sending emails, select <b class="govuk-!-font-weight-bold">Upload a list of email addresses</b>. If youre sending text messages, select <b class="govuk-!-font-weight-bold">Upload a list of phone numbers</b>. If youre sending letters, select <b class="govuk-!-font-weight-bold">Upload a list of addresses</b>.</li>

View File

@@ -1,5 +1,5 @@
{% extends "content_template.html" %}
{% from "components/current-service-link.html" import current_service_link %}
{% from "components/service-link.html" import service_link %}
{% block per_page_title %}
Edit and format messages
@@ -22,7 +22,7 @@
<p>You can see a list of formatting instructions on the edit template page:</p>
<ol class="list list-number">
<li>Go to the {{ current_service_link('main.choose_template', 'templates') }} page.</li>
<li>Go to the {{ service_link(current_service, 'main.choose_template', 'templates') }} page.</li>
<li>Add a new template or choose an existing template and select <b class="govuk-!-font-weight-bold">Edit</b>.</li>
</ol>
@@ -61,7 +61,7 @@
<p>To add a placeholder to the template:</p>
<ol class="list list-number">
<li>Go to the {{ current_service_link('main.choose_template', 'templates') }} page.</li>
<li>Go to the {{ service_link(current_service, 'main.choose_template', 'templates') }} page.</li>
<li>Add a new template or choose an existing template and select <b class="govuk-!-font-weight-bold">Edit</b>.</li>
<li>Add a placeholder using double brackets. For example: Hello ((first&nbsp;name)), your reference is ((ref&nbsp;number)).</li>
<li>Select <b class="govuk-!-font-weight-bold">Save</b>.</li>
@@ -81,7 +81,7 @@
<p>To add optional content to your emails and text messages:</p>
<ol class="list list-number">
<li>Go to the {{ current_service_link('main.choose_template', 'templates') }} page.</li>
<li>Go to the {{ service_link(current_service, 'main.choose_template', 'templates') }} page.</li>
<li>Add a new template or choose an existing template and select <b class="govuk-!-font-weight-bold">Edit</b>.</li>
<li>Use double brackets and ?? to define optional content. For example, if you only want to show something to people who are under 18: ((under18??Please get your application signed by a parent or guardian.))</li>
<li>Select <b class="govuk-!-font-weight-bold">Save</b>.</li>

View File

@@ -1,5 +1,5 @@
{% extends "content_template.html" %}
{% from "components/current-service-link.html" import current_service_link %}
{% from "components/service-link.html" import service_link %}
{% block per_page_title %}
Upload a letter
@@ -14,7 +14,7 @@
<p>To upload and send a letter from a PDF file:</p>
<ol class="list list-number">
<li>Go to the {{ current_service_link('main.uploads', 'uploads') }} page.</li>
<li>Go to the {{ service_link(current_service, 'main.uploads', 'uploads') }} page.</li>
<li>Select <b class="govuk-!-font-weight-bold">Upload a letter</b>.</li>
<li>Select <b class="govuk-!-font-weight-bold">Choose file</b>.</li>
</ol>

View File

@@ -17,7 +17,11 @@
) }}
<p>
{% if is_precompiled_letter %}
Provided as PDF
{% if created_by %}
Uploaded
{% else %}
Provided as PDF
{% endif %}
{% else %}
{% if help %}
{{ template.name }}
@@ -34,7 +38,7 @@
{% elif created_by %}
by {{ created_by.name }}
{% endif %}
on {{ created_at|format_datetime_short }}
{{ created_at|format_datetime_human }}
</p>
{% if template.template_type == 'letter' %}
@@ -67,7 +71,7 @@
{{ letter_print_day }}
</p>
<p>
Estimated delivery date: {{ estimated_letter_delivery_date|string|format_date_short }}
Estimated delivery date: {{ estimated_letter_delivery_date|format_day_of_week }} {{ estimated_letter_delivery_date|format_date_short }}
</p>
{% endif %}
{% endif %}

View File

@@ -1,5 +1,6 @@
{% from "components/table.html" import list_table, row_heading %}
{% from "components/message-count-label.html" import message_count_label %}
{% from "components/page-header.html" import page_header %}
{% extends "withnav_template.html" %}
{% block service_page_title %}
@@ -7,9 +8,20 @@
{% endblock %}
{% block maincolumn_content %}
<h1 class="heading-large">
Returned letters
</h1>
<div class="grid-row">
<div class="column-five-sixths">
{{ page_header(
'Returned letters',
back_link=url_for('main.service_dashboard', service_id=current_service.id)
) }}
<p class="govuk-body">
Reports are published once a month.
</p>
<p class="govuk-body">
Youll only get a report if one or more of your letters is returned.
</p>
</div>
</div>
<div class="dashboard-table">
{% call(item, row_number) list_table(
data,

View File

@@ -42,7 +42,7 @@
{% call field(align='right') %}
<span class="align-with-message-body">
<span class="status-hint">
Originally sent {{ item.created_at|format_date_normal }}
Sent {{ item.created_at|format_date_normal }}
</span>
</span>
{% endcall %}