Merge pull request #1364 from alphagov/letter-job-page-real

Customise the job page to make sense for letters
This commit is contained in:
Chris Hill-Scott
2017-07-21 13:10:09 +01:00
committed by GitHub
9 changed files with 183 additions and 44 deletions

View File

@@ -0,0 +1,23 @@
{% from 'components/big-number.html' import big_number %}
{% from 'components/message-count-label.html' import message_count_label %}
<div class="grid-row bottom-gutter-2-3">
<div class="column-half">
<div class="keyline-block">
{{ big_number(
total,
message_count_label(total, 'letter', suffix='')|capitalize,
smaller=True
)}}
</div>
</div>
<div class="column-half">
<div class="keyline-block">
{{ big_number(
delivery_estimate|string|format_date_short,
'Estimated delivery date',
smaller=True
)}}
</div>
</div>
</div>

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(
@@ -53,7 +55,9 @@
{{ item.preview_of_content }}
</p>
{% endcall %}
{{ notification_status_field(item) }}
{{ notification_status_field(
'' if template.template_type == 'letter' else item
) }}
{% endcall %}
{% if more_than_one_page %}