package cn.estsh.i3plus.ext.mes.pcn.pojo.model.jx;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiParam;
import lombok.Data;

import java.io.Serializable;

/**
 * @author wangjie
 * @version 1.0
 * @date 2021/1/15 15:32
 **/
@Data
@ApiModel("总检验结果 MODEL")
public class JxOqcLastCheckModel implements Serializable {

    private static final long serialVersionUID = 3946056930962962292L;

    @ApiParam("生产工单")
    private String workOrderNo;

    @ApiParam("生产线")
    private String workCenterCode;

    @ApiParam("物料号")
    private String partNo;

    @ApiParam("物料名称")
    private String partNameRdd;

    @ApiParam("作业时间")
    private String workTime;

    @ApiParam("班次代码")
    private String shiftCode;

    @ApiParam("工单计划数量")
    private Double planQty;

    @ApiParam("班次完工数量")
    private Double qty;

    @ApiParam("工单剩余完工数量")
    private Double unFinishQty;

    @ApiParam("抽检数量")
    private Double spotCheckQty;

    @ApiParam("检测范围")
    private Double checkLimit;

    @ApiParam("总检测单号")
    private String checkNo;

    @ApiParam("总检测结果")
    private Integer checkResult;

    @ApiParam("总检测结果名称")
    private String checkResultName;

    @ApiParam("备注")
    private String remark;

    @ApiParam("检测时间")
    private String confirmTime;

    @ApiParam("检测人员")
    private String checkUser;

    @ApiParam("组织代码")
    public String organizeCode;

    @ApiParam("操作人")
    public String userInfo;

    @ApiParam("产量统计ID")
    private Long id;

    @ApiParam("产量统计PID")
    private Long pid;

    @ApiParam("是否写入返工范围")
    private Integer isAddReworkRange;

    @ApiParam("作业时间开始")
    private String workTimeStart;

    @ApiParam("作业时间结束")
    private String workTimeEnd;

    @ApiParam("组件抽检只读状态")
    private Boolean zjCheckBoo = true;

    @ApiParam("总检合格只读状态")
    private Boolean qcBoo = true;

    @ApiParam("总检不合格只读状态")
    private Boolean unQcBoo = true;

    @ApiParam("颜色")
    private String color;

    @ApiParam("工单类型")
    private Integer workOrderType;

    @ApiParam("工单类型描述")
    private String workOrderTypeName;

    public JxOqcLastCheckModel() {
    }

    public JxOqcLastCheckModel(Long id, Long pid, String organizeCode, String workOrderNo, String workCenterCode, String partNo, String partNameRdd, String workTime, String shiftCode,
                               Double spotCheckQty, Double checkLimit, String checkNo, Integer checkResult, String remark, String confirmTime, String checkUser) {
        this.id = id;
        this.pid = pid;
        this.organizeCode = organizeCode;
        this.workOrderNo = workOrderNo;
        this.workCenterCode = workCenterCode;
        this.partNo = partNo;
        this.partNameRdd = partNameRdd;
        this.workTime = workTime;
        this.shiftCode = shiftCode;
        this.spotCheckQty = spotCheckQty;
        this.checkLimit = checkLimit;
        this.checkNo = checkNo;
        this.checkResult = checkResult;
        this.remark = remark;
        this.confirmTime = confirmTime;
        this.checkUser = checkUser;
    }

    public JxOqcLastCheckModel(Long id, Long pid, String organizeCode, String workOrderNo, String workCenterCode, String partNo, String partNameRdd, String workTime, String shiftCode,
                               Double spotCheckQty, Double checkLimit, String checkNo, Integer checkResult, String remark, String confirmTime, String checkUser, Integer workOrderType) {
        this.id = id;
        this.pid = pid;
        this.organizeCode = organizeCode;
        this.workOrderNo = workOrderNo;
        this.workCenterCode = workCenterCode;
        this.partNo = partNo;
        this.partNameRdd = partNameRdd;
        this.workTime = workTime;
        this.shiftCode = shiftCode;
        this.spotCheckQty = spotCheckQty;
        this.checkLimit = checkLimit;
        this.checkNo = checkNo;
        this.checkResult = checkResult;
        this.remark = remark;
        this.confirmTime = confirmTime;
        this.checkUser = checkUser;
        this.workOrderType = workOrderType;
    }

    public JxOqcLastCheckModel(Long id, Long pid, String organizeCode, String workOrderNo, String workCenterCode, String partNo, String partNameRdd, String workTime, String shiftCode,
                               Double spotCheckQty, Double checkLimit, String checkNo, Integer checkResult, String remark, String confirmTime, String checkUser, Integer workOrderType, Integer isAddReworkRange) {
        this.id = id;
        this.pid = pid;
        this.organizeCode = organizeCode;
        this.workOrderNo = workOrderNo;
        this.workCenterCode = workCenterCode;
        this.partNo = partNo;
        this.partNameRdd = partNameRdd;
        this.workTime = workTime;
        this.shiftCode = shiftCode;
        this.spotCheckQty = spotCheckQty;
        this.checkLimit = checkLimit;
        this.checkNo = checkNo;
        this.checkResult = checkResult;
        this.remark = remark;
        this.confirmTime = confirmTime;
        this.checkUser = checkUser;
        this.workOrderType = workOrderType;
        this.isAddReworkRange = isAddReworkRange;
    }

    public JxOqcLastCheckModel(Boolean boo) {
        this.qcBoo = boo;
        this.unQcBoo = boo;
    }

}
