diff --git a/app/models/broadcast_message.py b/app/models/broadcast_message.py index 27106be8e..372aec925 100644 --- a/app/models/broadcast_message.py +++ b/app/models/broadcast_message.py @@ -76,12 +76,6 @@ class BroadcastMessage(JSONModel): for parent in area.parents: yield parent - @property - def initial_area_names(self): - return [ - area.name for area in self.areas - ][:10] - @cached_property def polygons(self): return Polygons( diff --git a/app/templates/views/broadcast/partials/dashboard-table.html b/app/templates/views/broadcast/partials/dashboard-table.html index fd7a6eccd..1e1e559f1 100644 --- a/app/templates/views/broadcast/partials/dashboard-table.html +++ b/app/templates/views/broadcast/partials/dashboard-table.html @@ -15,12 +15,14 @@ {% call row_heading() %}
{{ item.template_name }} - + {{ item.content }} - - To {{ item.initial_area_names|formatted_list(before_each='', after_each='') }} - +
{% endcall %} {% call field(align='right') %} diff --git a/tests/app/main/views/test_broadcast.py b/tests/app/main/views/test_broadcast.py index fc1c9d285..be55d22bf 100644 --- a/tests/app/main/views/test_broadcast.py +++ b/tests/app/main/views/test_broadcast.py @@ -302,7 +302,7 @@ def test_broadcast_dashboard( assert [ normalize_spaces(row.text) for row in page.select('table')[0].select('tbody tr') ] == [ - 'Example template This is a test To England and Scotland Live until tomorrow at 2:20am', + 'Example template This is a test England Scotland Live until tomorrow at 2:20am', ] assert normalize_spaces(page.select('main h2')[1].text) == ( @@ -311,7 +311,7 @@ def test_broadcast_dashboard( assert [ normalize_spaces(row.text) for row in page.select('table')[1].select('tbody tr') ] == [ - 'Example template This is a test To England and Scotland Prepared by Test User', + 'Example template This is a test England Scotland Prepared by Test User', ] @@ -361,8 +361,8 @@ def test_previous_broadcasts_page( assert [ normalize_spaces(row.text) for row in page.select('table')[0].select('tbody tr') ] == [ - 'Example template This is a test To England and Scotland Stopped 10 February at 2:20am', - 'Example template This is a test To England and Scotland Finished yesterday at 8:20pm', + 'Example template This is a test England Scotland Stopped 10 February at 2:20am', + 'Example template This is a test England Scotland Finished yesterday at 8:20pm', ]