# EventDTO.java

    package cloud.wconnect.rateshop.pojo.dto.rateshop.event;

    import lombok.Data;
    import org.hibernate.validator.constraints.Length;

    import jakarta.validation.constraints.NotBlank;
    import jakarta.validation.constraints.NotNull;
    import jakarta.validation.constraints.Null;
    import jakarta.validation.constraints.Pattern;

    /**
     * 事件dto
     *
     * @author lichen
     * @date 2023/6/19
     */
    @Data
    public class EventDTO {

        /**
         * 事件名称
         */
        @NotBlank(message = "The title cannot be blank")
        @Length(max = 255, message = "The title is limited 255 characters")
        private String title;

        /**
         * 事件分类
         */
        @Length(max = 255, message = "The category is limited 255 characters")
        private String category;

        /**
         * 开始日期
         */
        @NotBlank(message = "The beginDate cannot be blank")
        @Pattern(regexp = "^\\d{4}-\\d{2}-\\d{2}$", message = "The beginDate format is incorrect, right format is [yyyy-MM-dd]")
        private String beginDate;

        /**
         * 结束日期
         */
        @NotBlank(message = "The endDate cannot be blank")
        @Pattern(regexp = "^\\d{4}-\\d{2}-\\d{2}$", message = "The endDate format is incorrect, right format is [yyyy-MM-dd]")
        private String endDate;

        /**
         * 外链
         */
        @Length(max = 255, message = "The link is limited 255 characters")
        private String link;

        /**
         * 事件发生的地点
         */
        @NotBlank(message = "The address cannot be blank")
        @Length(max = 255, message = "The address is limited 255 characters")
        private String address;

        /**
         * 描述
         */
        private String description;

        /**
         * 地址ID
         */
        @NotNull(message = "The locationId cannot be null")
        private Integer locationId;

        /**
         * 主键id
         */
        @Null(message = "The id must be null")
        private Integer id;

        /**
         * 资产id
         */
        @Null(message = "The propertyId must be null")
        private Integer propertyId;

        /**
         * 租户id
         */
        @Null(message = "The tenantId must be null")
        private Integer tenantId;

        /**
         * 更新日志
         */
        @Null(message = "The updateLog must be null")
        private String updateLog;

    }