Remove ‘Stop’ links from dashboard

Now you have to click in to cancel a broadcast instead.
This commit is contained in:
Chris Hill-Scott
2020-07-10 14:19:33 +01:00
parent 7d6dffc098
commit 15611d67d3
2 changed files with 2 additions and 3 deletions

View File

@@ -25,9 +25,8 @@
{% endcall %}
{% call field(align='right') %}
{% if item.status == 'broadcasting' %}
<p class="govuk-body letter-recipient-summary">
<p class="govuk-body govuk-!-margin-top-6 govuk-!-margin-bottom-0">
Live until {{ item.finishes_at|format_datetime_relative }}
<a href="{{ url_for('.cancel_broadcast_message', service_id=current_service.id, broadcast_message_id=item.id) }}" class="destructive-link destructive-link--no-visited-state">Stop broadcasting</a>
</p>
{% elif item.status == 'cancelled' %}
<p class="govuk-body govuk-!-margin-top-6 govuk-!-margin-bottom-0 govuk-hint">

View File

@@ -78,7 +78,7 @@ def test_broadcast_dashboard(
assert [
normalize_spaces(row.text) for row in page.select('table')[0].select('tbody tr')
] == [
'Example template To England and Scotland Live until tomorrow at 2:20am Stop broadcasting',
'Example template To England and Scotland Live until tomorrow at 2:20am',
]
assert [
normalize_spaces(row.text) for row in page.select('table')[1].select('tbody tr')