From 1772afb069b75871572c9c438bbd2bc403f864df Mon Sep 17 00:00:00 2001 From: puzhibing <393733352@qq.com> Date: 星期三, 13 十二月 2023 11:43:51 +0800 Subject: [PATCH] 修改bug --- ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/miniapp/AppActivityController.java | 8 +++++++- 1 files changed, 7 insertions(+), 1 deletions(-) diff --git a/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/miniapp/AppActivityController.java b/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/miniapp/AppActivityController.java index 7eb6f61..ea94908 100644 --- a/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/miniapp/AppActivityController.java +++ b/ruoyi-modules/ruoyi-goods/src/main/java/com/ruoyi/goods/controller/miniapp/AppActivityController.java @@ -49,14 +49,18 @@ public R<Page<AppActivityPageVo>> pageAppActivity(@RequestBody AppPageDto appPageDto) { Long userId = SecurityUtils.getUserId(); Long shopId = null; + Member member = null; if(userId!=null){ - Member member = memberService.getMember(userId).getData(); + member = memberService.getMember(userId).getData(); if(member!=null&&member.getRelationShopId()!=null){ shopId = member.getRelationShopId(); } } if(shopId==null){ throw new ServiceException(AppErrorConstant.NO_POSITION); + } + if(member!=null&&member.getBindingFlag()==0){ + shopId = null; } Page<AppActivityPageVo> page = new Page<>(); page.setSize(appPageDto.getPageSize()); @@ -74,6 +78,8 @@ Member member = memberService.getMember(userId).getData(); if(member!=null&&member.getRelationShopId()!=null){ appActivityGoodsPageDto.setShopId(member.getRelationShopId()); + }else{ + appActivityGoodsPageDto.setShopId(appActivityGoodsPageDto.getPositionShopId()); } } if(appActivityGoodsPageDto.getShopId()==null){ -- Gitblit v1.7.1