Files
notifications-admin/app/templates/partials/jobs/notifications.html
T

50 lines
1.4 KiB
HTML
Raw Normal View History

{% from "components/table.html" import list_table, field, right_aligned_field_heading, date_field, row_heading %}
2016-03-02 17:36:20 +00:00
2016-04-27 09:28:42 +01:00
<div
2016-06-08 16:34:26 +01:00
{% if notifications %}
class='dashboard-table'
{% endif %}
2016-05-25 13:36:35 +01:00
{% if not finished %}
data-module="update-content"
2016-06-08 16:34:26 +01:00
data-resource="{{url_for(".view_job_updates", service_id=current_service.id, job_id=job.id, status=request.args.get('status'), help=request.args.get('help'))}}"
data-key="notifications"
aria-live="polite"
2016-04-27 09:28:42 +01:00
{% endif %}
>
{% if notifications %}
<p class="bottom-gutter">
2016-06-08 16:34:26 +01:00
<a href="{{ url_for('.view_job_csv', service_id=current_service.id, job_id=job.id, status=status) }}" download="download" class="heading-small">Download as a CSV file</a>
&emsp;
Delivery information is available for 7 days
</p>
{% endif %}
2016-06-09 11:26:45 +01:00
{% call(item, row_number) list_table(
notifications,
caption=uploaded_file_name,
caption_visible=False,
2016-06-08 16:34:26 +01:00
empty_message="No messages to show",
2016-06-09 11:26:45 +01:00
field_headings=[
'Recipient',
'Time',
'Status'
],
field_headings_visible=False
) %}
{% call row_heading() %}
{{ item.to }}
2016-04-27 09:28:42 +01:00
{% endcall %}
2016-06-09 11:26:45 +01:00
{{ date_field(
(item.updated_at or item.created_at)|format_datetime_short
) }}
{% call field(
align='right',
status=item.status|format_notification_status_as_field_status
) %}
{{ item.status|format_notification_status(item.template.template_type) }}
{% endcall %}
{% endcall %}
2016-04-27 09:28:42 +01:00
</div>