|
// Copyright (c) Shenyang Leading Edge Intelligent Technology Co., Ltd. All rights reserved.
|
|
|
|
package base
|
|
|
|
import (
|
|
"LAPP_LF_MOM_BACKEND/grmi"
|
|
"xorm.io/core"
|
|
)
|
|
|
|
/******************************************************************************
|
|
*
|
|
* @Struct Name : Attribute
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : Attribute的实体映射
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-04-27 14:21:19
|
|
*
|
|
******************************************************************************/
|
|
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"`
|
|
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"`
|
|
AttrValue string `json:"Attribute-AttrValue" xorm:"-"`
|
|
Valst []AttributeValst `json:"Valst" xorm:"-"`
|
|
}
|
|
|
|
/******************************************************************************
|
|
*
|
|
* @Function Name : GetKey
|
|
*-----------------------------------------------------------------------------
|
|
*
|
|
* @Description : 获取实体的主键
|
|
*
|
|
* @Return Value : 实体的主键
|
|
*
|
|
* @Author : 代码生成器创建
|
|
*
|
|
* @Date : 2021-03-23 17:06:57
|
|
*
|
|
******************************************************************************/
|
|
func (self *Attribute) GetKey() core.PK {
|
|
return core.PK{self.PlantNr, self.AttrCode}
|
|
}
|