Commit 49685906857817f76a7c7f32faf28aa1583379c6
Committed by
Gitee
!1056 【功能优化】商城优惠券模板添加描述字段
Merge pull request !1056 from 卢越/master-jdk17
Showing
3 changed files
with
9 additions
and
1 deletions
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/admin/coupon/vo/template/CouponTemplateBaseVO.java
| ... | ... | @@ -95,6 +95,9 @@ public class CouponTemplateBaseVO { |
| 95 | 95 | @Schema(description = "折扣上限", example = "100") // 单位:分,仅在 discountType 为 PERCENT 使用 |
| 96 | 96 | private Integer discountLimitPrice; |
| 97 | 97 | |
| 98 | + @Schema(description = "优惠券说明", example = "优惠券使用说明") // 单位:分,仅在 discountType 为 PERCENT 使用 | |
| 99 | + private String description; | |
| 100 | + | |
| 98 | 101 | @AssertTrue(message = "商品范围编号的数组不能为空") |
| 99 | 102 | @JsonIgnore |
| 100 | 103 | public boolean isProductScopeValuesValid() { | ... | ... |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/controller/app/coupon/vo/template/AppCouponTemplateRespVO.java
| ... | ... | @@ -67,4 +67,7 @@ public class AppCouponTemplateRespVO { |
| 67 | 67 | @Schema(description = "是否可以领取", requiredMode = Schema.RequiredMode.REQUIRED, example = "true") |
| 68 | 68 | private Boolean canTake; |
| 69 | 69 | |
| 70 | + @Schema(description = "优惠券说明", example = "优惠券使用说明") // 单位:分,仅在 discountType 为 PERCENT 使用 | |
| 71 | + private String description; | |
| 72 | + | |
| 70 | 73 | } | ... | ... |
yudao-module-mall/yudao-module-promotion-biz/src/main/java/cn/iocoder/yudao/module/promotion/dal/dataobject/coupon/CouponTemplateDO.java
| ... | ... | @@ -11,6 +11,7 @@ import com.baomidou.mybatisplus.annotation.KeySequence; |
| 11 | 11 | import com.baomidou.mybatisplus.annotation.TableField; |
| 12 | 12 | import com.baomidou.mybatisplus.annotation.TableId; |
| 13 | 13 | import com.baomidou.mybatisplus.annotation.TableName; |
| 14 | +import io.swagger.v3.oas.annotations.media.Schema; | |
| 14 | 15 | import lombok.Data; |
| 15 | 16 | import lombok.EqualsAndHashCode; |
| 16 | 17 | |
| ... | ... | @@ -162,5 +163,6 @@ public class CouponTemplateDO extends BaseDO { |
| 162 | 163 | |
| 163 | 164 | // TODO 芋艿:领取开始时间、领取结束时间 |
| 164 | 165 | |
| 165 | - // TODO 芋艿:要不要加描述 | |
| 166 | + @Schema(description = "优惠券说明", example = "优惠券使用说明") // 单位:分,仅在 discountType 为 PERCENT 使用 | |
| 167 | + private String description; | |
| 166 | 168 | } | ... | ... |