From a9e8e5245d9725aedd712e04fc56cd4aa8dece14 Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Fri, 19 Jan 2024 15:11:57 +0800 Subject: [PATCH] =?UTF-8?q?#=E7=AB=99=E7=82=B9=E7=AD=9B=E9=80=89=E5=91=8A?= =?UTF-8?q?=E8=AD=A6=E6=97=A0=E6=95=88=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../alert/service/impl/HistoryAbnormalAlarmServiceImpl.java | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/alert/service/impl/HistoryAbnormalAlarmServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/alert/service/impl/HistoryAbnormalAlarmServiceImpl.java index e02cfe7..f6e34ea 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/alert/service/impl/HistoryAbnormalAlarmServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/alert/service/impl/HistoryAbnormalAlarmServiceImpl.java @@ -10,7 +10,10 @@ import com.hnac.hzims.operational.alert.entity.HistoryAbnormalAlarmEntity; import com.hnac.hzims.operational.alert.mapper.HistoryAbnormalAlarmMapper; import com.hnac.hzims.operational.alert.service.AlarmHandleService; import com.hnac.hzims.operational.alert.service.HistoryAbnormalAlarmService; -import com.hnac.hzims.operational.alert.vo.*; +import com.hnac.hzims.operational.alert.vo.AlarmDataVo; +import com.hnac.hzims.operational.alert.vo.AlarmParamVo; +import com.hnac.hzims.operational.alert.vo.AlarmReustVo; +import com.hnac.hzims.operational.alert.vo.HistoryAlarmVo; import com.hnac.hzims.operational.config.vo.AlarmDataPageVo; import com.hnac.hzims.operational.config.vo.AlarmVo; import com.hnac.hzims.operational.config.vo.IntelligentAlarmCountVo; @@ -38,7 +41,6 @@ import org.springblade.core.tool.utils.ObjectUtil; import org.springblade.system.entity.Dept; import org.springblade.system.feign.ISysClient; import org.springframework.beans.factory.annotation.Value; -import org.springframework.data.redis.core.RedisTemplate; import org.springframework.stereotype.Service; import java.lang.reflect.Field; @@ -46,7 +48,6 @@ import java.math.BigDecimal; import java.time.LocalDateTime; import java.time.format.DateTimeFormatter; import java.util.*; -import java.util.concurrent.TimeUnit; import java.util.stream.Collectors; /** @@ -225,7 +226,9 @@ public class HistoryAbnormalAlarmServiceImpl extends BaseServiceImpl wrapper = Wrappers.lambdaQuery(); wrapper.eq(StationEntity::getServeType,HomePageConstant.HYDROPOWER_SERVETYPE); wrapper.in(StationEntity::getRefDept,result.getData().stream().map(Dept::getId).collect(Collectors.toList())); - + if(StringUtils.isNotEmpty(param.getCode())){ + wrapper.eq(StationEntity::getCode,param.getCode()); + } List stations = stationService.list(wrapper); if(CollectionUtil.isEmpty(stations)){ return new AlarmReustVo();