Fix a bug with default datetime in models
This commit is contained in:
parent
5ab4342090
commit
736a5ae44f
@ -10,7 +10,7 @@ class ModuleStatus(peewee.Model):
|
|||||||
module = peewee.CharField(max_length=255) # Module name
|
module = peewee.CharField(max_length=255) # Module name
|
||||||
origin = peewee.CharField(max_length=255) # Origin of the update
|
origin = peewee.CharField(max_length=255) # Origin of the update
|
||||||
datetime = peewee.DateTimeField(
|
datetime = peewee.DateTimeField(
|
||||||
default=arrow.utcnow().replace(microsecond=0).datetime)
|
default=lambda: arrow.utcnow().replace(microsecond=0).datetime)
|
||||||
is_good = peewee.BooleanField() # True if good, False if bad
|
is_good = peewee.BooleanField() # True if good, False if bad
|
||||||
|
|
||||||
class Meta:
|
class Meta:
|
||||||
|
Loading…
Reference in New Issue
Block a user