From 75cf6d5a2484cc13ad78898e26e452ffa664f2cb Mon Sep 17 00:00:00 2001 From: xiangpei <xiangpei@timesnew.cn> Date: 星期一, 15 四月 2024 14:59:23 +0800 Subject: [PATCH] 阈值修改、阈值计算方法定义 --- ycl-server/src/main/java/com/ycl/platform/controller/CheckTemplateController.java | 29 +++++++++++++++++++---------- 1 files changed, 19 insertions(+), 10 deletions(-) diff --git a/ycl-server/src/main/java/com/ycl/platform/controller/CheckTemplateController.java b/ycl-server/src/main/java/com/ycl/platform/controller/CheckTemplateController.java index 2ec9af4..18f3e66 100644 --- a/ycl-server/src/main/java/com/ycl/platform/controller/CheckTemplateController.java +++ b/ycl-server/src/main/java/com/ycl/platform/controller/CheckTemplateController.java @@ -2,12 +2,15 @@ import annotation.Log; import com.ycl.platform.domain.entity.CheckTemplate; +import com.ycl.platform.domain.query.CheckTemplateQuery; import com.ycl.platform.service.ICheckTemplateService; import com.ycl.system.AjaxResult; +import com.ycl.system.Result; import com.ycl.system.controller.BaseController; import com.ycl.system.page.TableDataInfo; import com.ycl.utils.poi.ExcelUtil; import enumeration.BusinessType; +import io.swagger.annotations.ApiOperation; import jakarta.servlet.http.HttpServletResponse; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.access.prepost.PreAuthorize; @@ -31,24 +34,24 @@ /** * 鏌ヨ鑰冩牳妯℃澘鍒楄〃 */ - @PreAuthorize("@ss.hasPermi('system:template:list')") +// @PreAuthorize("@ss.hasPermi('system:template:list')") @GetMapping("/list") - public TableDataInfo list(CheckTemplate checkTemplate) + public TableDataInfo list(CheckTemplateQuery checkTemplateDTO) { startPage(); - List<CheckTemplate> list = checkTemplateService.selectCheckTemplateList(checkTemplate); + List<CheckTemplate> list = checkTemplateService.selectCheckTemplateList(checkTemplateDTO); return getDataTable(list); } /** * 瀵煎嚭鑰冩牳妯℃澘鍒楄〃 */ - @PreAuthorize("@ss.hasPermi('system:template:export')") +// @PreAuthorize("@ss.hasPermi('system:template:export')") @Log(title = "鑰冩牳妯℃澘", businessType = BusinessType.EXPORT) @PostMapping("/export") - public void export(HttpServletResponse response, CheckTemplate checkTemplate) + public void export(HttpServletResponse response, CheckTemplateQuery checkTemplateDTO) { - List<CheckTemplate> list = checkTemplateService.selectCheckTemplateList(checkTemplate); + List<CheckTemplate> list = checkTemplateService.selectCheckTemplateList(checkTemplateDTO); ExcelUtil<CheckTemplate> util = new ExcelUtil<CheckTemplate>(CheckTemplate.class); util.exportExcel(response, list, "鑰冩牳妯℃澘鏁版嵁"); } @@ -56,7 +59,7 @@ /** * 鑾峰彇鑰冩牳妯℃澘璇︾粏淇℃伅 */ - @PreAuthorize("@ss.hasPermi('system:template:query')") +// @PreAuthorize("@ss.hasPermi('system:template:query')") @GetMapping(value = "/{id}") public AjaxResult getInfo(@PathVariable("id") Long id) { @@ -66,12 +69,12 @@ /** * 鏂板鑰冩牳妯℃澘 */ - @PreAuthorize("@ss.hasPermi('system:template:add')") +// @PreAuthorize("@ss.hasPermi('system:template:add')") @Log(title = "鑰冩牳妯℃澘", businessType = BusinessType.INSERT) @PostMapping - public AjaxResult add(@RequestBody CheckTemplate checkTemplate) + public AjaxResult add(@RequestBody CheckTemplateQuery checkTemplateDTO) { - return toAjax(checkTemplateService.insertCheckTemplate(checkTemplate)); + return toAjax(checkTemplateService.insertCheckTemplate(checkTemplateDTO)); } /** @@ -95,4 +98,10 @@ { return toAjax(checkTemplateService.deleteCheckTemplateByIds(ids)); } + + @GetMapping("/pullList") + @ApiOperation(value = "鍒楄〃", notes = "鍒楄〃") + public Result pullList() { + return checkTemplateService.pullList(); + } } -- Gitblit v1.8.0