From 3aa7e668045d9976f98fde30f850993409110191 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=8E=8B=E5=85=B4=E7=90=B3?= <1911390090@qq.com> Date: Mon, 1 Jul 2024 16:56:08 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B0=94=E8=B1=A1=E8=AE=BE=E5=A4=87=20?= =?UTF-8?q?=E5=8F=82=E6=95=B0=E4=B8=A2=E5=A4=B1=E5=8A=A0=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../DcMeteorologicalDetectorController.java | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/zc-business/src/main/java/com/zc/business/controller/DcMeteorologicalDetectorController.java b/zc-business/src/main/java/com/zc/business/controller/DcMeteorologicalDetectorController.java index d42b6691..53fb97e9 100644 --- a/zc-business/src/main/java/com/zc/business/controller/DcMeteorologicalDetectorController.java +++ b/zc-business/src/main/java/com/zc/business/controller/DcMeteorologicalDetectorController.java @@ -2,11 +2,9 @@ package com.zc.business.controller; import com.ruoyi.common.core.controller.BaseController; import com.ruoyi.common.core.page.TableDataInfo; -import com.zc.business.domain.DcEvent; import com.zc.business.domain.DcMeteorologicalDetectorData; -import com.zc.business.service.IDcEventService; +import com.zc.business.enums.UniversalEnum; import com.zc.business.service.IDcMeteorologicalDetectorDataService; -import com.zc.business.service.impl.DcMeteorologicalDetectorDataServiceImpl; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; import org.springframework.beans.factory.annotation.Autowired; @@ -29,6 +27,8 @@ public class DcMeteorologicalDetectorController extends BaseController { @GetMapping("/deviceName") public TableDataInfo list(String deviceName) { + deviceName = deviceName.replace(UniversalEnum.BLANK_SPACE.getValue(), UniversalEnum.PLUS_SIGN.getValue()); + List> list = dcMeteorologicalDetectorDataService.selectStatistics(deviceName); return getDataTable(list); } @@ -36,6 +36,8 @@ public class DcMeteorologicalDetectorController extends BaseController { @GetMapping("/device/{deviceName}") public TableDataInfo deviceNameList(@PathVariable("deviceName") String deviceName) { + deviceName = deviceName.replace(UniversalEnum.BLANK_SPACE.getValue(), UniversalEnum.PLUS_SIGN.getValue()); + List list = dcMeteorologicalDetectorDataService.selectDeviceNameList(deviceName); return getDataTable(list); } @@ -59,6 +61,8 @@ public class DcMeteorologicalDetectorController extends BaseController { @GetMapping("/deviceHour") public TableDataInfo deviceHour(String deviceName,String specificDate) { + deviceName = deviceName.replace(UniversalEnum.BLANK_SPACE.getValue(), UniversalEnum.PLUS_SIGN.getValue()); + List> list = dcMeteorologicalDetectorDataService.selectStatisticsTime(deviceName,specificDate); return getDataTable(list); } @@ -66,6 +70,8 @@ public class DcMeteorologicalDetectorController extends BaseController { @GetMapping("/deviceDay") public TableDataInfo deviceDay(String deviceName,String specificDate) { + deviceName = deviceName.replace(UniversalEnum.BLANK_SPACE.getValue(), UniversalEnum.PLUS_SIGN.getValue()); + List> list = dcMeteorologicalDetectorDataService.selectStatisticsDay(deviceName,specificDate); return getDataTable(list); } @@ -73,6 +79,8 @@ public class DcMeteorologicalDetectorController extends BaseController { @GetMapping("/deviceYears") public TableDataInfo deviceYears(String deviceName,String specificDate) { + deviceName = deviceName.replace(UniversalEnum.BLANK_SPACE.getValue(), UniversalEnum.PLUS_SIGN.getValue()); + List> list = dcMeteorologicalDetectorDataService.selectStatisticsYears(deviceName,specificDate); return getDataTable(list); }