mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-04 18:32:33 -05:00
Merge pull request #426 from alphagov/reword-recent-templates
Reword ‘recent templates’ section of dashboard
This commit is contained in:
@@ -1,9 +1,9 @@
|
||||
{% from "components/table.html" import list_table, field, right_aligned_field_heading %}
|
||||
{% from "components/table.html" import list_table, field, hidden_field_heading, right_aligned_field_heading %}
|
||||
{% call(item, row_number) list_table(
|
||||
template_statistics,
|
||||
caption="Recent templates – last 7 days",
|
||||
empty_message='You haven’t sent any batch messages yet',
|
||||
field_headings=['Template', 'Type', right_aligned_field_heading('Usage')]
|
||||
caption="In the last 7 days",
|
||||
empty_message='You haven’t set up any templates yet',
|
||||
field_headings=['Template', hidden_field_heading('Type'), right_aligned_field_heading('Messages sent')]
|
||||
) %}
|
||||
{% call field() %}
|
||||
<a href="{{ url_for('.edit_service_template', service_id=current_service.id, template_id=item.template.id) }}">
|
||||
@@ -11,7 +11,7 @@
|
||||
</a>
|
||||
{% endcall %}
|
||||
{% call field() %}
|
||||
{{item.template.template_type}}
|
||||
{{'Text message' if 'sms' == item.template.template_type else 'Email'}}
|
||||
{% endcall %}
|
||||
{% call field(align='right') %}
|
||||
{{ item.usage_count }}
|
||||
|
||||
@@ -85,7 +85,7 @@ def test_should_show_recent_templates_on_dashboard(app_,
|
||||
assert 'Test Service' in headers
|
||||
assert 'Sent today' in headers
|
||||
template_usage_headers = [th.text.strip() for th in page.thead.find_all('th')]
|
||||
for th in ['Template', 'Type', 'Usage']:
|
||||
for th in ['Template', 'Type', 'Messages sent']:
|
||||
assert th in template_usage_headers
|
||||
table_rows = page.tbody.find_all('tr')
|
||||
|
||||
|
||||
Reference in New Issue
Block a user