Files
notifications-admin/app/templates/views/jobs/job.html
Chris Hill-Scott 340cb33fdd Refactor ‘finished’ to the model layer
By moving it from the view we reduce the complexity of the methods in
the view layer, so it’s easier to see what they do.

This also renames the variable `finished` to the property
`processing_finished` to disambiguate from the `job_status` field in the
JSON, which can also have a value of `finished`.
2020-01-13 15:10:14 +00:00

35 lines
1.2 KiB
HTML

{% extends "withnav_template.html" %}
{% from "components/banner.html" import banner %}
{% from "components/ajax-block.html" import ajax_block %}
{% from "components/page-footer.html" import page_footer %}
{% block service_page_title %}
{{ job.original_file_name }}
{% endblock %}
{% block maincolumn_content %}
<h1 class="heading-large">
{{ job.original_file_name }}
</h1>
{% if just_sent %}
{{ banner(just_sent_message, type='default', with_tick=True) }}
{% else %}
{{ ajax_block(partials, updates_url, 'status', finished=job.processing_finished) }}
{% endif %}
{{ ajax_block(partials, updates_url, 'counts', finished=job.processing_finished) }}
{{ ajax_block(partials, updates_url, 'notifications', finished=job.processing_finished) }}
{% if job.letter_job_can_be_cancelled %}
<div class="js-stick-at-bottom-when-scrolling">
<div class="page-footer">
<span class="page-footer-delete-link page-footer-delete-link-without-button">
<a href="{{ url_for('main.cancel_letter_job', service_id=current_service.id, job_id=job.id) }}">Cancel sending these letters</a>
</span>
{% else %}
<div>&nbsp;</div>
{% endif %}
{% endblock %}