| | |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "获取部门列表") |
| | | @PreAuthorize("@ss.hasPermission('system:dept:query')") |
| | | public CommonResult<List<DeptRespVO>> getDeptList(DeptListReqVO reqVO) { |
| | | List<DeptDO> list = deptService.getDeptList(reqVO); |
| | | return success(BeanUtils.toBean(list, DeptRespVO.class)); |
| | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "获得部门信息") |
| | | @Parameter(name = "id", description = "编号", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('system:dept:query')") |
| | | public CommonResult<DeptRespVO> getDept(@RequestParam("id") Long id) { |
| | | DeptDO dept = deptService.getDept(id); |
| | | return success(BeanUtils.toBean(dept, DeptRespVO.class)); |