From 5e403b6ae6be0dd6473845c5db3a7562da47a15d Mon Sep 17 00:00:00 2001 From: dinggang <2498628697@qq.com> Date: Thu, 17 Nov 2022 14:52:55 +0800 Subject: [PATCH] =?UTF-8?q?=E5=90=8E=E5=8F=B0=E7=AE=A1=E7=90=86=E8=83=BD?= =?UTF-8?q?=E5=8A=9B=E7=BB=9F=E8=AE=A1-=E8=83=BD=E5=8A=9B=E4=BD=BF?= =?UTF-8?q?=E7=94=A8=E7=BB=9F=E8=AE=A1=E6=9F=A5=E8=AF=A2=E7=94=B3=E8=AF=B7?= =?UTF-8?q?=E9=83=A8=E9=97=A8=E5=88=97=E8=A1=A8=E6=8E=A5=E5=8F=A3=E4=BF=AE?= =?UTF-8?q?=E6=94=B9-=E5=8F=AA=E6=9F=A5=E8=AF=A2=E6=9C=89=E7=94=B3?= =?UTF-8?q?=E8=AF=B7=E8=AE=B0=E5=BD=95=E7=9A=84=E9=83=A8=E9=97=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../TAbilityApplicationController.java | 10 ++++++++ .../dao/TAbilityApplicationDao.java | 2 ++ .../service/TAbilityApplicationService.java | 7 ++++++ .../impl/TAbilityApplicationServiceImpl.java | 6 +++++ .../processForm/TAbilityApplicationDao.xml | 23 +++++++++++++++++++ .../resources/mapper/resource/ResourceDao.xml | 1 + 6 files changed, 49 insertions(+) diff --git a/renren-admin/src/main/java/io/renren/modules/processForm/controller/TAbilityApplicationController.java b/renren-admin/src/main/java/io/renren/modules/processForm/controller/TAbilityApplicationController.java index e73d3b5a..bdd8ccf3 100644 --- a/renren-admin/src/main/java/io/renren/modules/processForm/controller/TAbilityApplicationController.java +++ b/renren-admin/src/main/java/io/renren/modules/processForm/controller/TAbilityApplicationController.java @@ -213,10 +213,13 @@ public class TAbilityApplicationController { put("apply_flag", applyFlag); // 限定 } }; + + /* 2022-11-16 去除对用户角色的判断,在后台能力统计处都可以看到申请详情 // 非超级管理员,只出本人 if (user.getSuperAdmin() == SuperAdminEnum.NO.value()) { params.put("user_id", user == null ? null : user.getId()); } + */ List applicationDTOS = tAbilityApplicationService.list(params); Map> result = applicationDTOS.stream().collect(Collectors.groupingBy(t -> { SysDeptDTO sysDeptDTO = t.getResourceOwnerDept(); @@ -443,4 +446,11 @@ public class TAbilityApplicationController { return new Result(); } + @GetMapping("getApplyDeptList") + @ApiOperation("/获取申请部门列表") + @LogOperation("/获取申请部门列表") + public Result getApplyDeptList() { + return new Result().ok(tAbilityApplicationService.getApplyDeptList()); + } + } \ No newline at end of file diff --git a/renren-admin/src/main/java/io/renren/modules/processForm/dao/TAbilityApplicationDao.java b/renren-admin/src/main/java/io/renren/modules/processForm/dao/TAbilityApplicationDao.java index 37f4e35d..b76b42fe 100644 --- a/renren-admin/src/main/java/io/renren/modules/processForm/dao/TAbilityApplicationDao.java +++ b/renren-admin/src/main/java/io/renren/modules/processForm/dao/TAbilityApplicationDao.java @@ -47,4 +47,6 @@ public interface TAbilityApplicationDao extends BaseDao getInstanceIdByResId(Long id); + + List getApplyDeptList(); } \ No newline at end of file diff --git a/renren-admin/src/main/java/io/renren/modules/processForm/service/TAbilityApplicationService.java b/renren-admin/src/main/java/io/renren/modules/processForm/service/TAbilityApplicationService.java index 7eeadb89..5d379a62 100644 --- a/renren-admin/src/main/java/io/renren/modules/processForm/service/TAbilityApplicationService.java +++ b/renren-admin/src/main/java/io/renren/modules/processForm/service/TAbilityApplicationService.java @@ -51,4 +51,11 @@ public interface TAbilityApplicationService extends CrudService implements TAbilityApplicationService { private static final Logger logger = LoggerFactory.getLogger(TAbilityApplicationServiceImpl.class); + private TAbilityApplicationDao abilityApplicationDao; @Override public QueryWrapper getWrapper(Map params) { @@ -131,5 +132,10 @@ public class TAbilityApplicationServiceImpl extends CrudServiceImpl SELECT instance_id FROM t_ability_application WHERE resource_id = #{id} + + \ No newline at end of file diff --git a/renren-admin/src/main/resources/mapper/resource/ResourceDao.xml b/renren-admin/src/main/resources/mapper/resource/ResourceDao.xml index fe8b2de6..309a3f44 100644 --- a/renren-admin/src/main/resources/mapper/resource/ResourceDao.xml +++ b/renren-admin/src/main/resources/mapper/resource/ResourceDao.xml @@ -2322,6 +2322,7 @@ 1 = 1 AND tdr.del_flag = 0 AND tdr.dept_id = #{deptId} + AND tdr.type = '应用资源' AND tdr.name like CONCAT('%', #{key}, '%')