package
Version:
v0.0.0-...-3030a97
Opens a new window with list of versions in this module.
Published: Mar 14, 2024
License: Apache-2.0
Opens a new window with license information.
Imports: 5
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
func MakeCondition(query interface{}) func(db *gorm.DB) *gorm.DB
MakeCondition 生成查询条件
type ControlBy struct {
CreateBy int `json:"create_by" gorm:"index;comment:创建者"`
UpdateBy int `json:"update_by" gorm:"index;comment:更新者"`
}
type Model struct {
ID int64 `gorm:"primaryKey;autoIncrement;comment:主键编码" json:"id"`
ModelTime
}
type ModelTime struct {
CreateTime time.Time `gorm:"column:create_time; autoCreateTime; <-:create" json:"create_time,omitempty"`
UpdateTime time.Time `gorm:"column:update_time; autoUpdateTime; <-;" json:"update_time,omitempty"`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.