Add page to show all uploaded letters

Because we won’t be showing uploaded letters individually on the uploads
page any more we need a way of listing them. This should be by printing
day, to match how we’re grouping them on the uploads page.

This code reuses the notifications.html template, but flips the
precedence of the filename and recipient because I reckon when you’re
looking at uploads you’re thinking filename-first.
This commit is contained in:
Chris Hill-Scott
2020-05-11 10:52:43 +01:00
parent 77b7e4b8ea
commit 2800b0a0c3
7 changed files with 363 additions and 1 deletions

View File

@@ -0,0 +1,37 @@
{% extends "withnav_template.html" %}
{% from 'components/big-number.html' import big_number %}
{% from 'components/message-count-label.html' import message_count_label %}
{% from "components/page-header.html" import page_header %}
{% block service_page_title %}
Uploaded letters
{% endblock %}
{% block maincolumn_content %}
{{ page_header(
'Uploaded letters',
back_link=url_for('main.uploads', service_id=current_service.id)
) }}
{% if notifications %}
<p class='govuk-body'>
{{ total|format_thousands}} {{ message_count_label(total, 'letter', suffix='') }}
</p>
<p class='govuk-body'>
{{ letter_printing_statement }}
</p>
{% else %}
<p class='table-empty-message'>
No letters printing {{ letter_print_day }}
</p>
{% endif %}
{% include 'views/activity/notifications.html' %}
{% endblock %}