mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-16 20:49:00 -04:00
It’s useful to get some kind of preview of the report before you download it. And if there’s only a few letters in there then you might not even need to download it at all. For teams with lots of letters we don’t want the page to load too slowly so let’s cap the number of displayed items to 50, same as previewing a spreadsheet.
33 lines
1.1 KiB
HTML
33 lines
1.1 KiB
HTML
{% from "components/table.html" import list_table, field %}
|
|
{% from "components/message-count-label.html" import message_count_label %}
|
|
{% extends "withnav_template.html" %}
|
|
|
|
{% block service_page_title %}
|
|
Returned letters
|
|
{% endblock %}
|
|
|
|
{% block maincolumn_content %}
|
|
<h1 class="heading-large">
|
|
Returned letters
|
|
</h1>
|
|
<div class="body-copy-table" id='pill-selected-item'>
|
|
{% call(item, row_number) list_table(
|
|
data,
|
|
caption="Returned letters report",
|
|
caption_visible=False,
|
|
empty_message='If you have returned letter reports they will be listed here',
|
|
field_headings=['Report'],
|
|
field_headings_visible=False
|
|
) %}
|
|
{% call field() %}
|
|
<a class="govuk_link file-list-filename"
|
|
href="{{url_for('.returned_letters', service_id=current_service.id, reported_at=item.reported_at)}}">{{ item.reported_at | format_date_normal }}</a>
|
|
<p class="file-list-hint">
|
|
{{ item.returned_letter_count}} {{ message_count_label(item.returned_letter_count, 'letter', suffix='')}}
|
|
</p>
|
|
{% endcall %}
|
|
{% endcall %}
|
|
</div>
|
|
|
|
{% endblock %}
|