From f0f9092bde94cae492e8d329d92a40cd118c358e Mon Sep 17 00:00:00 2001 From: cabbage <281119120@qq.com> Date: Tue, 22 Apr 2025 14:30:48 +0800 Subject: [PATCH] =?UTF-8?q?##=20=E4=B9=90=E5=AD=A6=E6=B3=A8=E5=86=8C?= =?UTF-8?q?=E4=B8=93=E5=8C=BA=E6=8E=A7=E5=88=B6=E6=98=BE=E7=A4=BA=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/impl/BdWaresServiceImpl.java | 33 ++++++++++--------- .../provider/AdvertBannerServiceProvider.java | 8 ----- 2 files changed, 18 insertions(+), 23 deletions(-) diff --git a/hzs-business/hzs-business-sale/src/main/java/com/hzs/sale/wares/service/impl/BdWaresServiceImpl.java b/hzs-business/hzs-business-sale/src/main/java/com/hzs/sale/wares/service/impl/BdWaresServiceImpl.java index 6351e5ac..8f4663a6 100644 --- a/hzs-business/hzs-business-sale/src/main/java/com/hzs/sale/wares/service/impl/BdWaresServiceImpl.java +++ b/hzs-business/hzs-business-sale/src/main/java/com/hzs/sale/wares/service/impl/BdWaresServiceImpl.java @@ -1153,6 +1153,10 @@ public class BdWaresServiceImpl extends ServiceImpl impl // // 可见乐学复购(标记是否乐学易考、金茗国际伞下) // boolean isLex = null != memberServiceApi.checkMemberByParentList(SysConstants.CHINA_LEX_REPURCHASE_LIST, userId).getData(); + // 注册专区权限 + boolean isLexRegister = ERegistrationAuthority.DECLARATION.getValue() == loginMember.getRegisterAuthority() + || ERegistrationAuthority.SERVICE.getValue() == loginMember.getRegisterAuthority(); + // 查询配置菜单列表 // 结算等级 int pkGrade = loginMember.getPkSettleGrade(); @@ -1195,13 +1199,13 @@ public class BdWaresServiceImpl extends ServiceImpl impl if (StringUtils.isNotBlank(sArea.getLabel())) { RecommendSpecialAreaVo recommendSpecialAreaVo = new RecommendSpecialAreaVo(); -// if (specialArea.equals(ESpecialArea.SPECIAL_REGISTER_AREA.getValue()) -// || specialArea.equals(ESpecialArea.SPECIAL_UPGRADE_AREA.getValue())) { -// // 2024.03.28 添加需求,只有指定4个账号可以看乐学注册、乐学升级 -// if (!isLexRegister) { -// continue; -// } -// } else if (specialArea.equals(ESpecialArea.SPECIAL_REPURCHASE_AREA.getValue())) { + if (specialArea.equals(ESpecialArea.SPECIAL_REGISTER_AREA.getValue())) { + // 乐学注册权限判断 + if (!isLexRegister) { + continue; + } + } +// else if (specialArea.equals(ESpecialArea.SPECIAL_REPURCHASE_AREA.getValue())) { // // 乐学复购专区处理 // if (!isLex) { // continue; @@ -1258,7 +1262,6 @@ public class BdWaresServiceImpl extends ServiceImpl impl resultList.sort(Comparator.comparingInt(RecommendSpecialAreaVo::getSort)); recommendWaresInfoVo.setRecommendSpecialAreaList(resultList); // 查询推荐商品 - List waresList = this.selectByRecommentList(pkCountry, specialAreaList); // 校验商品奖衔和等级/团队权限 List waresIdList = waresList.stream().map(BdWares::getPkId).collect(Collectors.toList()); @@ -1368,13 +1371,13 @@ public class BdWaresServiceImpl extends ServiceImpl impl // 商品信息填充 WaresVo waresVo = new WaresVo(); -// if (bdWares.getSpecialArea().equals(ESpecialArea.SPECIAL_REGISTER_AREA.getValue()) -// || bdWares.getSpecialArea().equals(ESpecialArea.SPECIAL_UPGRADE_AREA.getValue())) { -// // 2024.03.28 添加需求,只有指定4个账号可以看乐学注册、乐学升级 -// if (!isLexRegister) { -// continue; -// } -// } else if (bdWares.getSpecialArea().equals(ESpecialArea.SPECIAL_REPURCHASE_AREA.getValue())) { + if (bdWares.getSpecialArea().equals(ESpecialArea.SPECIAL_REGISTER_AREA.getValue())) { + // 乐学注册权限判断 + if (!isLexRegister) { + continue; + } + } +// else if (bdWares.getSpecialArea().equals(ESpecialArea.SPECIAL_REPURCHASE_AREA.getValue())) { // // 乐学复购专区处理 // if (!isLex) { // continue; diff --git a/hzs-business/hzs-business-system/src/main/java/com/hzs/system/config/provider/AdvertBannerServiceProvider.java b/hzs-business/hzs-business-system/src/main/java/com/hzs/system/config/provider/AdvertBannerServiceProvider.java index 254799f1..844032f2 100644 --- a/hzs-business/hzs-business-system/src/main/java/com/hzs/system/config/provider/AdvertBannerServiceProvider.java +++ b/hzs-business/hzs-business-system/src/main/java/com/hzs/system/config/provider/AdvertBannerServiceProvider.java @@ -14,14 +14,6 @@ import java.util.ArrayList; import java.util.List; import java.util.stream.Collectors; -/** - * @BelongsProject: hzs_cloud - * @BelongsPackage: com.hzs.system.config.provider - * @Author: yh - * @CreateTime: 2023-05-15 10:14 - * @Description: - * @Version: 1.0 - */ @DubboService public class AdvertBannerServiceProvider implements AdvertBannerServiceApi {