package org.dromara.elevator.domain.bo;

import org.dromara.elevator.domain.EElevatorExamination;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;
import org.springframework.format.annotation.DateTimeFormat;

import java.math.BigDecimal;
import java.time.LocalDate;
import java.util.Date;

/**
 * 电梯体检业务对象 e_elevator_examination
 *
 * @author ym
 * @date 2024-10-11
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = EElevatorExamination.class, reverseConvertGenerate = false)
public class EElevatorExaminationBo extends BaseEntity {

    /**
     * 主键
     */
    @NotNull(message = "主键不能为空", groups = { EditGroup.class })
    private Long id;

    /**
     * 电梯编号
     */
    @NotBlank(message = "电梯编号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String elevatorNum;

    /**
     * 体检时间
     */
    @NotBlank(message = "体检时间不能为空", groups = { AddGroup.class, EditGroup.class })
    private String examinationTime;

    /**
     * 体检编号
     */
    @NotBlank(message = "体检编号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String examinationNum;

    /**
     * 安全指数
     */
    @NotNull(message = "安全指数不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal safetyIndex;

    /**
     * 维保指数
     */
    @NotNull(message = "维保指数不能为空", groups = { AddGroup.class, EditGroup.class })
    private BigDecimal maintenanceIndex;

    /**
     * 高峰日期
     */
    @NotNull(message = "高峰日期不能为空", groups = { AddGroup.class, EditGroup.class })
    private LocalDate peakDate;

    /**
     * 高峰日运行次数
     */
    @NotNull(message = "高峰日运行次数不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer peakRunNum;

    /**
     * 高峰时段数据(json)
     */
    @NotBlank(message = "高峰时段数据(json)不能为空", groups = { AddGroup.class, EditGroup.class })
    private String peakHourData;

    /**
     * 繁忙楼层
     */
    @NotNull(message = "繁忙楼层不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer busyFloor;

    /**
     * 繁忙楼层停梯次数
     */
    @NotNull(message = "繁忙楼层停梯次数不能为空", groups = { AddGroup.class, EditGroup.class })
    private Integer busyFloorNum;

    /**
     * 体检日统计数据(json)
     */
    @NotBlank(message = "体检日统计数据(json)不能为空", groups = { AddGroup.class, EditGroup.class })
    private String statisticsDayData;

    /**
     * 体检周统计数据(json)
     */
    @NotBlank(message = "体检周统计数据(json)不能为空", groups = { AddGroup.class, EditGroup.class })
    private String statisticsWeekData;

    /**
     * 体检月统计数据(json)
     */
    @NotBlank(message = "体检月统计数据(json)不能为空", groups = { AddGroup.class, EditGroup.class })
    private String statisticsMonthData;

    /**
     * 问题明细
     */
    @NotBlank(message = "问题明细不能为空", groups = { AddGroup.class, EditGroup.class })
    private String problemDetail;

    /**
     * 工作明细
     */
    @NotBlank(message = "工作明细不能为空", groups = { AddGroup.class, EditGroup.class })
    private String workDetail;

    /**
     * 部门id
     */
    private Long deptId;

    /**
     * 开始时间
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date startTime;

    /**
     * 结束时间
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date endTime;

}
