| | |
| | | @GetMapping("/get") |
| | | @Operation(summary = "获得会计科目") |
| | | @Parameter(name = "id", description = "科目编号", required = true, example = "1024") |
| | | @PreAuthorize("@ss.hasPermission('finance:account-subject:query')") |
| | | public CommonResult<FinAccountSubjectRespVO> getAccountSubject(@RequestParam("id") Long id) { |
| | | FinAccountSubjectDO subject = accountSubjectService.getAccountSubject(id); |
| | | return success(BeanUtils.toBean(subject, FinAccountSubjectRespVO.class)); |
| | |
| | | */ |
| | | @GetMapping("/page") |
| | | @Operation(summary = "获得会计科目分页", description = "pageSize 传 -1 表示查询全部(树形列表页组树用)") |
| | | @PreAuthorize("@ss.hasPermission('finance:account-subject:query')") |
| | | public CommonResult<PageResult<FinAccountSubjectRespVO>> getAccountSubjectPage(FinAccountSubjectPageReqVO pageReqVO) { |
| | | if (pageReqVO.getPageSize() == null || pageReqVO.getPageSize() < 1) { |
| | | pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE); |
| | |
| | | |
| | | @GetMapping("/list") |
| | | @Operation(summary = "获得会计科目树列表", description = "返回全量科目,按父子层级组装 children") |
| | | @PreAuthorize("@ss.hasPermission('finance:account-subject:query')") |
| | | public CommonResult<List<FinAccountSubjectRespVO>> getAccountSubjectList() { |
| | | return success(buildTree(accountSubjectService.getAccountSubjectList())); |
| | | } |