allow to save an empty poll
This commit is contained in:
parent
48c53d3cd0
commit
4339c3ae8a
@ -32,4 +32,5 @@ class OptionForm(forms.Form, CssClassMixin):
|
||||
label=value,
|
||||
initial=weight,
|
||||
min_value=-2,
|
||||
required=False,
|
||||
)
|
||||
|
@ -33,7 +33,7 @@ class TextOption(BaseOption):
|
||||
class Vote(models.Model):
|
||||
option = models.ForeignKey(BaseOption)
|
||||
#profile = models.ForeignKey(Profile) # TODO: we need a person+ here
|
||||
weight = models.IntegerField(default=1)
|
||||
weight = models.IntegerField(default=1, null=True)
|
||||
value = models.CharField(max_length=255, null=True)
|
||||
|
||||
def get_weight(self, raw=False):
|
||||
|
Loading…
Reference in New Issue
Block a user