Skip to content

Commit 25db07d

Browse files
Consent screen fixes (#154)
Also adds consent to the check your answers page: ![Screenshot 2025-01-10 at 10 17 03](https://github.com/user-attachments/assets/1b774124-9f99-477d-af04-597e39891ba1) ![Screenshot 2025-01-10 at 10 17 21](https://github.com/user-attachments/assets/607c66d7-8ada-44ab-8f1b-014d8a473bd5)
1 parent a481d26 commit 25db07d

File tree

3 files changed

+27
-4
lines changed

3 files changed

+27
-4
lines changed

app/views/vaccinate/check.html

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,14 @@
1010
{{ backLink({ href: "/vaccinate/injection-site" }) }}
1111
{% endblock %}
1212

13+
{% set consentHtml %}
14+
{% if data.consent == data.patientName %}
15+
Patient
16+
{% else %}
17+
{{ data.consentName | first }}, {{ data.consent }}
18+
{% endif %}
19+
{% endset %}
20+
1321
{% block content %}
1422
<div class="nhsuk-grid-row">
1523
<div class="nhsuk-grid-column-two-thirds">
@@ -204,6 +212,23 @@ <h2 class="nhsuk-heading-m">Vaccination</h2>
204212
]
205213
}
206214
} if ((data.vaccine == "Pertussis") or (data.eligibility | arrayOrStringIncludes("Pregnant"))),
215+
{
216+
key: {
217+
text: "Consent given by"
218+
},
219+
value: {
220+
text: consentHtml
221+
},
222+
actions: {
223+
items: [
224+
{
225+
href: "/vaccinate/consent",
226+
text: "Change",
227+
visuallyHiddenText: "consnet"
228+
}
229+
]
230+
}
231+
},
207232
{
208233
key: {
209234
text: "Injection site"

app/views/vaccinate/consent.html

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@
1414
<div class="nhsuk-grid-row">
1515
<div class="nhsuk-grid-column-two-thirds">
1616

17-
18-
1917
<form action="/vaccinate/injection-site" method="post" novalidate>
2018

2119
{% set otherConsentHtml %}
@@ -26,7 +24,7 @@
2624
},
2725
id: "consentName",
2826
name: "consentName",
29-
value: data.consentName
27+
value: (data.consentName | first)
3028
}) }}
3129

3230
{% endset %}

app/views/vaccinate/patient-estimated-due-date.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
<div class="nhsuk-grid-row">
1515
<div class="nhsuk-grid-column-two-thirds">
1616

17-
<form action="/vaccinate/injection-site" method="post" novalidate>
17+
<form action="/vaccinate/consent" method="post" novalidate>
1818

1919
{{ dateInput({
2020
id: "pregnancyDueDate",

0 commit comments

Comments
 (0)