|
@@ -7,57 +7,53 @@ import lombok.Getter;
|
|
|
import lombok.Setter;
|
|
import lombok.Setter;
|
|
|
import java.time.LocalDateTime;
|
|
import java.time.LocalDateTime;
|
|
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
|
|
-import java.math.BigDecimal;
|
|
|
|
|
import jakarta.validation.constraints.*;
|
|
import jakarta.validation.constraints.*;
|
|
|
|
|
|
|
|
/**
|
|
/**
|
|
|
* 优惠劵模板表单对象
|
|
* 优惠劵模板表单对象
|
|
|
*
|
|
*
|
|
|
* @author zsElectric
|
|
* @author zsElectric
|
|
|
- * @since 2025-12-12 15:11
|
|
|
|
|
|
|
+ * @since 2025-12-15 11:14
|
|
|
*/
|
|
*/
|
|
|
@Getter
|
|
@Getter
|
|
|
@Setter
|
|
@Setter
|
|
|
@Schema(description = "优惠劵模板表单对象")
|
|
@Schema(description = "优惠劵模板表单对象")
|
|
|
-public class PromotionCouponTemplateForm implements Serializable {
|
|
|
|
|
|
|
+public class CouponTemplateForm implements Serializable {
|
|
|
|
|
|
|
|
@Serial
|
|
@Serial
|
|
|
private static final long serialVersionUID = 1L;
|
|
private static final long serialVersionUID = 1L;
|
|
|
|
|
|
|
|
- @Schema(description = "主键ID")
|
|
|
|
|
- @NotNull(message = "主键ID不能为空")
|
|
|
|
|
|
|
+ @Schema(description = "模板编号,自增唯一。")
|
|
|
|
|
+ @NotNull(message = "模板编号,自增唯一。不能为空")
|
|
|
private Long id;
|
|
private Long id;
|
|
|
|
|
|
|
|
- @Schema(description = "优惠劵名称")
|
|
|
|
|
- @NotBlank(message = "优惠劵名称不能为空")
|
|
|
|
|
- @Size(max=50, message="优惠劵名称长度不能超过50个字符")
|
|
|
|
|
|
|
+ @Schema(description = "优惠劵名")
|
|
|
|
|
+ @Size(max=50, message="优惠劵名长度不能超过50个字符")
|
|
|
private String name;
|
|
private String name;
|
|
|
|
|
|
|
|
- @Schema(description = "描述")
|
|
|
|
|
- @Size(max=500, message="描述长度不能超过500个字符")
|
|
|
|
|
|
|
+ @Schema(description = "优惠劵描述")
|
|
|
|
|
+ @Size(max=512, message="优惠劵描述长度不能超过512个字符")
|
|
|
private String description;
|
|
private String description;
|
|
|
|
|
|
|
|
- @Schema(description = "上线状态 ( 0-下线 1-上线)")
|
|
|
|
|
- @NotNull(message = "上线状态 ( 0-下线 1-上线)不能为空")
|
|
|
|
|
|
|
+ @Schema(description = "状态 1.上线 2.下线")
|
|
|
|
|
+ @NotNull(message = "状态 1.上线 2.下线不能为空")
|
|
|
private Integer status;
|
|
private Integer status;
|
|
|
|
|
|
|
|
@Schema(description = "发放数量, -1 - 则表示不限制")
|
|
@Schema(description = "发放数量, -1 - 则表示不限制")
|
|
|
@NotNull(message = "发放数量, -1 - 则表示不限制不能为空")
|
|
@NotNull(message = "发放数量, -1 - 则表示不限制不能为空")
|
|
|
private Integer totalCount;
|
|
private Integer totalCount;
|
|
|
|
|
|
|
|
- @Schema(description = "每人限领个数, -1 - 则表示不限制")
|
|
|
|
|
- private Integer takeLimitCount;
|
|
|
|
|
-
|
|
|
|
|
@Schema(description = "失效时间,领取后的几天。")
|
|
@Schema(description = "失效时间,领取后的几天。")
|
|
|
|
|
+ @NotNull(message = "失效时间,领取后的几天。不能为空")
|
|
|
private Integer failureTime;
|
|
private Integer failureTime;
|
|
|
|
|
|
|
|
@Schema(description = "设置满多少金额可用,单位:分")
|
|
@Schema(description = "设置满多少金额可用,单位:分")
|
|
|
@NotNull(message = "设置满多少金额可用,单位:分不能为空")
|
|
@NotNull(message = "设置满多少金额可用,单位:分不能为空")
|
|
|
- private BigDecimal usePrice;
|
|
|
|
|
|
|
+ private Integer usePrice;
|
|
|
|
|
|
|
|
@Schema(description = "优惠金额,单位:分")
|
|
@Schema(description = "优惠金额,单位:分")
|
|
|
@NotNull(message = "优惠金额,单位:分不能为空")
|
|
@NotNull(message = "优惠金额,单位:分不能为空")
|
|
|
- private BigDecimal discountPrice;
|
|
|
|
|
|
|
+ private Integer discountPrice;
|
|
|
|
|
|
|
|
@Schema(description = "领取时间:周 星期一 1 2 3 4 5 6 7")
|
|
@Schema(description = "领取时间:周 星期一 1 2 3 4 5 6 7")
|
|
|
@NotBlank(message = "领取时间:周 星期一 1 2 3 4 5 6 7不能为空")
|
|
@NotBlank(message = "领取时间:周 星期一 1 2 3 4 5 6 7不能为空")
|
|
@@ -69,6 +65,12 @@ public class PromotionCouponTemplateForm implements Serializable {
|
|
|
@Size(max=50, message="领取时间 时分 08:20长度不能超过50个字符")
|
|
@Size(max=50, message="领取时间 时分 08:20长度不能超过50个字符")
|
|
|
private String validTimeHour;
|
|
private String validTimeHour;
|
|
|
|
|
|
|
|
|
|
+ @Schema(description = "发放的总数量")
|
|
|
|
|
+ private Integer totalCountAll;
|
|
|
|
|
+
|
|
|
|
|
+ @Schema(description = "失效的数量")
|
|
|
|
|
+ private Integer failureCount;
|
|
|
|
|
+
|
|
|
@Schema(description = "创建时间")
|
|
@Schema(description = "创建时间")
|
|
|
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
|
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
|
|
private LocalDateTime createTime;
|
|
private LocalDateTime createTime;
|
|
@@ -83,5 +85,11 @@ public class PromotionCouponTemplateForm implements Serializable {
|
|
|
@Schema(description = "更新人")
|
|
@Schema(description = "更新人")
|
|
|
private Long updateBy;
|
|
private Long updateBy;
|
|
|
|
|
|
|
|
|
|
+ @Schema(description = "乐观锁")
|
|
|
|
|
+ private Integer version;
|
|
|
|
|
+
|
|
|
|
|
+ @Schema(description = "逻辑删除(0-未删除 1-已删除)")
|
|
|
|
|
+ private Integer isDeleted;
|
|
|
|
|
+
|
|
|
|
|
|
|
|
}
|
|
}
|