Require answer for multiselect
#1694
Answered
by
sisp
roaldarbol
asked this question in
Q&A
-
Hi! Have only used |
Beta Was this translation helpful? Give feedback.
Answered by
sisp
Jul 10, 2024
Replies: 1 comment 1 reply
-
You can define a validator: toppings:
type: str
help: Select pizza toppings
multiselect: true
choices:
- tomato
- cheese
- salami
default: [tomato]
validator: >
{%- if toppings | length < 1 -%}
You must select at least one topping
{%- endif -%} |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
roaldarbol
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You can define a validator: