Use table name constant in Cols for type safety
This commit is contained in:
34
app/model/dbmodel/ps_cms_role_lang.go
Normal file
34
app/model/dbmodel/ps_cms_role_lang.go
Normal file
@@ -0,0 +1,34 @@
|
||||
// Code generated by gorm.io/gen. DO NOT EDIT.
|
||||
// Code generated by gorm.io/gen. DO NOT EDIT.
|
||||
// Code generated by gorm.io/gen. DO NOT EDIT.
|
||||
|
||||
package dbmodel
|
||||
|
||||
import "git.ma-al.com/goc_marek/gormcol"
|
||||
|
||||
const TableNamePsCmsRoleLang = "ps_cms_role_lang"
|
||||
|
||||
// PsCmsRoleLang mapped from table <ps_cms_role_lang>
|
||||
type PsCmsRoleLang struct {
|
||||
IDCmsRole int32 `gorm:"column:id_cms_role;primaryKey" json:"id_cms_role"`
|
||||
IDLang int32 `gorm:"column:id_lang;primaryKey" json:"id_lang"`
|
||||
IDShop int32 `gorm:"column:id_shop;primaryKey" json:"id_shop"`
|
||||
Name *string `gorm:"column:name" json:"name"`
|
||||
}
|
||||
|
||||
// TableName PsCmsRoleLang's table name
|
||||
func (*PsCmsRoleLang) TableName() string {
|
||||
return TableNamePsCmsRoleLang
|
||||
}
|
||||
|
||||
var PsCmsRoleLangCols = struct {
|
||||
IDCmsRole gormcol.Field
|
||||
IDLang gormcol.Field
|
||||
IDShop gormcol.Field
|
||||
Name gormcol.Field
|
||||
}{
|
||||
IDCmsRole: gormcol.Field{Table: TableNamePsCmsRoleLang, Column: "id_cms_role"},
|
||||
IDLang: gormcol.Field{Table: TableNamePsCmsRoleLang, Column: "id_lang"},
|
||||
IDShop: gormcol.Field{Table: TableNamePsCmsRoleLang, Column: "id_shop"},
|
||||
Name: gormcol.Field{Table: TableNamePsCmsRoleLang, Column: "name"},
|
||||
}
|
||||
Reference in New Issue
Block a user