From 476101189ea1a6eeaba555bfadcd7e90793e1340 Mon Sep 17 00:00:00 2001 From: YunaiV Date: Sat, 31 Aug 2024 09:07:11 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E4=BB=A3=E7=A0=81=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E3=80=91=E5=95=86=E5=9F=8E=EF=BC=9A=E4=BC=98=E6=83=A0=E5=8A=B5?= =?UTF-8?q?=E7=9A=84=E6=8F=8F=E8=BF=B0=E5=AD=97=E6=AE=B5=E6=96=B0=E5=A2=9E?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../admin/coupon/vo/template/CouponTemplateBaseVO.java | 6 +++--- .../app/coupon/vo/template/AppCouponTemplateRespVO.java | 9 +++------ .../dal/dataobject/coupon/CouponTemplateDO.java | 8 +++++--- 3 files changed, 11 insertions(+), 12 deletions(-) diff --git a/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/admin/coupon/vo/template/CouponTemplateBaseVO.java b/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/admin/coupon/vo/template/CouponTemplateBaseVO.java index 715982aa0..6885246b4 100755 --- a/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/admin/coupon/vo/template/CouponTemplateBaseVO.java +++ b/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/admin/coupon/vo/template/CouponTemplateBaseVO.java @@ -33,6 +33,9 @@ public class CouponTemplateBaseVO { @NotNull(message = "优惠劵名不能为空") private String name; + @Schema(description = "优惠券说明", example = "优惠券使用说明") + private String description; + @Schema(description = "发行总量", requiredMode = Schema.RequiredMode.REQUIRED, example = "1024") // -1 - 则表示不限制发放数量 @NotNull(message = "发行总量不能为空") private Integer totalCount; @@ -95,9 +98,6 @@ public class CouponTemplateBaseVO { @Schema(description = "折扣上限", example = "100") // 单位:分,仅在 discountType 为 PERCENT 使用 private Integer discountLimitPrice; - @Schema(description = "优惠券说明", example = "优惠券使用说明") // 单位:分,仅在 discountType 为 PERCENT 使用 - private String description; - @AssertTrue(message = "商品范围编号的数组不能为空") @JsonIgnore public boolean isProductScopeValuesValid() { diff --git a/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/app/coupon/vo/template/AppCouponTemplateRespVO.java b/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/app/coupon/vo/template/AppCouponTemplateRespVO.java index 8ca62935e..a57fc0472 100755 --- a/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/app/coupon/vo/template/AppCouponTemplateRespVO.java +++ b/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/app/coupon/vo/template/AppCouponTemplateRespVO.java @@ -1,8 +1,5 @@ package cn.iocoder.yudao.module.promotion.controller.app.coupon.vo.template; -import cn.iocoder.yudao.framework.mybatis.core.type.LongListTypeHandler; -import cn.iocoder.yudao.module.promotion.enums.common.PromotionProductScopeEnum; -import com.baomidou.mybatisplus.annotation.TableField; import io.swagger.v3.oas.annotations.media.Schema; import lombok.Data; @@ -20,6 +17,9 @@ public class AppCouponTemplateRespVO { @Schema(description = "优惠劵名", requiredMode = Schema.RequiredMode.REQUIRED, example = "春节送送送") private String name; + @Schema(description = "优惠券说明", example = "优惠券使用说明") + private String description; + @Schema(description = "每人限领个数", requiredMode = Schema.RequiredMode.REQUIRED, example = "66") // -1 - 则表示不限制 private Integer takeLimitCount; @@ -67,7 +67,4 @@ public class AppCouponTemplateRespVO { @Schema(description = "是否可以领取", requiredMode = Schema.RequiredMode.REQUIRED, example = "true") private Boolean canTake; - @Schema(description = "优惠券说明", example = "优惠券使用说明") // 单位:分,仅在 discountType 为 PERCENT 使用 - private String description; - } diff --git a/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/dal/dataobject/coupon/CouponTemplateDO.java b/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/dal/dataobject/coupon/CouponTemplateDO.java index 93970ab9b..10fe302a3 100644 --- a/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/dal/dataobject/coupon/CouponTemplateDO.java +++ b/yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/dal/dataobject/coupon/CouponTemplateDO.java @@ -11,7 +11,6 @@ import com.baomidou.mybatisplus.annotation.KeySequence; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableName; -import io.swagger.v3.oas.annotations.media.Schema; import lombok.Data; import lombok.EqualsAndHashCode; @@ -41,6 +40,10 @@ public class CouponTemplateDO extends BaseDO { * 优惠劵名 */ private String name; + /** + * 优惠券说明 + */ + private String description; /** * 状态 * @@ -159,10 +162,9 @@ public class CouponTemplateDO extends BaseDO { * 使用优惠券的次数 */ private Integer useCount; + // ========== 统计信息 END ========== // TODO 芋艿:领取开始时间、领取结束时间 - @Schema(description = "优惠券说明", example = "优惠券使用说明") // 单位:分,仅在 discountType 为 PERCENT 使用 - private String description; }