mirror of
https://github.com/pretix/pretix.git
synced 2026-05-06 15:24:02 +00:00
Fixed wrong ModelChoiceField queryset in voucher form
This commit is contained in:
@@ -10,5 +10,9 @@ class VoucherForm(I18nModelForm):
|
||||
'code', 'valid_until', 'block_quota', 'allow_ignore_quota', 'price', 'item'
|
||||
]
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
super().__init__(*args, **kwargs)
|
||||
self.fields['item'].queryset = self.instance.event.items.all()
|
||||
|
||||
def _get_validation_exclusions(self):
|
||||
return []
|
||||
|
||||
Reference in New Issue
Block a user