From 128f0f373e7cf42dc0e5b7b43f2ac358234be85a Mon Sep 17 00:00:00 2001 From: phpcjl <phpcjl@gmail.com> Date: 星期一, 16 十二月 2024 14:02:50 +0800 Subject: [PATCH] 1 --- ruoyi-service/ruoyi-account/src/main/resources/mapper/account/UserPointMapper.xml | 19 ++++++++++++------- ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/domain/CouponInfo.java | 12 ++++++++++-- 2 files changed, 22 insertions(+), 9 deletions(-) diff --git a/ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/domain/CouponInfo.java b/ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/domain/CouponInfo.java index 5b352f5..a82e878 100644 --- a/ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/domain/CouponInfo.java +++ b/ruoyi-api/ruoyi-api-other/src/main/java/com/ruoyi/other/api/domain/CouponInfo.java @@ -11,6 +11,7 @@ import java.math.BigDecimal; import java.time.LocalDate; import java.time.LocalDateTime; +import java.util.List; /** * <p> @@ -126,13 +127,20 @@ @TableField("shelf_status") private Integer shelfStatus; + @ApiModelProperty(value = "指定会员等级,逗号隔开") + private String vipIds; + @ApiModelProperty(value = "已发放数量") @TableField(exist = false) private Long sendNumNow; - @ApiModelProperty(value = "指定会员等级,逗号隔开") - private String vipIds; + @ApiModelProperty(value = "其他商品名称") + private String goodsNames; + + @ApiModelProperty(value = "其他商品名称") + @TableField(exist = false) + private List<String> goodsNameList; public String getIdStr() { return String.valueOf(id); } diff --git a/ruoyi-service/ruoyi-account/src/main/resources/mapper/account/UserPointMapper.xml b/ruoyi-service/ruoyi-account/src/main/resources/mapper/account/UserPointMapper.xml index bb07244..3b734e3 100644 --- a/ruoyi-service/ruoyi-account/src/main/resources/mapper/account/UserPointMapper.xml +++ b/ruoyi-service/ruoyi-account/src/main/resources/mapper/account/UserPointMapper.xml @@ -50,15 +50,20 @@ ROW_NUMBER() OVER (PARTITION BY type ORDER BY create_time DESC) AS rn FROM t_user_point - ) AS subquery + <where> + <if test="startTime != null and endTime != null"> + create_time BETWEEN #{startTime} AND #{endTime} + </if> + <if test="type != null"> + AND type = #{type} + </if> + <if test="userIds != null and userIds.size !=0"> + AND app_user_id = #{appUserId} + </if> + </where> + ) AS subquery WHERE rn = 1 - <if test="type != null"> - AND type = #{type} - </if> - <if test="appUserId != null"> - AND app_user_id = #{appUserId} - </if> </select> </mapper> -- Gitblit v1.7.1