From c97eab04305d8e710a161c56a340af6394c1e1f3 Mon Sep 17 00:00:00 2001 From: Michele-Alberti <62114934+Michele-Alberti@users.noreply.github.com> Date: Fri, 1 Mar 2024 18:32:19 +0100 Subject: [PATCH] fix(models.py): fix error in server default for date in stats table now date is assigned database-side --- dlunch/models.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/dlunch/models.py b/dlunch/models.py index 195546b..0595f61 100755 --- a/dlunch/models.py +++ b/dlunch/models.py @@ -318,8 +318,7 @@ class Stats(Data): date = Column( Date, nullable=False, - default=datetime.utcnow(), - server_default=func.current_timestamp(), + server_default=func.current_date(), ) guest = Column( String(20),