From aacd7867e566d8c25b8a6036aeee9f687b8bd4da Mon Sep 17 00:00:00 2001 From: hurui <177768073@qq.com> Date: Wed, 15 Mar 2023 09:22:22 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/bweb/controller/HighActivityInfoController.java | 7 +++++++ .../com/hai/service/impl/HighActivityInfoServiceImpl.java | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/hai-bweb/src/main/java/com/bweb/controller/HighActivityInfoController.java b/hai-bweb/src/main/java/com/bweb/controller/HighActivityInfoController.java index 497f0a7d..d4145b1c 100644 --- a/hai-bweb/src/main/java/com/bweb/controller/HighActivityInfoController.java +++ b/hai-bweb/src/main/java/com/bweb/controller/HighActivityInfoController.java @@ -208,8 +208,15 @@ public class HighActivityInfoController { @RequestParam(value = "pageSize", required = true) Integer pageSize) { { try { + //发布人员 + UserInfoModel userInfoModel = userCenter.getSessionModel(UserInfoModel.class); + if (userInfoModel.getBsCompany() == null) { + log.error("HighActivityInfoController -> editActivityInfo() error!","该主角色没有权限"); + throw ErrorHelp.genException(SysCode.System, ErrorCode.MENU_TREE_HAS_NOT_ERROR, ""); + } Map map = new HashMap<>(); + map.put("companyId", userInfoModel.getBsCompany().getId()); map.put("title", title); map.put("type", type); map.put("status", status); diff --git a/hai-service/src/main/java/com/hai/service/impl/HighActivityInfoServiceImpl.java b/hai-service/src/main/java/com/hai/service/impl/HighActivityInfoServiceImpl.java index 4106d999..259339bb 100644 --- a/hai-service/src/main/java/com/hai/service/impl/HighActivityInfoServiceImpl.java +++ b/hai-service/src/main/java/com/hai/service/impl/HighActivityInfoServiceImpl.java @@ -86,6 +86,10 @@ public class HighActivityInfoServiceImpl implements HighActivityInfoService { HighActivityInfoExample example = new HighActivityInfoExample(); HighActivityInfoExample.Criteria criteria = example.createCriteria().andStatusNotEqualTo(ActivityInfoStatus.status0.getNumber()); + if (MapUtils.getLong(param, "companyId") != null) { + criteria.andCompanyIdEqualTo(MapUtils.getLong(param, "companyId")); + } + if (StringUtils.isNotBlank(MapUtils.getString(param, "title"))) { criteria.andTitleLike("%"+MapUtils.getString(param, "title")+"%"); }