From e836991c23794a64eeedd02c6ee33051a2dd8df9 Mon Sep 17 00:00:00 2001 From: yumoqing Date: Thu, 9 Jul 2026 15:04:44 +0800 Subject: [PATCH] fix: add CURRENT_TIMESTAMP defaults to created_at/updated_at --- models/sub_distributors.json | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/models/sub_distributors.json b/models/sub_distributors.json index 3ccf012..ae17091 100644 --- a/models/sub_distributors.json +++ b/models/sub_distributors.json @@ -111,12 +111,14 @@ "name": "created_at", "title": "创建时间", "type": "datetime", - "nullable": "no" + "nullable": "no", + "default": "CURRENT_TIMESTAMP" }, { "name": "updated_at", "title": "更新时间", - "type": "datetime" + "type": "datetime", + "default": "CURRENT_TIMESTAMP" } ], "indexes": [ @@ -158,4 +160,4 @@ "cond": "parentid='sub_distributor_status'" } ] -} +} \ No newline at end of file