package cn.estsh.i3plus.pojo.mes.bean;

import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Transient;
import java.io.Serializable;

/**
 * @Description:
 * @Author: jokelin
 * @Date: 2020/7/3 5:06 下午
 * @Modify:
 */
@Data
@Entity
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Table(name = "MES_JIT_ISSUE_CFG")
@Api("MES_客户JIT队列下达配置")
public class MesJitIssueCfg extends BaseBean implements Serializable {

    private static final long serialVersionUID = 1475207048628221791L;

    @Column(name = "CUST_PLANT_CODE")
    @ApiParam("客户工厂代码")
    private String custPlantCode;

    @Column(name = "QTY")
    @ApiParam("配置数量")
    private Integer qty;

    @Column(name = "THRESHOLD_QTY")
    @ApiParam("触发阈值")
    private Integer thresholdQty;

    @Column(name = "CFG_TYPE")
    @ApiParam("缓存类型")
    private Integer cfgType;

    @Column(name = "SEQ")
    @ApiParam("排序号")
    private Integer seq;

    @Transient
    @ApiParam("当前JIT缓存数")
    private Integer currentJitCacheNum;

    @Transient
    @ApiParam("其他工单数")
    private Integer otherWorkNum = 0;
}
