package com.zt.plat.module.qms.resource.device.controller.vo;

import com.alibaba.fastjson.JSONObject;
import com.zt.plat.framework.common.pojo.CommonResult;
import com.zt.plat.module.infra.api.businessfile.dto.BusinessFileWithUrlRespDTO;
import com.zt.plat.module.qms.core.aspect.annotation.Dict;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.util.*;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import com.alibaba.excel.annotation.*;

@Schema(description = "管理后台 - 设备-检定校准 Response VO")
@Data
@ExcelIgnoreUnannotated
public class DeviceCalibrationRespVO {

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

    @Schema(description = "检定校准计划id", example = "22068")
    @ExcelProperty("检定校准计划id")
    private Long planId;

    @Schema(description = "有效标识")
    @ExcelProperty("有效标识")
    private String effectiveFlag;

    @Schema(description = "设备id", example = "21116")
    @ExcelProperty("设备id")
    private Long deviceId;

    @Schema(description = "供应商名称", example = "赵六")
    @ExcelProperty("供应商名称")
    private String supplierName;

    @Schema(description = "供应商ID", example = "24250")
    @ExcelProperty("供应商ID")
    private Long supplierId;

    @Schema(description = "校准点/范围")
    @ExcelProperty("校准点/范围")
    private String specification;

    @Schema(description = "计划检定校准日期")
    @ExcelProperty("计划检定校准日期")
    private LocalDateTime planCheckDate;

    @Schema(description = "上次检定校准日期")
    @ExcelProperty("上次检定校准日期")
    private LocalDateTime lastCheckDate;

    @Schema(description = "频次")
    @ExcelProperty("频次")
    private String frequencyRemark;

    @Schema(description = "类型：检定|校准", example = "2")
    @ExcelProperty("类型：检定|校准")
    private String checkType;

    @Schema(description = "检定校准日期")
    @ExcelProperty("检定校准日期")
    private LocalDateTime checkDate;

    @Schema(description = "检定校准单位")
    @ExcelProperty("检定校准单位")
    private String agent;

    @Schema(description = "证书编号")
    @ExcelProperty("证书编号")
    private String certificateCode;

    @Schema(description = "有效期")
    @ExcelProperty("有效期")
    private LocalDateTime validityDate;

    @Schema(description = "确认情况（理由）")
    @ExcelProperty("确认情况（理由）")
    private String checkContent;

    @Schema(description = "确认结果")
    @ExcelProperty("确认结果")
    private String checkResult;

    @Schema(description = "检定校准状态", example = "2")
    @ExcelProperty("检定校准状态")
    @Dict(dicCode = "flow_status")
    private String flowStatus;

    @Schema(description = "流程实例id", example = "24905")
    @ExcelProperty("流程实例id")
    private String flowInstanceId;

    @Schema(description = "表单id")
    private Long formId;

    @Schema(description = "作废状态")
    @ExcelProperty("作废状态")
    private Integer cancelFlag;

    @Schema(description = "所属部门")
    @ExcelProperty("所属部门")
    private String systemDepartmentCode;

    @Schema(description = "备注")
    @ExcelProperty("备注")
    private String remark;

    @Schema(description = "创建时间")
    @ExcelProperty("创建时间")
    private LocalDateTime createTime;

    //============扩展字段============

    @Schema(description = "附件对象")
    private CommonResult<List<BusinessFileWithUrlRespDTO>> businessFileRet;
}