Commit 8f2fcb58 by huangjy

Merge remote-tracking branch 'origin/dev' into dev

parents 9852247d 469f2909
...@@ -113,7 +113,7 @@ public class BreathAlarm implements IAlarm { ...@@ -113,7 +113,7 @@ public class BreathAlarm implements IAlarm {
} }
if ((br > end || br < start)) { if ((br > end || br < start) && StringUtils.equalsAnyIgnoreCase(messageType, "REPORT_PROPERTY")) {
if(alarmRedisDTO==null){ if(alarmRedisDTO==null){
alarmRedisDTO = new AlarmRedisDTO(); alarmRedisDTO = new AlarmRedisDTO();
alarmRedisDTO.setAlarm(CommonEnum.NO.getValue()); alarmRedisDTO.setAlarm(CommonEnum.NO.getValue());
......
...@@ -106,10 +106,11 @@ public class FallAlarm implements IAlarm { ...@@ -106,10 +106,11 @@ public class FallAlarm implements IAlarm {
String ruleConfigStr = config.getRuleConfig(); String ruleConfigStr = config.getRuleConfig();
JSONObject properties = platAlarmCheckDTO.getProperties(); JSONObject properties = platAlarmCheckDTO.getProperties();
String messageType = platAlarmCheckDTO.getMessageType(); String messageType = platAlarmCheckDTO.getMessageType();
String deviceId = platDevice.getId(); String deviceId = platDevice.getId();
if(properties == null ){
properties = new JSONObject();
}
String personState = Convert.toStr(properties.get("personState"));
String person = Convert.toStr(properties.get("person")); String person = Convert.toStr(properties.get("person"));
PlatAlarmConfigBehaviorDTOVO ruleConfig = JsonUtil.toObj(ruleConfigStr, PlatAlarmConfigBehaviorDTOVO.class); PlatAlarmConfigBehaviorDTOVO ruleConfig = JsonUtil.toObj(ruleConfigStr, PlatAlarmConfigBehaviorDTOVO.class);
Integer duration = ruleConfig.getAverageDuration();//分钟 Integer duration = ruleConfig.getAverageDuration();//分钟
......
...@@ -102,7 +102,7 @@ public class HeartAlarm implements IAlarm { ...@@ -102,7 +102,7 @@ public class HeartAlarm implements IAlarm {
return; return;
} }
if ((hr > end || hr < start)) { if ((hr > end || hr < start) && StringUtils.equalsAnyIgnoreCase(messageType, "REPORT_PROPERTY")) {
if(alarmRedisDTO==null){ if(alarmRedisDTO==null){
alarmRedisDTO = new AlarmRedisDTO(); alarmRedisDTO = new AlarmRedisDTO();
alarmRedisDTO.setAlarm(CommonEnum.NO.getValue()); alarmRedisDTO.setAlarm(CommonEnum.NO.getValue());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment