From 6131f6c6aaa56e581ec7ae446e4cf6f0a4a29ea7 Mon Sep 17 00:00:00 2001 From: Chris Hill-Scott Date: Mon, 24 Aug 2020 12:04:06 +0100 Subject: [PATCH] =?UTF-8?q?Replace=20=E2=80=98broadcast=E2=80=99=20with=20?= =?UTF-8?q?=E2=80=98alert=E2=80=99=20on=20dashboard?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We’re moving away from ‘broadcast’ as a noun, so this commit updates the dashboard to be in line with changes in other PRs. --- app/main/views/broadcast.py | 6 +++--- app/templates/views/broadcast/dashboard.html | 4 ++-- tests/app/main/views/test_broadcast.py | 10 +++++----- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/app/main/views/broadcast.py b/app/main/views/broadcast.py index d27f14c25..7d0cc5018 100644 --- a/app/main/views/broadcast.py +++ b/app/main/views/broadcast.py @@ -53,17 +53,17 @@ def get_broadcast_dashboard_partials(service_id): pending_approval_broadcasts=render_template( 'views/broadcast/partials/dashboard-table.html', broadcasts=broadcast_messages.with_status('pending-approval'), - empty_message='You do not have any broadcasts waiting for approval', + empty_message='You do not have any alerts waiting for approval', ), live_broadcasts=render_template( 'views/broadcast/partials/dashboard-table.html', broadcasts=broadcast_messages.with_status('broadcasting'), - empty_message='You do not have any live broadcasts at the moment', + empty_message='You do not have any live alerts at the moment', ), previous_broadcasts=render_template( 'views/broadcast/partials/dashboard-table.html', broadcasts=broadcast_messages.with_status('cancelled', 'completed'), - empty_message='You do not have any previous broadcasts', + empty_message='You do not have any previous alerts', ), ) diff --git a/app/templates/views/broadcast/dashboard.html b/app/templates/views/broadcast/dashboard.html index 9ca2c4cb7..35f7b209b 100644 --- a/app/templates/views/broadcast/dashboard.html +++ b/app/templates/views/broadcast/dashboard.html @@ -18,7 +18,7 @@ {% endif %} -

Live broadcasts

+

Live alerts

{{ ajax_block( partials, @@ -34,7 +34,7 @@ 'pending_approval_broadcasts' ) }} -

Previous broadcasts

+

Previous alerts

{{ ajax_block( partials, diff --git a/tests/app/main/views/test_broadcast.py b/tests/app/main/views/test_broadcast.py index 8722a1f54..4bc981b82 100644 --- a/tests/app/main/views/test_broadcast.py +++ b/tests/app/main/views/test_broadcast.py @@ -164,9 +164,9 @@ def test_empty_broadcast_dashboard( assert [ normalize_spaces(row.text) for row in page.select('tbody tr .table-empty-message') ] == [ - 'You do not have any live broadcasts at the moment', - 'You do not have any broadcasts waiting for approval', - 'You do not have any previous broadcasts', + 'You do not have any live alerts at the moment', + 'You do not have any alerts waiting for approval', + 'You do not have any previous alerts', ] @@ -184,7 +184,7 @@ def test_broadcast_dashboard( ) assert normalize_spaces(page.select('main h2')[0].text) == ( - 'Live broadcasts' + 'Live alerts' ) assert [ normalize_spaces(row.text) for row in page.select('table')[0].select('tbody tr') @@ -202,7 +202,7 @@ def test_broadcast_dashboard( ] assert normalize_spaces(page.select('main h2')[2].text) == ( - 'Previous broadcasts' + 'Previous alerts' ) assert [ normalize_spaces(row.text) for row in page.select('table')[2].select('tbody tr')