add empty string / none to choices for single LocationGroupCategories
This commit is contained in:
parent
ca237d7884
commit
662031c632
1 changed files with 1 additions and 0 deletions
|
@ -52,6 +52,7 @@ class EditorFormBase(ModelForm):
|
|||
if category.single:
|
||||
name = 'group_'+category.name
|
||||
initial = initial[0] if initial else ''
|
||||
choices = (('', '---'), )+choices
|
||||
field = ChoiceField(label=category.title, required=False, initial=initial, choices=choices)
|
||||
else:
|
||||
name = 'groups_'+category.name
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue