forked from CGM_Public/pretix_original
Fix #1446 - Migrate NullBooleanSelect from 1/2/3 to unknown/true/false
This commit is contained in:
@@ -369,9 +369,9 @@ class ItemCreateForm(I18nModelForm):
|
|||||||
class ShowQuotaNullBooleanSelect(forms.NullBooleanSelect):
|
class ShowQuotaNullBooleanSelect(forms.NullBooleanSelect):
|
||||||
def __init__(self, attrs=None):
|
def __init__(self, attrs=None):
|
||||||
choices = (
|
choices = (
|
||||||
('1', _('(Event default)')),
|
('unknown', _('(Event default)')),
|
||||||
('2', _('Yes')),
|
('true', _('Yes')),
|
||||||
('3', _('No')),
|
('false', _('No')),
|
||||||
)
|
)
|
||||||
super(forms.NullBooleanSelect, self).__init__(attrs, choices)
|
super(forms.NullBooleanSelect, self).__init__(attrs, choices)
|
||||||
|
|
||||||
@@ -379,9 +379,9 @@ class ShowQuotaNullBooleanSelect(forms.NullBooleanSelect):
|
|||||||
class TicketNullBooleanSelect(forms.NullBooleanSelect):
|
class TicketNullBooleanSelect(forms.NullBooleanSelect):
|
||||||
def __init__(self, attrs=None):
|
def __init__(self, attrs=None):
|
||||||
choices = (
|
choices = (
|
||||||
('1', _('Choose automatically depending on event settings')),
|
('unknown', _('Choose automatically depending on event settings')),
|
||||||
('2', _('Yes, if ticket generation is enabled in general')),
|
('true', _('Yes, if ticket generation is enabled in general')),
|
||||||
('3', _('Never')),
|
('false', _('Never')),
|
||||||
)
|
)
|
||||||
super(forms.NullBooleanSelect, self).__init__(attrs, choices)
|
super(forms.NullBooleanSelect, self).__init__(attrs, choices)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user