mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-05-05 08:31:00 -04:00
Use message_count_label component
For the button on the check page, we need to be able to say ‘1 text message’ or ‘55 emails’. We already have the logic to do this on the dashboard (101 text messages sent), and it’s already in a component. So this commit makes the check page use the same component.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
{% macro message_count_label(count, template_type) -%}
|
||||
{% macro message_count_label(count, template_type, suffix='sent') -%}
|
||||
{%- if template_type == 'sms' -%}
|
||||
{%- if count == 1 -%}
|
||||
text message
|
||||
@@ -10,6 +10,6 @@
|
||||
email
|
||||
{%- else -%}
|
||||
emails
|
||||
{%- endif -%}
|
||||
{%- endif %} sent
|
||||
{%- endmacro %}
|
||||
{%- endif -%}
|
||||
{%- endif %} {{ suffix }}
|
||||
{%- endmacro %}
|
||||
|
||||
Reference in New Issue
Block a user