Show postage on template page if service can choose postage and

postage set on the template.
This commit is contained in:
Pea Tyczynska
2018-12-18 15:43:36 +00:00
parent 6f74b7f3ea
commit a60d269900
2 changed files with 8 additions and 0 deletions

View File

@@ -76,6 +76,7 @@ def view_template(service_id, template_id):
show_recipient=True,
page_count=get_page_count_for_letter(template),
),
template_postage=template["postage"],
default_letter_contact_block_id=default_letter_contact_block_id,
)

View File

@@ -21,6 +21,13 @@
Send
</a>
</div>
<div class="column-whole">
{% if current_service.has_permission("choose_postage") and template_postage %}
<h2 class="heading-small heading-inline">Postage</h2>: {{ template_postage }} class
{% elif (current_service.has_permission("choose_postage") and not template_postage) or not current_service.has_permission("choose_postage") %}
<h2 class="heading-small heading-inline">Postage</h2>: {{ current_service.postage }} class
{% endif %}
</div>
{% endif %}
{% else %}
{% if current_user.has_permissions('send_messages', restrict_admin_usage=True) %}