package com.changhu.module.assessmentCriteria.pojo.params;

import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.Valid;
import jakarta.validation.constraints.NotEmpty;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

import java.util.List;

/**
 * @author 20252
 * @createTime 2024/11/7 上午11:15
 * @desc AssessmentRecordParams...
 */
@Data
public class AssessmentRecordParams {
    @Schema(description = "企事业单位id")
    @NotNull(message = "被考核单位不能为空")
    private Long enterprisesUnitId;

    @Schema(description = "考核项目")
    @NotNull(message = "考核项目不能为空")
    private Long ckProjectId;

    @Schema(description = "考核人员签字")
    @NotEmpty(message = "考核人员需签字")
    private String assessmentUserSignature;
    @Schema(description = "被考核单位人员签字")
    @NotEmpty(message = "被考核单位需人员签字")
    private String byAssessmentEnterprisesUnitUserSignature;

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

    @Valid
    @Schema(description = "考核记录详情")
    private List<RecordDetailParams> assessmentRecordDetails;

    @Data
    public static class RecordDetailParams {
        @NotNull(message = "考核分组不能为空")
        @Schema(description = "考核分组id")
        private Long ckGroupId;

        @NotNull(message = "考核项不能为空")
        @Schema(description = "考核项id")
        private Long ckItemId;

        @NotNull(message = "考核标准不能为空")
        @Schema(description = "考核标准id")
        private Long ckStandardId;
    }
}
