From 8240adafb08a0304ab29ea47e4982a2710e12195 Mon Sep 17 00:00:00 2001 From: wenjianzhang Date: Tue, 31 Mar 2020 21:42:24 +0800 Subject: [PATCH] Update config.go --- models/config.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/models/config.go b/models/config.go index b9860158..1194ab59 100644 --- a/models/config.go +++ b/models/config.go @@ -24,7 +24,7 @@ type Config struct { CreateTime string `json:"createTime" gorm:"column:create_time"` UpdateBy string `json:"updateBy" gorm:"column:update_by"` UpdateTime string `json:"updateTime" gorm:"column:update_time"` - DataScope string `json:"dataScope" gorm:"_"` + DataScope string `json:"dataScope" gorm:"-"` Params string `json:"params" gorm:"column:params"` IsDel string `json:"isDel" gorm:"column:is_del"` } @@ -34,6 +34,7 @@ func (e *Config) Create() (Config, error) { var doc Config doc.IsDel = "0" e.CreateTime = utils.GetCurrntTime() + e.UpdateTime = utils.GetCurrntTime() result := orm.Eloquent.Table("sys_config").Create(&e) if result.Error != nil { err := result.Error