# BookingDTO.java

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

    import cloud.wconnect.commonlib.annotation.validator.DigitsCustom;
    import lombok.Data;

    import jakarta.validation.constraints.NotNull;
    import java.math.BigDecimal;

    /**
     * DTO: Booking
     *
     * @author: yyt
     * 2024-07-22
     */
    @Data
    public class BookingDTO {

        /**
         * 数据 id
         */
        private Integer id;

        /**
         * 开始日期（yyyyMMdd）
         */
        @NotNull(message = "the startDate must not be null")
        private Integer startDate;

        /**
         * 结束日期（yyyyMMdd）
         */
        @NotNull(message = "the endDate must not be null")
        private Integer endDate;

        /**
         * 总金额
         */
        @NotNull(message = "the totalAmount must not be null")
        @DigitsCustom(integer = 10, message = "the totalAmount format error")
        private BigDecimal totalAmount;

        /**
         * 平均房价
         */
        private BigDecimal averagePrice;

        /**
         * 入住天数
         */
        private Integer stayDays;

        /**
         * 预定日期（yyyyMMdd）
         */
        @NotNull(message = "the bookedDate must not be null")
        private Integer bookedDate;

        /**
         * 提前预定天数
         */
        private Integer advanceDays;

    }