widelands-dev team mailing list archive
-
widelands-dev team
-
Mailing list archive
-
Message #07835
Re: [Merge] lp:~widelands-dev/widelands-website/django1_8 into lp:widelands-website
Review: Approve
http://bazaar.launchpad.net/~widelands-dev/widelands-website/django1_8/revision/415#wlpoll/models.py:
http://bazaar.launchpad.net/~widelands-dev/widelands-website/django1_8/revision/430:
According to the docs:
https://docs.djangoproject.com/en/1.9/ref/models/fields/#default, default is
either a default value or a callable object. So, the lambda should work:
closed_date = models.DateTimeField("date closed",
default = lambda: datetime.datetime.now() + datetime.timedelta(days=90), blank=True, null=True)
and the explicit function should work always
but the explicit function you have is much more readable, so I'd prefer that anyways.
http://bazaar.launchpad.net/~widelands-dev/widelands-website/django1_8/revision/454:
Interesting that this was changed, but makes sense. lgtm.
http://bazaar.launchpad.net/~widelands-dev/widelands-website/django1_8/revision/443:
lgtm. A nice functional improvement too.
> except creating a user over the admin page:
I think this is fine, we never did that anyways.
--
https://code.launchpad.net/~widelands-dev/widelands-website/django1_8/+merge/298561
Your team Widelands Developers is subscribed to branch lp:widelands-website.
Follow ups
References