| | |
| | | return success(true); |
| | | } |
| | | |
| | | @PutMapping("/update-sort-batch") |
| | | @Operation(summary = "批量更新流程分类的排序") |
| | | @Parameter(name = "ids", description = "分类编号列表", required = true, example = "1,2,3") |
| | | @PreAuthorize("@ss.hasPermission('bpm:category:update')") |
| | | public CommonResult<Boolean> updateCategorySortBatch(@RequestParam("ids") List<Long> ids) { |
| | | categoryService.updateCategorySortBatch(ids); |
| | | return success(true); |
| | | } |
| | | |
| | | @DeleteMapping("/delete") |
| | | @Operation(summary = "删除流程分类") |
| | | @Parameter(name = "id", description = "编号", required = true) |
| | |
| | | @Operation(summary = "获取流程分类的精简信息列表", description = "只包含被开启的分类,主要用于前端的下拉选项") |
| | | public CommonResult<List<BpmCategoryRespVO>> getCategorySimpleList() { |
| | | List<BpmCategoryDO> list = categoryService.getCategoryListByStatus(CommonStatusEnum.ENABLE.getStatus()); |
| | | BpmCategoryRespVO bpmCategoryRespVO = new BpmCategoryRespVO(); |
| | | BpmCategoryRespVO bpmCategoryRespVO1 = bpmCategoryRespVO.setName("123"); |
| | | list.sort(Comparator.comparingInt(BpmCategoryDO::getSort)); |
| | | return success(convertList(list, category -> new BpmCategoryRespVO().setId(category.getId()) |
| | | .setName(category.getName()).setCode(category.getCode()))); |