From 3d07e2187d3ce7e1555e29463e1e41c94f5a894e Mon Sep 17 00:00:00 2001 From: lSun <15893999301@qq.com> Date: Thu, 24 Jul 2025 19:01:18 +0800 Subject: [PATCH] =?UTF-8?q?=E5=B7=A5=E7=A8=8B=E5=AE=89=E5=85=A8=E5=88=86?= =?UTF-8?q?=E6=9E=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../EngineeringSafetyAnalysisController.java | 6 +- .../EngineeringSafetyAnalysisMapper.xml | 91 +++++++++++-------- 2 files changed, 58 insertions(+), 39 deletions(-) diff --git a/securitycontrol-model/securitycontrol-screen/src/main/java/com/securitycontrol/screen/controller/EngineeringSafetyAnalysisController.java b/securitycontrol-model/securitycontrol-screen/src/main/java/com/securitycontrol/screen/controller/EngineeringSafetyAnalysisController.java index 08f282e..7f32539 100644 --- a/securitycontrol-model/securitycontrol-screen/src/main/java/com/securitycontrol/screen/controller/EngineeringSafetyAnalysisController.java +++ b/securitycontrol-model/securitycontrol-screen/src/main/java/com/securitycontrol/screen/controller/EngineeringSafetyAnalysisController.java @@ -35,7 +35,7 @@ public class EngineeringSafetyAnalysisController extends BaseController { @ApiOperation(value = "查询安全隐患列表") @GetMapping("/list") public TableDataInfo list(EngineeringSafetyAnalysis environmentalReadings) { - startPage(); + startLayPage(); List list = environmentalReadingsService.selectEnvironmentalReadingsList(environmentalReadings); return getDataTableLayui(list); } @@ -67,7 +67,7 @@ public class EngineeringSafetyAnalysisController extends BaseController { @ApiOperation(value = "查询环境监测趋势列表") @GetMapping("/getEnvironmentalList") public TableDataInfo getEnvironmentalList(EngineeringSafetyAnalysis environmentalReadings) { - startPage(); + startLayPage(); List list = environmentalReadingsService.getEnvironmentalList(environmentalReadings); return getDataTableLayui(list); } @@ -78,7 +78,7 @@ public class EngineeringSafetyAnalysisController extends BaseController { @ApiOperation(value = "查询安全隐患分布列表") @GetMapping("/getHazardsList") public TableDataInfo getHazardsList(EngineeringSafetyAnalysis environmentalReadings) { - startPage(); + startLayPage(); List list = environmentalReadingsService.getHazardsList(environmentalReadings); return getDataTableLayui(list); } diff --git a/securitycontrol-model/securitycontrol-screen/src/main/resources/mapper/EngineeringSafetyAnalysisMapper.xml b/securitycontrol-model/securitycontrol-screen/src/main/resources/mapper/EngineeringSafetyAnalysisMapper.xml index 143c749..d592c37 100644 --- a/securitycontrol-model/securitycontrol-screen/src/main/resources/mapper/EngineeringSafetyAnalysisMapper.xml +++ b/securitycontrol-model/securitycontrol-screen/src/main/resources/mapper/EngineeringSafetyAnalysisMapper.xml @@ -26,6 +26,50 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" SELECT date, - AVG(temperature) AS temperature, - AVG(humidity) AS humidity, - AVG(wind_speed) AS wind_speed, - AVG(gas_value) AS gas_value + temperature , + humidity , + wind_speed , + gas_value FROM environmental_readings WHERE bid_code = #{bidCode} - GROUP BY - date ORDER BY date ASC @@ -109,7 +128,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" - SELECT id,date,temperature,humidity,wind_speed,gas_value FROM environmental_readings WHERE bid_code = #{bidCode} @@ -119,7 +138,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ORDER BY date ASC - SELECT id,type,level,timestamp FROM hazards WHERE bid_code = #{bidCode}