Commit ea45878b authored by chenzhao's avatar chenzhao

修改代码

parent d38e16ff
...@@ -21,6 +21,8 @@ public class TopicEntityVo { ...@@ -21,6 +21,8 @@ public class TopicEntityVo {
private String message; private String message;
private String data;
private String type; private String type;
// 若是车辆返回车牌号 // 若是车辆返回车牌号
......
...@@ -1465,8 +1465,11 @@ public class MqttReceiveServiceImpl implements MqttReceiveService { ...@@ -1465,8 +1465,11 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
TopicEntityVo topicEntityVo = new TopicEntityVo(); TopicEntityVo topicEntityVo = new TopicEntityVo();
topicEntityVo.setIotCode(equipmentSpeIndex.getIotCode()); topicEntityVo.setIotCode(equipmentSpeIndex.getIotCode());
topicEntityVo.setTopic(riskTopicCreate); topicEntityVo.setTopic("equip/risk/trigger");
topicEntityVo.setMessage(JSON.toJSONString(detailVo)); detailVo.setEquipInfo(equipInfoVo);
detailVo.setAlarmInfo(alarmInfoVo);
// topicEntityVo.setMessage(JSON.toJSONString(detailVo));
topicEntityVo.setData(JSON.toJSONString(detailVo));
mqttSendGateway.sendToMqtt(riskTopicCreate, JSON.toJSONString(topicEntityVo)); mqttSendGateway.sendToMqtt(riskTopicCreate, JSON.toJSONString(topicEntityVo));
}); });
} }
......
...@@ -28,5 +28,10 @@ ...@@ -28,5 +28,10 @@
"code": "xf", "code": "xf",
"emqTopic": "emq.xf.created", "emqTopic": "emq.xf.created",
"akkaTopic": "JKXT2BP-XF-Topic" "akkaTopic": "JKXT2BP-XF-Topic"
},
{
"code": "risk",
"emqTopic": "emq.risk.created",
"akkaTopic": "JKXT2BP-RISK-Topic"
} }
] ]
\ No newline at end of file
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