package com.muchinfo.mtp3pojos.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * <p>
 * 品种要素项表
 * </p>
 *
 * @author XKF
 * @since 2024-11-29
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("DGFACTORYITEMTYPE")
@ApiModel(value="Dgfactoryitemtype对象", description="品种要素项表")
public class Dgfactoryitemtype extends Model<Dgfactoryitemtype> {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "要素项类型ID(SEQ_DGFACTORYITEMTYPE) 1-999：预留为特殊类型 选择项： 1:仓库 2.品牌 3:规格 属性项： 100:品牌 101 年份 >1000（序列自增） 选择项 录入项")
    @TableId(value = "DGFACTORYITEMTYPEID")
    private Long dgfactoryitemtypeid;

    @ApiModelProperty(value = "品种ID")
    @TableField("DELIVERYGOODSID")
    private Long deliverygoodsid;

    @ApiModelProperty(value = "要素项类型名称")
    @TableField("ITEMTYPENAME")
    private String itemtypename;

    @ApiModelProperty(value = "要素项类型模式 -1:选择项(品种) 2:录入项(品种) 3:属性项(通用)")
    @TableField("ITEMTYPEMODE")
    private Integer itemtypemode;

    @ApiModelProperty(value = "顺序")
    @TableField("ORDERINDEX")
    private Long orderindex;

    @ApiModelProperty(value = "单位ID - [录入项]")
    @TableField("UNITID")
    private Integer unitid;

    @ApiModelProperty(value = "最小变动值 - [录入项]")
    @TableField("MINIVALUE")
    private Long minivalue;

    @ApiModelProperty(value = "最小变动值小数位 - [录入项]")
    @TableField("MINIVALUEDP")
    private Long minivaluedp;

    @ApiModelProperty(value = "创建人")
    @TableField("CREATORID")
    private Long creatorid;

    @ApiModelProperty(value = "创建时间")
    @TableField("CREATETIME")
    private Date createtime;

    @ApiModelProperty(value = "更新人")
    @TableField("UPDATORID")
    private Long updatorid;

    @ApiModelProperty(value = "更新时间")
    @TableField("UPDATETIME")
    private Date updatetime;

    @ApiModelProperty(value = "是否有效 - 0:无效 1:有效")
    @TableField("ISVALID")
    private Integer isvalid;

    @ApiModelProperty(value = "是否固定 - 0:不固定 1:固定")
    @TableField("ISFIXED")
    private Integer isfixed;

    @TableField(select = false)
    private BigDecimal minivalue2;
    @TableField(select = false)
    private String unitname;
    @TableField(select = false)
    private String typevalue;
    @TableField(select = false)
    private List<Dgfactoryitem> dgfilist;

    public Serializable pkVal() {
        return this.dgfactoryitemtypeid;
    }

}
