package cn.iocoder.yudao.module.mes.controller.admin.safety.vo.hazard; import io.swagger.v3.oas.annotations.media.Schema; import jakarta.validation.constraints.*; import lombok.Data; import org.springframework.format.annotation.DateTimeFormat; import java.time.LocalDate; import java.time.LocalDateTime; /** * 安全生产 - 隐患上报/修改 Request VO * * @author 超级管理员 */ @Schema(description = "管理后台 - 隐患上报/修改 Request VO") @Data public class SafetyHazardSaveReqVO { private Long id; @Schema(description = "隐患标题", requiredMode = Schema.RequiredMode.REQUIRED, example = "配电室门未上锁") @NotBlank(message = "隐患标题不能为空") @Size(max = 200) private String title; @Schema(description = "隐患等级", example = "GENERAL") @Pattern(regexp = "GENERAL|MAJOR", message = "隐患等级不合法") private String level; @Schema(description = "来源", example = "INSPECTION") @Pattern(regexp = "INSPECTION|SELF_CHECK|REPORT|EXTERNAL", message = "隐患来源不合法") private String source; @Schema(description = "关联巡检记录编号") private Long inspectionId; @Schema(description = "关联巡检点位编号") private Long pointId; @Schema(description = "点位名称") @Size(max = 100) private String pointName; @Schema(description = "隐患位置") @Size(max = 200) private String location; @Schema(description = "隐患描述") @Size(max = 2000) private String description; @Schema(description = "现场照片 URL,逗号分隔(移动端拍照上传)") @Size(max = 2000) private String photoUrls; @Schema(description = "上报人(员工编号,关联 hrm_employee)", requiredMode = Schema.RequiredMode.REQUIRED) @NotNull(message = "请选择上报人") private Long reporterId; @Schema(description = "上报时间") @DateTimeFormat(iso = DateTimeFormat.ISO.DATE_TIME) private LocalDateTime reportTime; @Schema(description = "整改期限") @DateTimeFormat(iso = DateTimeFormat.ISO.DATE) private LocalDate rectifyDeadline; @Schema(description = "备注") @Size(max = 500) private String remark; }