package cn.ezhizao.project.websocket.domain;

import cn.ezhizao.framework.aspectj.lang.annotation.Excel;
import cn.ezhizao.framework.web.domain.BaseEntity;
import cn.ezhizao.project.system.domain.SysUser;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;
import java.util.List;

/**
 * 序检主对象 biz_process_inspecion
 *
 * @author ezhizao
 * @date 2024-04-24
 */
@Data
@TableName(value = "biz_process_inspecion")
public class BizProcessInspecion extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 租户（厂别）id */
    @ApiModelProperty(value = "${comment}")
    private Long tenantId;

    /** 用户id */
    @ApiModelProperty(value = "${comment}")
    private Long userId;

    /** 员工编码 */
    @Excel(name = "员工编码")
    @ApiModelProperty(value = "员工编码")
    private String userName;

    /** 员工姓名 */
    @Excel(name = "员工姓名")
    @ApiModelProperty(value = "员工姓名")
    private String nickName;

    @Excel(name = "箱号Id")
    @ApiModelProperty(value = "箱号Id")
    private Long carrierId;

    @Excel(name = "箱号code")
    @ApiModelProperty(value = "箱号code")
    private String carrierCode;

    /** daywork的id */
    @ApiModelProperty(value = "员工姓名")
    private Long dayworkId;

    /** dayworkItemId */
    private Long dayworkItemId;

    @TableField(exist = true)
    private String remark;

    /** 计划单id */
    @ApiModelProperty(value = "员工姓名")
    private Long productionPlanId;

    /** 计划单明细id */
    @ApiModelProperty(value = "员工姓名")
    private Long productionPlanDetailId;

    /** 子计划id */
    @ApiModelProperty(value = "员工姓名")
    private Long productionPlanDetailSubDetailId;

    /** 批次id */
    @ApiModelProperty(value = "员工姓名")
    private Long lotId;

    /** 批次号 */
    @Excel(name = "批次号")
    @ApiModelProperty(value = "批次号")
    private String lotCode;

    /** 工段id（当前工段的id） */
    @ApiModelProperty(value = "批次号")
    private Long deptId;

    /** 产品id */
    @ApiModelProperty(value = "批次号")
    private Long productId;

    /** 工艺id（通过工艺id，获取版本号） */
    @ApiModelProperty(value = "批次号")
    private Long technologicalProcessId;

    /** 废品量 */
    @Excel(name = "废品量")
    @ApiModelProperty(value = "废品量")
    private Integer rejectNum;

    /** 检测量 */
    @Excel(name = "检测量")
    @ApiModelProperty(value = "检测量")
    private Integer examiningNum;

    /** 开始时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "开始时间", width = 30, dateFormat = "yyyy-MM-dd")
    @ApiModelProperty(value = "开始时间")
    private Date startTime;

    /** 结束时间 */
    @JsonFormat(pattern = "yyyy-MM-dd")
    @Excel(name = "结束时间", width = 30, dateFormat = "yyyy-MM-dd")
    @ApiModelProperty(value = "结束时间")
    private Date endTime;

    /** 批次生产状态（0：未开始，1：进行中，2：已完成） */
    @Excel(name = "批次生产状态", readConverterExp = "0=：未开始，1：进行中，2：已完成")
    @ApiModelProperty(value = "批次生产状态")
    private Integer status;


    /** 产品描述 */
    private String productDescription;

    @TableField(exist = false)
    private SysUser user;

    @TableField(exist = false)
    private String keyword;

    private Long returnReceiptDetailId;
    @ApiModelProperty("第一修改人")
    private Long firstUpdaterId;

    @ApiModelProperty("不合格数量")
    private Integer disqualificationNum;

    @ApiModelProperty("质检箱解绑")
    private Integer isInspectionCarrierChanged;

    @ApiModelProperty("质检箱解绑时间")
    private Date inspectionCarrierChangedTime;

    @ApiModelProperty("外协序检工序")
    private String processNames;

    @ApiModelProperty("审核人")
    private Long reviewerId;

    @ApiModelProperty("外协单id")
    private Long outsourceOrderDetailId;
    @ApiModelProperty("外协单id")
    private Long outsourceOrderId;
    @TableField(exist = false)
    private String processAlias;
    @TableField(exist = false)
    private String technologyVersion;
    @TableField(exist = false)
    private String deptName;
    @TableField(exist = false)
    private String drawingNumber;

    @ApiModelProperty("复检时间")
    private Date recheckDate;
    @ApiModelProperty("自动外协检查")
    private Integer isAuto;
    @ApiModelProperty("外协检查单号")
    private String outsourcedInspectionNo;
    @ApiModelProperty("外协检查审核状态")
    private Integer auditStatus;
    @ApiModelProperty("是否为外协序检")
    private Integer isOutsourcedInspection;
    @TableField(exist = false)
    private String supplierName;
    @TableField(exist = false)
    private String mnemonicCode;
    @TableField(exist = false)
    private Integer materialLoss;
    @TableField(exist = false)
    private String processName;

    @TableField(exist = false)
    private String technicianCode;

    @TableField(exist = false)
    private String technicianName;
    private String type;
    private String equipmentDetailCode;
    private Long equipmentDetailId;
    private Integer inspectionStatus;
    @TableField(exist = false)
    private String outsourcedOrderDetailFormCode;
    @TableField(exist = false)
    private String returnReceiptDetailFormCode;
    private Integer adoptStatus;
    @TableField(exist = false)
    private Integer start;
    @TableField(exist = false)
    private Integer pageSize;


}
