From 7fce3006ecd0b670e33c2d3ba123778e79e2e943 Mon Sep 17 00:00:00 2001 From: 潘志宝 <979469083@qq.com> Date: 星期一, 06 一月 2025 09:18:25 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/sche/controller/admin/StScheduleSchemeController.java | 20 ++++++++++++++++++-- 1 files changed, 18 insertions(+), 2 deletions(-) diff --git a/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/sche/controller/admin/StScheduleSchemeController.java b/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/sche/controller/admin/StScheduleSchemeController.java index 12da0e3..3c45312 100644 --- a/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/sche/controller/admin/StScheduleSchemeController.java +++ b/iailab-module-model/iailab-module-model-biz/src/main/java/com/iailab/module/model/mcs/sche/controller/admin/StScheduleSchemeController.java @@ -76,14 +76,14 @@ @GetMapping("/page") @Operation(summary = "获得调度方案分页") @PreAuthorize("@ss.hasPermission('sche:scheme:query')") - public CommonResult<PageResult<StScheduleSchemeRespVO>> getTenantPage(@Valid StScheduleSchemePageReqVO pageVO) { + public CommonResult<PageResult<StScheduleSchemeRespVO>> getPage(@Valid StScheduleSchemePageReqVO pageVO) { PageResult<StScheduleSchemeEntity> pageResult = stScheduleSchemeService.page(pageVO); return success(BeanUtils.toBean(pageResult, StScheduleSchemeRespVO.class)); } @GetMapping("/export-excel") @Operation(summary = "导出调度方案 Excel") - @PreAuthorize("@ss.hasPermission('system:tenant:export')") + @PreAuthorize("@ss.hasPermission('sche:scheme:export')") @ApiAccessLog(operateType = EXPORT) public void exportTenantExcel(@Valid StScheduleSchemePageReqVO exportReqVO, HttpServletResponse response) throws IOException { @@ -93,4 +93,20 @@ ExcelUtils.write(response, "调度方案.xls", "数据", StScheduleSchemeEntity.class, BeanUtils.toBean(list, StScheduleSchemeEntity.class)); } + + @PreAuthorize("@ss.hasPermission('sche:scheme:update')") + @PutMapping("/enable") + @Operation(summary = "启用") + public CommonResult<Boolean> enable(@RequestBody String[] ids) { + stScheduleSchemeService.enableByIds(ids); + return success(true); + } + + @PreAuthorize("@ss.hasPermission('sche:scheme:update')") + @PutMapping("/disable") + @Operation(summary = "禁用") + public CommonResult<Boolean> disable(@RequestBody String[] ids) { + stScheduleSchemeService.disableByIds(ids); + return success(true); + } } \ No newline at end of file -- Gitblit v1.9.3