package cn.iocoder.yudao.module.common.controller.admin.moldticketmanagement.vo;

import cn.iocoder.yudao.framework.mybatis.core.dataobject.BaseDO;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer;
import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

@Schema(description = "管理后台 - 项目方案关联 Response VO")
@Data
@ExcelIgnoreUnannotated
public class MoldTicketManagementRespVO extends BaseDO {

    @Schema(description = "id", requiredMode = Schema.RequiredMode.REQUIRED, example = "6566")
    @ExcelProperty("id")
    private Long id;

    @Schema(description = "任务Id", example = "21368")
//    @ExcelProperty("项目ID")
    private Long taskId;

    @Schema(description = "方案ID", example = "20459")
//    @ExcelProperty("方案ID")
    private Long planId;

    @Schema(description = "单号")
    @ExcelProperty("单号")
    private String planNo;

    @Schema(description = "设备名称", example = "张三")
    @ExcelProperty("设备名称")
    private String moldName;

    @Schema(description = "类型", example = "2")
    @ExcelProperty("类型")
    private String planType;

    @Schema(description = "计划配置名称", example = "赵六")
    @ExcelProperty("计划配置名称")
    private String configName;

    @Schema(description = "作业状态", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
    @ExcelProperty("作业状态")
    private Integer jobStatus;

    @Schema(description = "作业结果")
    @ExcelProperty("作业结果")
    private Integer jobResult;

    @Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("创建时间")
    private LocalDateTime createTime;



    /**
     * 作业开始时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    private LocalDateTime taskTime;

    /**
     * 作业结束时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonSerialize(using = LocalDateTimeSerializer.class)
    @JsonDeserialize(using = LocalDateTimeDeserializer.class)
    private LocalDateTime taskEndTime;


    @Schema(description = "创建人名字")
    @ExcelProperty("创建人名字")
    private String creatorName;

    @Schema(description = "作业人")
    private String operator;
    @Schema(description = "作业人名称")
    @ExcelProperty("作业人名称")
    private String operatorName;

     @Schema(description = "取消原因")
    private String cancelReason;


}