| | |
| | | import com.github.xiaoymin.knife4j.annotations.ApiOperationSupport; |
| | | import io.swagger.annotations.*; |
| | | import lombok.AllArgsConstructor; |
| | | import org.springblade.common.vo.DeptVo; |
| | | import org.springblade.core.boot.ctrl.BladeController; |
| | | import org.springblade.core.cache.utils.CacheUtil; |
| | | import org.springblade.core.log.annotation.ApiLog; |
| | |
| | | } |
| | | |
| | | /** |
| | | * 获取处警员树形结构 |
| | | */ |
| | | @GetMapping("/Batrees") |
| | | @ApiOperationSupport(order = 4) |
| | | @ApiOperation(value = "树形结构", notes = "树形结构") |
| | | public R<List<DeptVO>> Batrees(String tenantId, BladeUser bladeUser) { |
| | | List<DeptVO> tree = deptService.Batrees(); |
| | | return R.data(tree); |
| | | } |
| | | |
| | | /** |
| | | * 懒加载获取部门树形结构 |
| | | */ |
| | | @GetMapping("/lazy-tree") |
| | |
| | | List<DeptVO> tree = deptService.lazyTree(Func.toStrWithEmpty(tenantId, bladeUser.getTenantId()), parentId); |
| | | return R.data(tree); |
| | | } |
| | | |
| | | /** |
| | | * 懒加载获取部门树形结构 |
| | | */ |
| | | @GetMapping("/lazy-trees") |
| | | @ApiOperationSupport(order = 5) |
| | | @ApiOperation(value = "懒加载树形结构", notes = "树形结构") |
| | | public R<List<DeptVO>> lazyTrees(String tenantId, Long parentId, BladeUser bladeUser) { |
| | | List<DeptVO> tree = deptService.lazyTrees(Func.toStrWithEmpty(tenantId, bladeUser.getTenantId()), parentId); |
| | | return R.data(tree); |
| | | } |
| | | |
| | | |
| | | /** |
| | | * 新增或修改 |
| | |
| | | public R selectInfo() { |
| | | return R.data(deptService.selectInfo()); |
| | | } |
| | | |
| | | /** |
| | | * 查询所有的部门信息 |
| | | * @return |
| | | */ |
| | | @GetMapping("/selDeptList") |
| | | public List<DeptVo> selDeptList() { |
| | | return deptService.selDeptList(); |
| | | } |
| | | } |