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/YwThresholdController.java |   48 +++++++++++++++++++++++++++---------------------
 1 files changed, 27 insertions(+), 21 deletions(-)

diff --git a/ycl-server/src/main/java/com/ycl/platform/controller/YwThresholdController.java b/ycl-server/src/main/java/com/ycl/platform/controller/YwThresholdController.java
index 526fa72..f314698 100644
--- a/ycl-server/src/main/java/com/ycl/platform/controller/YwThresholdController.java
+++ b/ycl-server/src/main/java/com/ycl/platform/controller/YwThresholdController.java
@@ -2,14 +2,19 @@
 
 import annotation.Log;
 import com.ycl.platform.domain.entity.YwThreshold;
+import com.ycl.platform.domain.form.CarThresholdForm;
+import com.ycl.platform.domain.form.FaceThresholdForm;
+import com.ycl.platform.domain.form.VideoThresholdForm;
 import com.ycl.platform.service.IYwThresholdService;
 import com.ycl.system.AjaxResult;
 import com.ycl.system.controller.BaseController;
+import com.ycl.system.domain.group.Update;
 import com.ycl.system.page.TableDataInfo;
 import com.ycl.utils.poi.ExcelUtil;
 import enumeration.BusinessType;
 import jakarta.servlet.http.HttpServletResponse;
 import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.validation.annotation.Validated;
 import org.springframework.web.bind.annotation.*;
 
 import java.util.List;
@@ -59,32 +64,33 @@
     }
 
     /**
-     * 鏂板杩愮淮闃堝��
-     */
-    // @PreAuthorize("@ss.hasPermi('ycl:threshold:add')")
-    @Log(title = "杩愮淮闃堝��", businessType = BusinessType.INSERT)
-    @PostMapping
-    public AjaxResult add(@RequestBody YwThreshold ywThreshold) {
-        return toAjax(ywThresholdService.insertYwThreshold(ywThreshold));
-    }
-
-    /**
-     * 淇敼杩愮淮闃堝��
+     * 淇敼浜鸿劯闃堝��
      */
     // @PreAuthorize("@ss.hasPermi('ycl:threshold:edit')")
-    @Log(title = "杩愮淮闃堝��", businessType = BusinessType.UPDATE)
-    @PutMapping
-    public AjaxResult edit(@RequestBody YwThreshold ywThreshold) {
-        return toAjax(ywThresholdService.updateYwThreshold(ywThreshold));
+    @Log(title = "淇敼浜鸿劯杩愮淮闃堝��", businessType = BusinessType.UPDATE)
+    @PutMapping("/face")
+    public AjaxResult editFace(@RequestBody @Validated FaceThresholdForm form) {
+        return toAjax(ywThresholdService.editFace(form));
     }
 
     /**
-     * 鍒犻櫎杩愮淮闃堝��
+     * 淇敼杞﹁締闃堝��
      */
-    // @PreAuthorize("@ss.hasPermi('ycl:threshold:remove')")
-    @Log(title = "杩愮淮闃堝��", businessType = BusinessType.DELETE)
-    @DeleteMapping("/{ids}")
-    public AjaxResult remove(@PathVariable Integer[] ids) {
-        return toAjax(ywThresholdService.deleteYwThresholdByIds(ids));
+    // @PreAuthorize("@ss.hasPermi('ycl:threshold:edit')")
+    @Log(title = "淇敼杞﹁締闃堝��", businessType = BusinessType.UPDATE)
+    @PutMapping("/car")
+    public AjaxResult editCar(@RequestBody @Validated CarThresholdForm form) {
+        return toAjax(ywThresholdService.editCar(form));
     }
+
+    /**
+     * 淇敼瑙嗛闃堝��
+     */
+    // @PreAuthorize("@ss.hasPermi('ycl:threshold:edit')")
+    @Log(title = "淇敼瑙嗛闃堝��", businessType = BusinessType.UPDATE)
+    @PutMapping("video")
+    public AjaxResult editVideo(@RequestBody @Validated VideoThresholdForm form) {
+        return toAjax(ywThresholdService.editVideo(form));
+    }
+
 }

--
Gitblit v1.8.0