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 :物料校验项
 * @Reference :
 * @Author : wangjie
 * @CreateDate : 2019-04-02
 * @Modify:
 **/
@Data
@Entity
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Table(name = "MES_PART_CHECK")
@Api("物料校验项")
public class MesPartCheck extends BaseBean implements Serializable {

    private static final long serialVersionUID = -7706120594398072630L;

    @Column(name = "PART_NO")
    @ApiParam("物料号")
    private String partNo;

    @Column(name = "OBJECT_CODE")
    @ApiParam("对象代码")
    private String objectCode;

    @Column(name = "CHECK_SPEL_EXPRESS")
    @ApiParam("校验表达式")
    private String checkSpelExpress;

    @Column(name = "TYPE_SPEL_EXPRESS")
    @ApiParam("类型表达式")
    private String typeSpelExpress;

    @Column(name = "RECORD_NUM_SPEL_EXPRESS")
    @ApiParam("记录数量表达式")
    private String recordNumSpelExpress;

    @Column(name = "DATA_TYPE")
    @ApiParam("数据查询类型")
    private Integer dataType = 1;

    @Column(name = "LIMIT_TIMES")
    @ApiParam("限定检测次数")
    private Integer limitTimes;

    @Column(name = "RECORD_NUM_DESC")
    @ApiParam("校验表达式描述")
    private String recordNumDesc;

    @Transient
    @ApiParam("复核结果")
    private Integer reviewResult = 1;

    @Transient
    @ApiParam("对象名称")
    private String objectCodeName;

    @Column(name = "WORK_CENTER_CODE")
    @ApiParam("产线")
    private String workCenterCode;
}
