mirror of
https://github.com/pretix/pretix.git
synced 2026-08-21 12:36:26 +00:00
Co-authored-by: Raphael Michel <michel@rami.io>
This commit is contained in:
co-authored by
Raphael Michel
parent
89e8d3d12f
commit
80b6a3d27d
@@ -550,7 +550,8 @@ class BaseQuestionsForm(forms.Form):
|
||||
|
||||
if not self.all_optional:
|
||||
for q in question_cache.values():
|
||||
if question_is_required(q) and not d.get('question_%d' % q.pk):
|
||||
answer = d.get('question_%d' % q.pk)
|
||||
if question_is_required(q) and not answer and answer != 0:
|
||||
raise ValidationError({'question_%d' % q.pk: [_('This field is required')]})
|
||||
|
||||
return d
|
||||
|
||||
Reference in New Issue
Block a user