package com.zt.plat.module.qms.business.bus.controller.vo;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;

import java.math.BigDecimal;
import java.util.*;
import jakarta.validation.constraints.*;

@Schema(description = "管理后台 - 检测项目数据业务新增/修改 Request VO")
@Data
public class BusinessAssayProjectDataSaveReqVO {

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

    @Schema(description = "检测任务ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "15606")
    @NotNull(message = "检测任务ID不能为空")
    private Long businessAssayTaskDataId;

    @Schema(description = "检测方法分析项目配置ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "17620")
    @NotNull(message = "检测方法分析项目配置ID不能为空")
    private Long configAssayMethodProjectId;

    @Schema(description = "检测项目字典ID,字典表【T_DIC_PRJ】", requiredMode = Schema.RequiredMode.REQUIRED, example = "19038")
    @NotNull(message = "检测项目字典ID,字典表【T_DIC_PRJ】不能为空")
    private Long dictionaryProjectId;

    @Schema(description = "值")
    private String value;

    @Schema(description = "补正系数ID", example = "1008")
    private Long configAssayMethodProjectCoefficientId;

    @Schema(description = "补正系数")
    private BigDecimal coefficient;

    @Schema(description = "补正后的值")
    private String valueAfter;

    @Schema(description = "数据类型,字典表【T_DIC_BSN】string-字符串，int-整数，decimal-小数,date-日期，datetime-时间", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
    @NotEmpty(message = "数据类型,字典表【T_DIC_BSN】string-字符串，int-整数，decimal-小数,date-日期，datetime-时间不能为空")
    private String dataType;

    @Schema(description = "小数位")
    private Integer decimalPosition;

    @Schema(description = "有效数字位")
    private Integer effectiveDigit;

    @Schema(description = "是否不参与超差判定", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "是否不参与超差判定不能为空")
    private Integer isNotAssessment;

    @Schema(description = "方法检出下限值")
    private String minimumLimitValue;

    @Schema(description = "判定类型,内控超差、重复性超差、再现性超差", example = "2")
    private String assessmentType;

    @Schema(description = "是否作废(取消)判定[超差时],1-是，0-否")
    private Integer isCancelAssessment;

    @Schema(description = "是否启用", requiredMode = Schema.RequiredMode.REQUIRED)
    @NotNull(message = "是否启用不能为空")
    private Integer isEnabled;

    @Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "30046")
    private Integer updateCount;

    @Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
    private String systemDepartmentCode;

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

}