Hide report on letter job

This commit is contained in:
Chris Hill-Scott
2017-07-13 09:57:15 +01:00
parent 7881753193
commit ad897cd820
2 changed files with 14 additions and 10 deletions

View File

@@ -24,16 +24,18 @@
<div class="dashboard-table bottom-gutter-3-2">
{% endif %}
{% if percentage_complete < 100 %}
<p class="bottom-gutter hint">
Report is {{ "{:.0f}%".format(percentage_complete * 0.99) }} complete…
</p>
{% elif notifications %}
<p class="bottom-gutter">
<a href="{{ download_link }}" download="download" class="heading-small">Download this report</a>
&emsp;
<span id="time-left">{{ time_left }}</span>
</p>
{% if template.template_type != 'letter' %}
{% if percentage_complete < 100 %}
<p class="bottom-gutter hint">
Report is {{ "{:.0f}%".format(percentage_complete * 0.99) }} complete…
</p>
{% elif notifications %}
<p class="bottom-gutter">
<a href="{{ download_link }}" download="download" class="heading-small">Download this report</a>
&emsp;
<span id="time-left">{{ time_left }}</span>
</p>
{% endif %}
{% endif %}
{% call(item, row_number) list_table(

View File

@@ -183,6 +183,8 @@ def test_should_show_letter_job(
assert normalize_spaces(page.select('.keyline-block')[1].text) == (
'6 January Estimated delivery date'
)
assert page.select('[download=download]') == []
assert page.select('.hint') == []
mock_get_notifications.assert_called_with(
SERVICE_ONE_ID,