Merge pull request #3051 from alphagov/revise-thanks-wording

Make ‘thanks’ page consistent with support page
This commit is contained in:
Chris Hill-Scott
2019-07-12 12:04:41 +01:00
committed by GitHub
3 changed files with 100 additions and 68 deletions

View File

@@ -71,21 +71,11 @@ def feedback(ticket_type):
else:
severe = None
p1 = False
urgent = False
if in_business_hours():
# if we're in the office, it's urgent (aka we'll get back in 30 mins)
urgent = True
elif ticket_type == PROBLEM_TICKET_TYPE and severe:
# out of hours, it's only a p1 and it's only urgent if it's a p1
urgent = True
p1 = True
anonymous = (
(not form.email_address.data) and
(not current_user.is_authenticated)
)
out_of_hours_emergency = all((
ticket_type == PROBLEM_TICKET_TYPE,
not in_business_hours(),
severe,
))
if needs_triage(ticket_type, severe):
session['feedback_message'] = form.feedback.data
@@ -119,11 +109,17 @@ def feedback(ticket_type):
subject='Notify feedback',
message=feedback_msg,
ticket_type=ticket_type,
p1=p1,
p1=out_of_hours_emergency,
user_email=user_email,
user_name=user_name
)
return redirect(url_for('.thanks', urgent=urgent, anonymous=anonymous))
return redirect(url_for(
'.thanks',
out_of_hours_emergency=out_of_hours_emergency,
email_address_provided=(
current_user.is_authenticated or bool(form.email_address.data)
),
))
if not form.feedback.data:
form.feedback.data = get_prefilled_message()
@@ -148,9 +144,9 @@ def bat_phone():
def thanks():
return render_template(
'views/support/thanks.html',
urgent=convert_to_boolean(request.args.get('urgent')),
anonymous=convert_to_boolean(request.args.get('anonymous')),
logged_in=current_user.is_authenticated,
out_of_hours_emergency=convert_to_boolean(request.args.get('out_of_hours_emergency')),
email_address_provided=convert_to_boolean(request.args.get('email_address_provided')),
out_of_hours=not in_business_hours(),
)

View File

@@ -9,19 +9,26 @@
{% block maincolumn_content %}
<h1 class="heading-large">
Thanks for contacting GOV.UK Notify
Thanks for contacting us
</h1>
<p>
{% if anonymous %}
Well look into it
{% if out_of_hours_emergency %}
Well reply in the next 30 minutes.
{% else %}
Well get back to you
{% endif %}
{% if urgent %}
within 30 minutes.
{% else %}
by the next working day.
{% if email_address_provided %}
{% if out_of_hours %}
Well reply within one working day.
{% else %}
Well read your message in the next 30 minutes and reply within one
working day.
{% endif %}
{% else %}
{% if out_of_hours %}
Well read your message when were back in the office.
{% else %}
Well read your message in the next 30 minutes.
{% endif %}
{% endif %}
{% endif %}
</p>
<p>