GAAS 广汽安道拓GFrame金属件MOM项目
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 

28 lines
1.4 KiB

package base
import (
"leit.com/LAPP_GAAS_GFrame/grmi"
"xorm.io/core"
)
//Attribute的实体映射
type Attribute struct {
PlantNr int `xorm:"pk int 'PlantNr'" json:"Attribute-PlantNr"`
AttrCode int `xorm:"pk int 'AttrCode'" json:"Attribute-AttrCode"`
AttrName string `xorm:"nvarchar(100) 'AttrName' not null" json:"Attribute-AttrName"`
Descr string `xorm:"nvarchar(100) 'Descr' not null" json:"Attribute-Descr"`
AttrGroup int `xorm:"int 'AttrGroup' not null" json:"Attribute-AttrGroup"`
ShortCode string `xorm:"nvarchar(20) 'ShortCode' not null" json:"Attribute-ShortCode"`
AttrType int `xorm:"int 'AttrType' not null" json:"Attribute-AttrType"`
AttrDataType int `xorm:"int 'AttrDataType' not null" json:"Attribute-AttrDataType"`
AttrValType int `xorm:"int 'AttrValType' not null" json:"Attribute-AttrValType"`
ValFormat string `xorm:"nvarchar(100) 'ValFormat' not null" json:"Attribute-ValFormat"`
LastModify grmi.DateTime `xorm:"datetime 'LastModify' not null updated" json:"Attribute-LastModify"`
LastUser string `xorm:"nvarchar(20) 'LastUser' not null" json:"Attribute-LastUser"`
CreateTime grmi.DateTime `xorm:"datetime 'CreateTime' not null created" json:"Attribute-CreateTime"`
}
//获取Attribute的主键
func (self *Attribute) GetKey() core.PK {
return core.PK{self.PlantNr, self.AttrCode}
}