From af136a73561c05342e87f35845539128bd40b41b Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Tue, 9 May 2023 20:12:55 +0800 Subject: [PATCH 1/2] =?UTF-8?q?#bug=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/hnac/hzims/operational/alert/mapper/AbnormalAlarmMapper.xml | 1 + .../operational/station/service/impl/RealMonitorServiceImpl.java | 6 ------ 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/alert/mapper/AbnormalAlarmMapper.xml b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/alert/mapper/AbnormalAlarmMapper.xml index 5519b3d..034ec61 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/alert/mapper/AbnormalAlarmMapper.xml +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/alert/mapper/AbnormalAlarmMapper.xml @@ -11,6 +11,7 @@ diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/RealMonitorServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/RealMonitorServiceImpl.java index 49939a5..f3f2bc7 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/RealMonitorServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/RealMonitorServiceImpl.java @@ -178,12 +178,6 @@ public class RealMonitorServiceImpl implements IRealMonitorService { List objects = redisClient.getBatchRealDataByRealId(stationReal.getStation(),realIds); for(int i = 0; i < realIds.size() ;i++){ if(ObjectUtil.isEmpty(objects.get(i))){ - Map attribute = new ConcurrentHashMap<>(); - attribute.put("realId",realIds.get(i)); - attribute.put("value","0"); - attribute.put("time",DateUtil.format(new Date(),"yyyy-MM-dd HH:mm:ss.s")); - valueMap.put(realIdArr[i],attribute.get("value")); - keyMap.put(realIdArr[i],attribute); log.error(realIds.get(i) + "is null"); }else{ Map attribute = (Map) JSONObject.parse(objects.get(i)); From b878505be19bed1c51f932315042b42b921906f2 Mon Sep 17 00:00:00 2001 From: yang_shj <1069818635@QQ.com> Date: Tue, 9 May 2023 20:51:12 +0800 Subject: [PATCH 2/2] =?UTF-8?q?#bug=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hzims/operational/station/entity/StationEntity.java | 13 +++++-------- .../station/service/impl/StationServiceImpl.java | 6 +++++- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/station/entity/StationEntity.java b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/station/entity/StationEntity.java index 6e9450d..d55aa6b 100644 --- a/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/station/entity/StationEntity.java +++ b/hzims-service-api/hzims-operational-api/src/main/java/com/hnac/hzims/operational/station/entity/StationEntity.java @@ -1,18 +1,16 @@ package com.hnac.hzims.operational.station.entity; -import com.baomidou.mybatisplus.annotation.FieldStrategy; import com.baomidou.mybatisplus.annotation.SqlCondition; import com.baomidou.mybatisplus.annotation.TableField; import com.baomidou.mybatisplus.annotation.TableName; import com.fasterxml.jackson.annotation.JsonFormat; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.databind.annotation.JsonDeserialize; import com.fasterxml.jackson.databind.annotation.JsonSerialize; import com.fasterxml.jackson.databind.ser.std.NullSerializer; -import com.fasterxml.jackson.datatype.jsr310.deser.LocalDateTimeDeserializer; -import com.fasterxml.jackson.datatype.jsr310.ser.LocalDateTimeSerializer; import io.swagger.annotations.ApiModelProperty; -import lombok.*; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; import org.springblade.core.mp.support.QueryField; import org.springblade.core.tenant.mp.TenantEntity; import org.springblade.core.tool.utils.DateUtil; @@ -26,7 +24,6 @@ import java.time.LocalDateTime; @EqualsAndHashCode(callSuper = true) @Data @TableName("HZIMS_STATION") -@Builder @AllArgsConstructor @NoArgsConstructor public class StationEntity extends TenantEntity implements Serializable { @@ -158,5 +155,5 @@ public class StationEntity extends TenantEntity implements Serializable { private String secretKey; @ApiModelProperty("是否发送告警短信: 1-发送短信 0-不发送短信") - private Integer isSendMessage; + private Integer sendMessageFlag; } diff --git a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/StationServiceImpl.java b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/StationServiceImpl.java index 85ee6c1..6ab53ce 100644 --- a/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/StationServiceImpl.java +++ b/hzims-service/operational/src/main/java/com/hnac/hzims/operational/station/service/impl/StationServiceImpl.java @@ -6,6 +6,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage; import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.hnac.hzims.common.service.UserAuthDataService; import com.hnac.hzims.fdp.feign.IQuestionClient; +import com.hnac.hzims.hzimsweather.response.air.Station; import com.hnac.hzims.operational.OperationalConstants; import com.hnac.hzims.operational.main.vo.StationCountVo; import com.hnac.hzims.operational.station.StationConstants; @@ -276,7 +277,10 @@ public class StationServiceImpl extends BaseServiceImpl 0 ? codeList.get(0) : null; if (ObjectUtil.isNotEmpty(object)) { - return StationEntity.builder().code(stationId).enableControl(2).build(); + StationEntity result = new StationEntity(); + result.setCode(stationId); + result.setEnableControl(2); + return result; } else { stationEntity.setEnableControl(0); return stationEntity;