mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-20 14:29:51 -04:00
Update banner message for CSV letters
This was always showing the text 'Your letter has been sent...' This has now been updated to start 'Your letters have been sent...' if a job has more than one notification in it.
This commit is contained in:
@@ -93,6 +93,11 @@ def view_job(service_id, job_id):
|
||||
version=job['template_version']
|
||||
)['data']
|
||||
|
||||
just_sent_message = 'Your {} been sent. Printing starts {} at 5.30pm.'.format(
|
||||
'letter has' if job['notification_count'] == 1 else 'letters have',
|
||||
printing_today_or_tomorrow()
|
||||
)
|
||||
|
||||
return render_template(
|
||||
'views/jobs/job.html',
|
||||
finished=(total_notifications == processed_notifications),
|
||||
@@ -110,7 +115,7 @@ def view_job(service_id, job_id):
|
||||
request.args.get('just_sent') == 'yes' and
|
||||
template['template_type'] == 'letter'
|
||||
),
|
||||
printing_day=printing_today_or_tomorrow()
|
||||
just_sent_message=just_sent_message,
|
||||
)
|
||||
|
||||
|
||||
|
||||
@@ -14,9 +14,7 @@
|
||||
</h1>
|
||||
|
||||
{% if just_sent %}
|
||||
{{ banner('Your letter has been sent. Printing starts {} at 5.30pm.'.format(printing_day),
|
||||
type='default',
|
||||
with_tick=True) }}
|
||||
{{ banner(just_sent_message, type='default', with_tick=True) }}
|
||||
{% else %}
|
||||
{{ ajax_block(partials, updates_url, 'status', finished=finished) }}
|
||||
{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user