添加通过部门编号查询部门接口
This commit is contained in:
@@ -60,6 +60,11 @@ public interface DeptFeignClient {
|
||||
@GetMapping("/getDeptById")
|
||||
HttpResult<Dept> getDeptById(@RequestParam("deptId") String deptId);
|
||||
|
||||
/**
|
||||
* 根据部门code获取部门信息
|
||||
*/
|
||||
@GetMapping("/getDeptByCode")
|
||||
HttpResult<Dept> getDeptByCode(@RequestParam("deptCode") String deptCode);
|
||||
|
||||
/**
|
||||
* 根据部门id获取所有子部门ids
|
||||
|
||||
@@ -70,6 +70,12 @@ public class DeptFeignClientFallbackFactory implements FallbackFactory<DeptFeign
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
|
||||
@Override
|
||||
public HttpResult<Dept> getDeptByCode(String deptCode) {
|
||||
log.error("{}异常,降级处理,异常为:{}","查询部门信息异常",cause.toString());
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
|
||||
@Override
|
||||
public HttpResult<List<String>> getDepSonIdtByDeptId(String deptId) {
|
||||
log.error("{}异常,降级处理,异常为:{}","查询所有子孙部门异常",cause.toString());
|
||||
|
||||
Reference in New Issue
Block a user