Commit b998a6e6 authored by tangwei's avatar tangwei

修改bug

parent 57681b38
......@@ -506,51 +506,56 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
// 直流中心消息推送刷新
publishDataToDCCenterPage(equipmentSpecificIndexList);
}
});
if(vo.getEcode()!=null){
String ecode= vo.getEcode();
boolean flag=false;
//消防泵
String[] strings = pumpCodes.split(",");
for (String string : strings) {
if(ecode.startsWith(string)){
//通知>消防应急预案
topicEntity.setType("xfb");
mqttSendGateway.sendToMqtt(emergencyDisposalIndicators, JSONObject.toJSONString(topicEntity));
flag=true;
break;
}
}
// 消防炮
String[] stringxfp = monitorCodes.split(",");
if(!flag){
for (String string1 : stringxfp) {
if(ecode.startsWith(string1)){
//通知>消防应急预案
topicEntity.setType("xfp");
mqttSendGateway.sendToMqtt(emergencyDisposalIndicators, JSONObject.toJSONString(topicEntity));
flag=true;
break;
if(vo.getEcode()!=null){
String ecode= vo.getEcode();
boolean flag=false;
//消防泵
String[] strings = pumpCodes.split(",");
for (String string : strings) {
if(ecode.startsWith(string)){
//通知>消防应急预案
topicEntity.setType("xfb");
mqttSendGateway.sendToMqtt(emergencyDisposalIndicators, JSONObject.toJSONString(topicEntity));
flag=true;
break;
}
}
// 消防炮
String[] stringxfp = monitorCodes.split(",");
if(!flag){
for (String string1 : stringxfp) {
if(ecode.startsWith(string1)){
//通知>消防应急预案
topicEntity.setType("xfp");
mqttSendGateway.sendToMqtt(emergencyDisposalIndicators, JSONObject.toJSONString(topicEntity));
flag=true;
break;
}
}
}
//消防水源
if(!flag){
List<Map> lit= iEquipmentSpecificSerivce.getwater(vo.getId());
if(lit!=null&& lit.size()>0){
topicEntity.setType("xfsy");
mqttSendGateway.sendToMqtt(emergencyDisposalIndicators, JSONObject.toJSONString(topicEntity));
}
}
}
}
//消防水源
if(!flag){
List<Map> lit= iEquipmentSpecificSerivce.getwater(vo.getId());
if(lit!=null&& lit.size()>0){
topicEntity.setType("xfsy");
mqttSendGateway.sendToMqtt(emergencyDisposalIndicators, JSONObject.toJSONString(topicEntity));
}
});
}
}
}
......
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 to comment