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

import cn.iocoder.yudao.framework.excel.core.annotations.DictFormat;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.write.style.ColumnWidth;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

@Schema(description = "管理后台 - 模具维修记录 Response VO")
@Data
@ExcelIgnoreUnannotated
public class MoldRepairRespVO {

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

    @Schema(description = "维修单编号", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("维修单编号")
    private String repairCode;

    @Schema(description = "维修单名称", example = "王五")
    @ExcelProperty("维修单名称")
    private String repairName;

    @Schema(description = "模具ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "6979")
//    @ExcelProperty("模具ID")
    private Long moldId;

    @Schema(description = "模具编码", requiredMode = Schema.RequiredMode.REQUIRED)
    @ExcelProperty("模具编码")
    private String moldCode;

    @Schema(description = "模具名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "张三")
    @ExcelProperty("模具名称")
    private String moldName;

    @Schema(description = "品牌")
//    @ExcelProperty("品牌")
    private String moldBrand;

    @Schema(description = "规格型号")
//    @ExcelProperty("规格型号")
    private String moldSpec;

    @Schema(description = "模具类型", requiredMode = Schema.RequiredMode.REQUIRED, example = "1622")
//    @ExcelProperty(value = "模具类型", converter = DictConvert.class)
//    @DictFormat("mes_machine_type") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private Long moldTypeId;

    @Schema(description = "报修日期")
    @ExcelProperty("报修日期")
    @ColumnWidth(20)
    private LocalDateTime requireDate;

    @Schema(description = "完成日期")
    @ExcelProperty("完成日期")
    @ColumnWidth(20)
    private LocalDateTime finishDate;

    @Schema(description = "验收日期")
    @ExcelProperty("验收日期")
    @ColumnWidth(20)
    private LocalDateTime confirmDate;

    @Schema(description = "维修结果")
    @ExcelProperty("维修结果")
    private String repairResult;

    @Schema(description = "维修人员")
    @ExcelProperty("维修人员")
    private String acceptedBy;

    @Schema(description = "验收人员")
    @ExcelProperty("验收人员")
    private String confirmBy;

    @Schema(description = "单据状态", example = "1")
//    @ExcelProperty(value = "单据状态 0-待完成 1-已完成")
//    @DictFormat("mes_mold_record_status") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private Integer status;

    @Schema(description = "单据状态", example = "1")
    @ExcelProperty(value = "单据状态 0-待完成 1-已完成")
    @DictFormat("mes_mold_record_status") // TODO 代码优化：建议设置到对应的 DictTypeConstants 枚举类中
    private String statusName;

    @Schema(description = "备注", example = "你猜")
    @ExcelProperty("备注")
    private String remark;

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

    @Schema(description = "模具类型 1-模具 2-关键件", example = "你猜")
    private Integer deviceType;

    @Schema(description = "模具Id", example = "你猜")
    private Long deviceId;

    @Schema(description = "关键件Id", example = "你猜")
    private Long componentId;

    @Schema(description = "维修状态 0-待完成 1-通过 2-不通过")
    private Integer repairStatus;

    @Schema(description = "维修状态")
    @ExcelProperty("维修状态")
    private String repairStatusName;


}