From 9721df0bc598d93467f9be9904388a5273a0fbed Mon Sep 17 00:00:00 2001 From: hoellen Date: Tue, 15 Jan 2019 16:41:58 +0100 Subject: [PATCH] fix default value for created_at and updated_at Use date instead of datetime for created_at and updated_at. --- core/admin/mailu/models.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/admin/mailu/models.py b/core/admin/mailu/models.py index 15685abd..9c3786b9 100644 --- a/core/admin/mailu/models.py +++ b/core/admin/mailu/models.py @@ -101,8 +101,8 @@ class Base(db.Model): } ) - created_at = db.Column(db.Date, nullable=False, default=datetime.now) - updated_at = db.Column(db.Date, nullable=True, onupdate=datetime.now) + created_at = db.Column(db.Date, nullable=False, default=date.today) + updated_at = db.Column(db.Date, nullable=True, onupdate=date.today) comment = db.Column(db.String(255), nullable=True)