From 92d79e47bfdae4a29c3e40af0b3e0e5ab8a47511 Mon Sep 17 00:00:00 2001
From: whyclxw <810412026@qq.com>
Date: 星期四, 12 六月 2025 09:59:00 +0800
Subject: [PATCH] Merge branch 'master' of http://118.89.139.230:10101/r/powerIntelligenceSystem

---
 src/main/java/com/whyc/service/AlarmInspectionService.java       |    2 +-
 src/main/java/com/whyc/controller/AlarmInspectionController.java |    4 ++--
 src/main/java/com/whyc/mapper/AlarmInspectionMapper.java         |    2 +-
 src/main/resources/mapper/AlarmInspectionMapper.xml              |    6 ++++++
 4 files changed, 10 insertions(+), 4 deletions(-)

diff --git a/src/main/java/com/whyc/controller/AlarmInspectionController.java b/src/main/java/com/whyc/controller/AlarmInspectionController.java
index e7d672e..3467b3e 100644
--- a/src/main/java/com/whyc/controller/AlarmInspectionController.java
+++ b/src/main/java/com/whyc/controller/AlarmInspectionController.java
@@ -26,8 +26,8 @@
     @Autowired
     private AlarmInspectionService service;
 
-    @ApiOperation("鏌ヨ绔欑偣瀵瑰簲鐨勫贰妫�鍗�")
-    @GetMapping("")
+    @ApiOperation(value = "鏌ヨ绔欑偣瀵瑰簲鐨勫贰妫�鍗�",notes = "inspectionType=1琛ㄧず鍛婅绾у埆涓�1鐨勬晠闅滃伐鍗�,inspectionType=2琛ㄧず鍛婅绾у埆涓�2鐨勫贰妫�澶囧繕褰�")
+    @GetMapping("getList")
     public Response getList(@RequestParam Integer stationId,@RequestParam Integer inspectionType){
         return service.getList(stationId,inspectionType);
     }
diff --git a/src/main/java/com/whyc/mapper/AlarmInspectionMapper.java b/src/main/java/com/whyc/mapper/AlarmInspectionMapper.java
index 9fa5b5d..7a9d35b 100644
--- a/src/main/java/com/whyc/mapper/AlarmInspectionMapper.java
+++ b/src/main/java/com/whyc/mapper/AlarmInspectionMapper.java
@@ -5,6 +5,6 @@
 import java.util.List;
 
 public interface AlarmInspectionMapper extends CustomMapper<AlarmInspection>{
-    List<AlarmInspection> getList(Integer stationId);
+    List<AlarmInspection> getList(Integer stationId, Integer inspectionType);
 
 }
diff --git a/src/main/java/com/whyc/service/AlarmInspectionService.java b/src/main/java/com/whyc/service/AlarmInspectionService.java
index 8fe391e..ae05a78 100644
--- a/src/main/java/com/whyc/service/AlarmInspectionService.java
+++ b/src/main/java/com/whyc/service/AlarmInspectionService.java
@@ -16,7 +16,7 @@
 
     public Response getList(Integer stationId, Integer inspectionType) {
         //闇�瑕侀檮鍔犲~鍏� 璐熻矗鐝粍淇℃伅 鍙� 鍛婅璇婃柇淇℃伅
-        List<AlarmInspection> list = mapper.getList(stationId);
+        List<AlarmInspection> list = mapper.getList(stationId,inspectionType);
         return new Response().set(1,list);
     }
 }
diff --git a/src/main/resources/mapper/AlarmInspectionMapper.xml b/src/main/resources/mapper/AlarmInspectionMapper.xml
index 55790d4..dbba3f1 100644
--- a/src/main/resources/mapper/AlarmInspectionMapper.xml
+++ b/src/main/resources/mapper/AlarmInspectionMapper.xml
@@ -68,5 +68,11 @@
         and ai.station_id = bgp.station_id
         and bg.baoji_group_id = bgp.baoji_group_id
         and ai.station_id = #{stationId}
+        <if test="inspectionType == 1">
+            and ai.alm_level = 1
+        </if>
+        <if test="inspectionType == 2">
+            and ai.alm_level != 1
+        </if>
     </select>
 </mapper>
\ No newline at end of file

--
Gitblit v1.9.1