fix bad import for Django 1.3 and fixed save() with args in RunInfo models
parent
5469a1d82a
commit
a414ca1ec8
|
@ -167,9 +167,9 @@ class RunInfo(models.Model):
|
|||
help_text=u"A comma sepearted list of questions to skip"
|
||||
)
|
||||
|
||||
def save(self):
|
||||
def save(self, **kwargs):
|
||||
self.random = (self.random or '').lower()
|
||||
super(RunInfo, self).save()
|
||||
super(RunInfo, self).save(**kwargs)
|
||||
|
||||
def set_cookie(self, key, value):
|
||||
"runinfo.set_cookie(key, value). If value is None, delete cookie"
|
||||
|
@ -386,4 +386,4 @@ class Answer(models.Model):
|
|||
|
||||
def check_answer(self):
|
||||
"Confirm that the supplied answer matches what we expect"
|
||||
return True
|
||||
return True
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
from questionnaire import *
|
||||
from django.conf.urls.static import settings
|
||||
from django.conf import settings
|
||||
from django.utils.translation import ugettext as _
|
||||
from django.utils.simplejson import dumps
|
||||
|
||||
|
@ -80,4 +80,4 @@ def digits(number):
|
|||
else:
|
||||
return len(number.split(',')[1])
|
||||
else:
|
||||
return 0
|
||||
return 0
|
||||
|
|
Loading…
Reference in New Issue