package com.bonus.material.back.domain;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.bonus.common.core.annotation.Excel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.ToString;
import lombok.experimental.Accessors;

import javax.validation.constraints.Size;

/**
 * 退料任务对象 back_apply_info
 * 
 * @author xsheng
 * @date 2024-10-16
 */

@Accessors(chain = true)
@Data
@ToString
public class BackApplyInfo implements Serializable {

    private static final long serialVersionUID = 1L;

    private Boolean isExport;

    @ApiModelProperty(value = "登录用户id")
    private Long userId;

    /** ID */
    private Long id;

    @ApiModelProperty(value = "协议id")
    private Long agreementId;

    @ApiModelProperty(value = "材料站协议id")
    private Long clzAgreementId;

    @ApiModelProperty(value = "任务类型")
    private Integer taskType;

    @ApiModelProperty(value = "单位id")
    private Long unitId;

    @ApiModelProperty(value = "单位名称")
    @Excel(name = "退料单位")
    private String unitName;

    @ApiModelProperty(value="工程id")
    private Long proId;

    @ApiModelProperty(value="工程名称")
    @Excel(name = "工程名称")
    private String proName;

    /** 退料单号 */
    @Excel(name = "退料单号")
    @ApiModelProperty(value = "退料单号")
    private String code;

    @ApiModelProperty(value = "类型id")
    private String typeId;

    @ApiModelProperty(value = "物资类型")
    private String materialType;

    private String materialName;

    @ApiModelProperty(value = "类型名称")
    @Excel(name = "物资类型")
    private String typeName;

    /** 任务ID */
    @ApiModelProperty(value = "任务ID")
    private Long taskId;

    /** 退料人 */
    @Excel(name = "退料人")
    @ApiModelProperty(value = "退料人")
    @Size(max = 20, message = "退料人长度不能超过20个字符")
    private String backPerson;

    private String backSignUrl;

    private Byte backSignType;

    /**
     * 退料数量
     */
    private BigDecimal backNum;

    /** 联系方式 */
    @Excel(name = "退料人电话")
    @ApiModelProperty(value = "联系方式")
    private String phone;

    /** 机具公司审批人 */
    @ApiModelProperty(value = "机具公司审批人")
    private Long directAuditBy;

    /** 机具公司审批时间 */
    @ApiModelProperty(value = "机具公司审批时间")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date directAuditTime;

    /** 机具公司审批备注 */
    @ApiModelProperty(value = "机具公司审批备注")
    private String directAuditRemark;

    /** 数据所属组织 */
    @ApiModelProperty(value = "数据所属组织")
    private Long companyId;

    /** 预退料时间 */
    @ApiModelProperty(value = "预退料时间")
    @JsonFormat(pattern = "yyyy-MM-dd")
    private Date backTime;

    @Excel(name = "创建人")
    private String createBy;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "创建时间", dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    /** 1.机具分公司审核通过，2.机具分公司审批不通过，3.调试分公司审批通过，4.调试分公司审批不通过，5.出库进行中，6.出库完成 */
    @Excel(name = "状态")
    @ApiModelProperty(value = "1.机具分公司审核通过，2.机具分公司审批不通过，3.调试分公司审批通过，4.调试分公司审批不通过，5.出库进行中，6.出库完成")
    private String status;

    @ApiModelProperty(value = "任务状态")
    private Integer taskStatus;

    private String updateBy;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

    @ApiModelProperty(value = "打印状态")
    @Excel(name = "打印状态")
    private String printStatus;

    @Excel(name = "备注")
    @Size(max = 500, message = "备注长度不能超过500个字符")
    private String remark;

    @ApiModelProperty(value = "机具id")
    private Long maId;

    /** 任务ID */
    @ApiModelProperty(value = "任务ID")
    private Long parentId;

    /** 直转id */
    @ApiModelProperty(value = "直转id")
    private Long directId;

    @ApiModelProperty(value="开始时间")
    private String startTime;

    @ApiModelProperty(value="结束时间")
    private String endTime;

    @ApiModelProperty(value="关键字")
    private String keyWord;

    @ApiModelProperty(value="设备编码")
    private String maCode;

    @ApiModelProperty(value="二维码")
    private String qrCode;

    @ApiModelProperty(value = "审批人签名类型 手写0 和 图片上传1")
    private int directAuditSignType;

    @ApiModelProperty(value = "审批人人签名URL")
    private String directAuditSignUrl;

    @ApiModelProperty(value = "app退料任务状态，0 未审核 1已审核（包含通过和驳回）")
    private Integer appTaskStatus;

    private String maStatus;

    /**
     * 是否签名
     */
    private Integer isSign;

    @ApiModelProperty(value = "一级类型id集合")
    private String firstId;

    @ApiModelProperty(value = "i8工程id")
    private String externalId;

    @ApiModelProperty(value = "材料员确认账号")
    private String materialMan;

    @ApiModelProperty(value = "材料员确认时间")
    private String confirmTime;

    @ApiModelProperty(value = "是否确认 0不需要确认，1未确认 2已确认")
    private Integer isConfirm;

    @ApiModelProperty(value = "材料员确认备注")
    private String confirmRemark;

    @ApiModelProperty(value="工程id")
    private Long projectId;

    @ApiModelProperty(value = "退料方式（1 直退，2 数据同步）")
    private String backStyle;

    @ApiModelProperty(value = "制单人签名地址")
    private String signUrl;

    @ApiModelProperty(value = "制单人签名类型 手写0 和 图片上传1")
    private int signType;
}
