-
-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
embed model not generated
type BaseModel[statusT ~int32] struct {
Id string `gorm:"column:id;not null;primaryKey;type:uuid;autoIncrement:false;comment:主键id"`
CreatedAt time.Time `gorm:"column:created_at;not null;index;type:timestamp(6);comment:创建时间"`
UpdatedAt time.Time `gorm:"column:updated_at;not null;index;type:timestamp(6);comment:更新时间"`
Status statusT `gorm:"column:status;default:0;not null;type:smallint;index;comment:状态"`
Remark string `gorm:"column:remark;type:text;not null;default:'';comment:备注"`
}
type Permission struct {
kk_models.BaseModel[PBPermission_PermissionStatus]
ApiTag string `gorm:"column:api_tag;type:text;not null;index;comment:分类"`
ApiId string `gorm:"column:api_id;type:text;not null;uniqueIndex;comment:api唯一标识"`
ApiName string `gorm:"column:api_name;type:text;not null;comment:api名称"`
}generated code
var Permission = struct {
ApiTag field.String
ApiId field.String
ApiName field.String
}{
ApiTag: field.String{}.WithColumn("api_tag"),
ApiId: field.String{}.WithColumn("api_id"),
ApiName: field.String{}.WithColumn("api_name"),
}Metadata
Metadata
Assignees
Labels
No labels