// Copyright (c) Shenyang Leading Edge Intelligent Technology Co., Ltd. All rights reserved.

package log

import (
	"LAPP_LF_MOM_BACKEND/grmi"
	"xorm.io/core"
)

/******************************************************************************
 *
 * @Struct Name              : ArtDemandLst
 *-----------------------------------------------------------------------------
 *
 * @Description              : ArtDemandLst的实体映射
 *
 * @Author                   : 代码生成器创建
 *
 * @Date                     : 2021-06-11 16:10:25
 *
 ******************************************************************************/
type ArtDemandLst struct {
	PlantNr            int           `xorm:"pk int 'PlantNr'" json:"LOG_ArtDemandLst-PlantNr"`
	DemandId           string        `xorm:"pk nvarchar(40) 'DemandId'" json:"LOG_ArtDemandLst-DemandId"`
	Pos                int           `xorm:"pk int 'Pos'" json:"LOG_ArtDemandLst-Pos"`
	ArtId              string        `xorm:"nvarchar(40) 'ArtId' not null" json:"LOG_ArtDemandLst-ArtId"`
	DemandTime         grmi.DateTime `xorm:"datetime2(7) 'DemandTime' not null" json:"LOG_ArtDemandLst-DemandTime"`
	DemandYear         int           `xorm:"int 'DemandYear' not null" json:"LOG_ArtDemandLst-DemandYear"`
	DemandMonth        int           `xorm:"int 'DemandMonth' not null" json:"LOG_ArtDemandLst-DemandMonth"`
	DemandWeek         int           `xorm:"int 'DemandWeek' not null" json:"LOG_ArtDemandLst-DemandWeek"`
	DemandDate         grmi.Date     `xorm:"date 'DemandDate' not null" json:"LOG_ArtDemandLst-DemandDate"`
	DemandHour         int           `xorm:"int 'DemandHour' not null" json:"LOG_ArtDemandLst-DemandHour"`
	DemandQty          float64       `xorm:"float 'DemandQty' not null" json:"LOG_ArtDemandLst-DemandQty"`
	QtyUomId           string        `xorm:"nvarchar(40) 'QtyUomId' not null" json:"LOG_ArtDemandLst-QtyUomId"`
	DemandObjId        string        `xorm:"nvarchar(40) 'DemandObjId' not null" json:"LOG_ArtDemandLst-DemandObjId"`
	DemandType         string        `xorm:"nvarchar(40) 'DemandType' not null" json:"LOG_ArtDemandLst-DemandType"`
	Status             int           `xorm:"int 'Status' not null" json:"LOG_ArtDemandLst-Status"`
	DemandSendTime     grmi.DateTime `xorm:"datetime 'DemandSendTime'" json:"LOG_ArtDemandLst-DemandSendTime"`
	DemandRecieveTime  grmi.DateTime `xorm:"datetime 'DemandRecieveTime'" json:"LOG_ArtDemandLst-DemandRecieveTime"`
	DemandConfirmTime  grmi.DateTime `xorm:"datetime 'DemandConfirmTime'" json:"LOG_ArtDemandLst-DemandConfirmTime"`
	DemandCloseTime    grmi.DateTime `xorm:"datetime 'DemandCloseTime'" json:"LOG_ArtDemandLst-DemandCloseTime"`
	DemandDeliveredQty float64       `xorm:"float 'DemandDeliveredQty' not null" json:"LOG_ArtDemandLst-DemandDeliveredQty"`
	DemandCtrlPara1    int           `xorm:"int 'DemandCtrlPara1' not null" json:"LOG_ArtDemandLst-DemandCtrlPara1"`
	DemandCtrlPara2    int           `xorm:"int 'DemandCtrlPara2' not null" json:"LOG_ArtDemandLst-DemandCtrlPara2"`
	DemandCtrlPara3    string        `xorm:"nvarchar(100) 'DemandCtrlPara3' not null" json:"LOG_ArtDemandLst-DemandCtrlPara3"`
	DemandCtrlPara4    string        `xorm:"nvarchar(100) 'DemandCtrlPara4' not null" json:"LOG_ArtDemandLst-DemandCtrlPara4"`
	DemandCtrlTime1    grmi.DateTime `xorm:"datetime 'DemandCtrlTime1'" json:"LOG_ArtDemandLst-DemandCtrlTime1"`
	DemandCtrlTime2    grmi.DateTime `xorm:"datetime 'DemandCtrlTime2'" json:"LOG_ArtDemandLst-DemandCtrlTime2"`
	OrderStatus        int           `xorm:"int 'OrderStatus' not null" json:"LOG_ArtDemandLst-OrderStatus"`
	UnproducedQty      float64       `xorm:"float 'UnproducedQty' not null" json:"LOG_ArtDemandLst-UnproducedQty"`
	OrderType          string        `xorm:"nvarchar(20) 'OrderType' not null" json:"LOG_ArtDemandLst-OrderType"`
	ProjectId          string        `xorm:"nvarchar(40) 'ProjectId' not null" json:"LOG_ArtDemandLst-ProjectId"`
	DemandStatus       int           `xorm:"int 'DemandStatus' not null" json:"LOG_ArtDemandLst-DemandStatus"`
	PlanResourceId     string        `xorm:"nvarchar(40) 'PlanResourceId'" json:"LOG_ArtDemandLst-PlanResourceId"`
	PlanStartDate      grmi.Date     `xorm:"date 'PlanStartDate'" json:"LOG_ArtDemandLst-PlanStartDate"`
	PlanEndDate        grmi.Date     `xorm:"date 'PlanEndDate'" json:"LOG_ArtDemandLst-PlanEndDate"`
	PlanStartTime      grmi.DateTime `xorm:"datetime 'PlanStartTime'" json:"LOG_ArtDemandLst-PlanStartTime"`
	PlanEndTime        grmi.DateTime `xorm:"datetime 'PlanEndTime'" json:"LOG_ArtDemandLst-PlanEndTime"`
	ActStartTime       grmi.DateTime `xorm:"datetime 'ActStartTime'" json:"LOG_ArtDemandLst-ActStartTime"`
	ActEndTime         grmi.DateTime `xorm:"datetime 'ActEndTime'" json:"LOG_ArtDemandLst-ActEndTime"`
	LastModify         grmi.DateTime `xorm:"datetime 'LastModify' not null updated" json:"LOG_ArtDemandLst-LastModify"`
	LastUser           string        `xorm:"nvarchar(20) 'LastUser' not null" json:"LOG_ArtDemandLst-LastUser"`
	CreateTime         grmi.DateTime `xorm:"datetime 'CreateTime' not null created" json:"LOG_ArtDemandLst-CreateTime"`
}

/******************************************************************************
 *
 * @Function Name            : GetKey
 *-----------------------------------------------------------------------------
 *
 * @Description              : 获取实体的主键
 *
 * @Return Value             : 实体的主键
 *
 * @Author                   : 代码生成器创建
 *
 * @Date                     : 2021-06-11 16:10:25
 *
 ******************************************************************************/
func (self *ArtDemandLst) GetKey() core.PK {
	return core.PK{self.PlantNr, self.DemandId, self.Pos}
}
