Convert radios on research consent (basic)

This commit is contained in:
Tom Byers
2020-06-26 21:56:08 +01:00
parent 25b89dd30a
commit d0b8610cd8
2 changed files with 5 additions and 3 deletions

View File

@@ -1569,13 +1569,16 @@ class EstimateUsageForm(StripWhitespaceForm):
things='letters',
format_error_suffix='you expect to send',
)
consent_to_research = RadioField(
consent_to_research = GovukRadiosField(
'Can we contact you when were doing user research?',
choices=[
('yes', 'Yes'),
('no', 'No'),
],
thing='yes or no',
param_extensions={
'hint': {'text': 'You do not have to take part and you can unsubscribe at any time'}
}
)
at_least_one_volume_filled = True

View File

@@ -3,7 +3,6 @@
{% from "components/form.html" import form_wrapper %}
{% from "components/page-header.html" import page_header %}
{% from "components/page-footer.html" import page_footer %}
{% from "components/radios.html" import radios %}
{% block service_page_title %}
Tell us how many messages you expect to send
@@ -39,7 +38,7 @@
"hint": {"text": "For example, 50,000"},
}) }}
</div>
{{ radios(form.consent_to_research, hint='You do not have to take part and you can unsubscribe at any time') }}
{{ form.consent_to_research }}
{{ page_footer('Continue') }}
{% endcall %}
</div>