Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions lung_cancer_screening/questions/forms/ethnicity_form.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,7 @@ def __init__(self, *args, **kwargs):
choices=EthnicityValues.choices,
label="What is your ethnic background?",
widget=forms.RadioSelect,
label_classes="nhsuk-fieldset__legend--l",
label_is_page_heading=True,
hint=(
"Your ethnicity may impact your chances of "
"developing lung cancer."
),
label_classes="nhsuk-fieldset__legend--m",
error_messages={
'required': 'Select your ethnic background'
}
Expand Down
11 changes: 11 additions & 0 deletions lung_cancer_screening/questions/jinja2/ethnicity.jinja
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{% extends 'question_form.jinja' %}

{% block prelude %}

<h1 class="nhsuk-heading-l">Help us give you an accurate result by telling us your ethnic background</h1>

<p>Your ethnicity may impact your chances of developing lung cancer.</p>

<p>You do not have to tell us your ethnic background but this may affect the accuracy of your result.</p>

{% endblock prelude %}
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class EthnicityValues(models.TextChoices):
MIXED = "M", "Mixed or multiple ethnic groups"
WHITE = "W", "White"
OTHER = "O", "Other ethnic group"
PREFER_NOT_TO_SAY = "N", "I'd prefer not to say"
PREFER_NOT_TO_SAY = "N", "Prefer not to say"


class EthnicityResponse(BaseModel):
Expand Down
2 changes: 1 addition & 1 deletion lung_cancer_screening/questions/views/ethnicity.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@


class EthnicityView(QuestionBaseView):
template_name = "question_form.jinja"
template_name = "ethnicity.jinja"
form_class = EthnicityForm
model = EthnicityResponse
success_url = reverse_lazy("questions:education")
Expand Down