1.app远程接口代码提交
This commit is contained in:
@@ -125,4 +125,12 @@ public interface DeptFeignClient {
|
||||
*/
|
||||
@GetMapping("/getDepSonDetailIdByDeptId")
|
||||
HttpResult<List<DeptDTO>> getDepSonDetailByDeptId(@RequestParam("deptId") String deptId);
|
||||
|
||||
/**
|
||||
* 根据部门id查询当前部门所有父级部门id
|
||||
* @param deptId
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/getUpByDeptIds")
|
||||
HttpResult<List<String>> getUpByDeptIds(@RequestParam("deptId") String deptId);
|
||||
}
|
||||
|
||||
@@ -64,4 +64,12 @@ public interface UserFeignClient {
|
||||
*/
|
||||
@PostMapping("/userByIdList")
|
||||
HttpResult<List<User>> getUserByIdList(@RequestBody List<String> ids);
|
||||
|
||||
/**
|
||||
* 根据部门ids查询用户信息
|
||||
* @param deptId
|
||||
* @return
|
||||
*/
|
||||
@GetMapping("/getUserByDeptIds")
|
||||
HttpResult<List<User>> getUserByDeptIds(@RequestBody List<String> deptId);
|
||||
}
|
||||
|
||||
@@ -122,6 +122,12 @@ public class DeptFeignClientFallbackFactory implements FallbackFactory<DeptFeign
|
||||
log.error("{}异常,降级处理,异常为:{}","查询前部门的的下级子部门list,(如果没子部门就是返回当前部门)",cause.toString());
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
|
||||
@Override
|
||||
public HttpResult<List<String>> getUpByDeptIds(String deptId) {
|
||||
log.error("{}异常,降级处理,异常为:{}","根据部门id查询当前部门所有父级部门id",cause.toString());
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -66,6 +66,12 @@ public class UserFeignClientFallbackFactory implements FallbackFactory<UserFeign
|
||||
log.error("{}异常,降级处理,异常为:{}","根据用户id集合查询用户信息",cause.toString());
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
|
||||
@Override
|
||||
public HttpResult<List<User>> getUserByDeptIds(List<String> deptId) {
|
||||
log.error("{}异常,降级处理,异常为:{}","根据部门ids查询用户信息",cause.toString());
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user