Browse Source

维多利亚

24282 2 years ago
parent
commit
8659e008d5

+ 4 - 10
bladex/blade-service-api/blade-system-api/src/main/java/org/springblade/system/feign/ISysClient.java

@@ -18,16 +18,10 @@ package org.springblade.system.feign;
 
 
 import org.springblade.core.launch.constant.AppConstant;
 import org.springblade.core.launch.constant.AppConstant;
 import org.springblade.core.tool.api.R;
 import org.springblade.core.tool.api.R;
-import org.springblade.system.entity.Dept;
-import org.springblade.system.entity.Menu;
-import org.springblade.system.entity.Param;
-import org.springblade.system.entity.Post;
-import org.springblade.system.entity.Region;
-import org.springblade.system.entity.Role;
-import org.springblade.system.entity.Tenant;
-import org.springblade.system.entity.TenantPackage;
+import org.springblade.system.entity.*;
 import org.springframework.cloud.openfeign.FeignClient;
 import org.springframework.cloud.openfeign.FeignClient;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
 import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RequestParam;
 import org.springframework.web.bind.annotation.RequestParam;
 
 
@@ -310,7 +304,7 @@ public interface ISysClient {
      * @param deptIds 部门ID集合
      * @param deptIds 部门ID集合
      * @return
      * @return
      */
      */
-    @GetMapping(GET_DEPT_BY_IDS)
+    @PostMapping(GET_DEPT_BY_IDS)
     List<Dept> getDeptByIds(@RequestBody List<Long> deptIds);
     List<Dept> getDeptByIds(@RequestBody List<Long> deptIds);
 
 
     /**
     /**
@@ -319,7 +313,7 @@ public interface ISysClient {
      * @param deptIds 部门ID集合
      * @param deptIds 部门ID集合
      * @return
      * @return
      */
      */
-    @GetMapping(GET_DEPT_BY_IDS_TO_MAP)
+    @PostMapping(GET_DEPT_BY_IDS_TO_MAP)
     Map<Long, Dept> getDeptByIdsToMap(@RequestBody List<Long> deptIds);
     Map<Long, Dept> getDeptByIdsToMap(@RequestBody List<Long> deptIds);
 
 
     /**
     /**

+ 11 - 18
bladex/blade-service/blade-system/src/main/java/org/springblade/system/feign/SysClient.java

@@ -19,23 +19,11 @@ package org.springblade.system.feign;
 import lombok.AllArgsConstructor;
 import lombok.AllArgsConstructor;
 import org.springblade.core.tenant.annotation.NonDS;
 import org.springblade.core.tenant.annotation.NonDS;
 import org.springblade.core.tool.api.R;
 import org.springblade.core.tool.api.R;
-import org.springblade.system.entity.Dept;
-import org.springblade.system.entity.Menu;
-import org.springblade.system.entity.Param;
-import org.springblade.system.entity.Post;
-import org.springblade.system.entity.Region;
-import org.springblade.system.entity.Role;
-import org.springblade.system.entity.Tenant;
-import org.springblade.system.entity.TenantPackage;
-import org.springblade.system.service.IDeptService;
-import org.springblade.system.service.IMenuService;
-import org.springblade.system.service.IParamService;
-import org.springblade.system.service.IPostService;
-import org.springblade.system.service.IRegionService;
-import org.springblade.system.service.IRoleService;
-import org.springblade.system.service.ITenantPackageService;
-import org.springblade.system.service.ITenantService;
+import org.springblade.system.entity.*;
+import org.springblade.system.service.*;
 import org.springframework.web.bind.annotation.GetMapping;
 import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.RequestBody;
 import org.springframework.web.bind.annotation.RestController;
 import org.springframework.web.bind.annotation.RestController;
 import springfox.documentation.annotations.ApiIgnore;
 import springfox.documentation.annotations.ApiIgnore;
 
 
@@ -212,6 +200,7 @@ public class SysClient implements ISysClient {
      * @return
      * @return
      */
      */
     @Override
     @Override
+    @GetMapping(GET_DEPTS)
     public List<Dept> getDepts() {
     public List<Dept> getDepts() {
         return deptService.getDepts();
         return deptService.getDepts();
     }
     }
@@ -223,7 +212,8 @@ public class SysClient implements ISysClient {
      * @return
      * @return
      */
      */
     @Override
     @Override
-    public List<Dept> getDeptByIds(List<Long> deptIds) {
+    @PostMapping(GET_DEPT_BY_IDS)
+    public List<Dept> getDeptByIds(@RequestBody List<Long> deptIds) {
         return deptService.getDeptByIds(deptIds);
         return deptService.getDeptByIds(deptIds);
     }
     }
 
 
@@ -234,7 +224,8 @@ public class SysClient implements ISysClient {
      * @return
      * @return
      */
      */
     @Override
     @Override
-    public Map<Long, Dept> getDeptByIdsToMap(List<Long> deptIds) {
+    @PostMapping(GET_DEPT_BY_IDS_TO_MAP)
+    public Map<Long, Dept> getDeptByIdsToMap(@RequestBody List<Long> deptIds) {
         return deptService.getDeptByIdsToMap(deptIds);
         return deptService.getDeptByIdsToMap(deptIds);
     }
     }
 
 
@@ -245,7 +236,9 @@ public class SysClient implements ISysClient {
      * @return
      * @return
      */
      */
     @Override
     @Override
+    @GetMapping(GET_DEPT_ANCESTORS_BY_ID)
     public List<Dept> getDeptAncestorsById(Long deptId) {
     public List<Dept> getDeptAncestorsById(Long deptId) {
         return deptService.getDeptAncestorsById(deptId);
         return deptService.getDeptAncestorsById(deptId);
     }
     }
+
 }
 }