package cn.estsh.i3plus.ext.mes.pojo.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: xiangming.liao
 * @Date: 2021/03/12
 * @Modify:
 */
@Data
@Entity
@DynamicInsert
@DynamicUpdate
@EqualsAndHashCode(callSuper = true)
@Table(name = "MES_EXTERIOR_SCRATCH_PROOF_DETAIL")
@Api("MES_外观防划伤明细")
public class MesExteriorScratchProofDetail extends BaseBean implements Serializable {

    private static final long serialVersionUID = 3987723045664728377L;

    @Column(name = "WORK_CENTER_CODE")
    @ApiParam("生产线代码")
    private String workCenterCode;

    @Column(name = "WORK_CELL_CODE")
    @ApiParam(value = "工位代码")
    public String workCellCode;

    @Column(name = "FILE_ID")
    @ApiParam("文件编号")
    private Long fileId;

    @Column(name = "ORDER_TIME")
    @ApiParam(value = "单据时间")
    private String orderTime;

    @Column(name="ORDER_NO")
    @ApiParam(value ="单据编号")
    private String orderNo;

    /**
     * OK显示O，NG显示X
     */
    @Column(name = "CHECK_RESULT")
    @ApiParam("点检结果")
    private Integer checkResult;

    @Column(name = "CHECK_USER")
    @ApiParam("点检人员")
    private String checkUser;

    @Column(name = "CHECK_TIME")
    @ApiParam("点检时间")
    private String checkTime;

    /**
     * 10=是，20=否
     */
    @Column(name = "SHIFT_GROUP_CHECK")
    @ApiParam("班组确认")
    private Integer shiftGroupCheck;

    @Column(name = "SHIFT_GROUP_CHECK_USER")
    @ApiParam("班组确认人")
    private String shiftGroupCheckUser;

    @Column(name = "SHIFT_GROUP_CHECK_TIME")
    @ApiParam("班组确认时间")
    private String shiftGroupCheckTime;

    /**
     * 10=是，20=否
     */
    @Column(name = "QUALITY_CHECK")
    @ApiParam("品质确认")
    private Integer qualityCheck;

    @Column(name = "QUALITY_CHECK_USER")
    @ApiParam("品质确认人")
    private String qualityCheckUser;

    @Column(name = "QUALITY_CHECK_TIME")
    @ApiParam("品质确认时间")
    private String qualityCheckTime;

    @Column(name = "remark")
    @ApiParam(value = "备注")
    public String remark;

    @Transient
    @ApiParam(
            value = "点检开始日期查询用，查询截至日期",
            example = "2021-01-01 00:00:00"
    )
    public String checkStartTime;
    @Transient
    @ApiParam(
            value = "点检结束日期查询用，查询截至日期",
            example = "2022-01-01 00:00:00"
    )
    public String checkEndTime;
}
