From fe2d5b14031edbe43238770fb1fc21e8a322b51a Mon Sep 17 00:00:00 2001 From: rentaiming <806181062@qq.com> Date: 星期四, 13 六月 2024 18:18:08 +0800 Subject: [PATCH] 用户端商品 --- ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/GoodsGroupPurchaseServiceImpl.java | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-) diff --git a/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/GoodsGroupPurchaseServiceImpl.java b/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/GoodsGroupPurchaseServiceImpl.java index b5c3e66..200e29e 100644 --- a/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/GoodsGroupPurchaseServiceImpl.java +++ b/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/GoodsGroupPurchaseServiceImpl.java @@ -8,6 +8,7 @@ import com.fasterxml.jackson.databind.ObjectMapper; import com.google.common.collect.Lists; import com.ruoyi.common.core.constant.SecurityConstants; +import com.ruoyi.common.core.enums.ClientTypeEnum; import com.ruoyi.common.core.enums.GroupStatusEnum; import com.ruoyi.common.core.enums.ListingStatusEnum; import com.ruoyi.common.core.enums.OrderStatusEnum; @@ -210,7 +211,7 @@ map.put("target_id", groupPurchaseId); map.put("message_type", "start"); String msg = objectMapper.writeValueAsString(map); - WebSocketUsers.sendMessageToUsersByText(msg); + WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.MEMBER.getCode(), msg); log.info("===================>发送websocket通知,消息体{}", msg); } } @@ -234,7 +235,7 @@ map.put("target_id", groupPurchaseId); map.put("message_type", "end"); String msg = objectMapper.writeValueAsString(map); - WebSocketUsers.sendMessageToUsersByText(msg); + WebSocketUsers.sendMessageToUsersByType(ClientTypeEnum.MEMBER.getCode(), msg); log.info("===================>发送websocket通知,消息体{}", msg); } } @@ -376,7 +377,9 @@ .collect(Collectors.toList()); Page<GoodsGroupPurchase> page = new Page<>(homeGoodsSkuDTO.getPageCurr(), homeGoodsSkuDTO.getPageSize()); LambdaQueryWrapper< GoodsGroupPurchase> wrapper= Wrappers.lambdaQuery(); - wrapper.in(GoodsGroupPurchase::getGoodsSkuId,goodsSkuIdList); + if (homeGoodsSkuDTO.getSkuName()!=null){ + wrapper.in(GoodsGroupPurchase::getId,goodsSkuIdList); + } wrapper.eq(GoodsGroupPurchase::getListingStatus,0); wrapper.eq( GoodsGroupPurchase::getDelFlag,0); Page< GoodsGroupPurchase> page1 = this.page(page, wrapper); -- Gitblit v1.7.1