From 2fb70ef217bc1685a3a5085a6f13236f88d7af34 Mon Sep 17 00:00:00 2001 From: yujt Date: Fri, 22 May 2020 09:00:19 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E8=8E=B7=E5=8F=96=E4=B8=8B?= =?UTF-8?q?=E7=BA=A7=E6=9C=BA=E6=9E=84=E7=9A=84=E6=96=B9=E6=B3=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../esua/epdc/modules/feign/AdminFeignClient.java | 12 ++++++++++++ .../feign/fallback/AdminFeignClientFallback.java | 5 +++++ 2 files changed, 17 insertions(+) diff --git a/epdc-cloud-property/src/main/java/com/elink/esua/epdc/modules/feign/AdminFeignClient.java b/epdc-cloud-property/src/main/java/com/elink/esua/epdc/modules/feign/AdminFeignClient.java index fe70966..6304f68 100644 --- a/epdc-cloud-property/src/main/java/com/elink/esua/epdc/modules/feign/AdminFeignClient.java +++ b/epdc-cloud-property/src/main/java/com/elink/esua/epdc/modules/feign/AdminFeignClient.java @@ -39,4 +39,16 @@ public interface AdminFeignClient { */ @GetMapping("/sys/dept/getParentAndAllDept/{deptId}") Result getParentAndAllDept(@PathVariable("deptId") String deptId); + + /** + * 通过部门id,获取所有下级机构(包括冗余字段) + * + * @param typeKey 部门类别关键字{@link com.elink.esua.epdc.commons.tools.constant.OrganizationTypeConstant} + * @param deptId 部门id + * @return com.elink.esua.epdc.commons.tools.utils.Result> + * @author work@yujt.net.cn + * @date 2020/5/22 08:57 + */ + @GetMapping("optimize/deptlevel/listByParent/{typeKey}/{deptId}") + Result> listChildDeptLevelById(@PathVariable("typeKey") String typeKey, @PathVariable("deptId") Long deptId); } diff --git a/epdc-cloud-property/src/main/java/com/elink/esua/epdc/modules/feign/fallback/AdminFeignClientFallback.java b/epdc-cloud-property/src/main/java/com/elink/esua/epdc/modules/feign/fallback/AdminFeignClientFallback.java index b4f7c3f..ec461b2 100644 --- a/epdc-cloud-property/src/main/java/com/elink/esua/epdc/modules/feign/fallback/AdminFeignClientFallback.java +++ b/epdc-cloud-property/src/main/java/com/elink/esua/epdc/modules/feign/fallback/AdminFeignClientFallback.java @@ -26,4 +26,9 @@ public class AdminFeignClientFallback implements AdminFeignClient { public Result getParentAndAllDept(String depId) { return ModuleUtils.feignConError(ServiceConstant.EPDC_ADMIN_SERVER, "getParentAndAllDept", depId); } + + @Override + public Result> listChildDeptLevelById(String typeKey, Long deptId) { + return ModuleUtils.feignConError(ServiceConstant.EPDC_ADMIN_SERVER, "listChildDeptLevelById", typeKey, deptId); + } }