fix(model): 修改BaseModel主键ID数据类型
- 将Id字段从uint类型改为int类型 - 保持GORM标签和JSON序列化配置不变main v1.0.1028
parent
828e19de93
commit
427f568db6
|
|
@ -8,7 +8,7 @@ import (
|
||||||
|
|
||||||
// BaseModel 基础模型
|
// BaseModel 基础模型
|
||||||
type BaseModel struct {
|
type BaseModel struct {
|
||||||
Id uint `gorm:"column:id;primaryKey;autoIncrement;common:主键ID" json:"id"`
|
Id int `gorm:"column:id;primaryKey;autoIncrement;common:主键ID" json:"id"`
|
||||||
CreateTime string `gorm:"autoCreateTime;column:create_time;type:datetime" json:"create_time"`
|
CreateTime string `gorm:"autoCreateTime;column:create_time;type:datetime" json:"create_time"`
|
||||||
UpdateTime string `gorm:"autoUpdateTime;column:update_time;type:datetime" json:"update_time"`
|
UpdateTime string `gorm:"autoUpdateTime;column:update_time;type:datetime" json:"update_time"`
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue