Commit dc532ab0 authored by maoying's avatar maoying

修改预案相关代码

parent 99fb3f63
......@@ -167,7 +167,7 @@ public class HandlerMqttMessageImpl implements IEquipmentHandlerService {
String title = String.format("/%s/%s", serviceName, "data/refresh/indexStatus");
webMqttComponent.publish(title, JSON.toJSONString(equipmentSpecificIndex));
}
Equipment equipment = impAndFireEquipMapper.queryImpEqumtByFireEquipmt(eqSpecId);
Equipment equipment = topicEntity.getEquipment()==null?impAndFireEquipMapper.queryImpEqumtByFireEquipmt(eqSpecId):topicEntity.getEquipment();
Toke toke = remoteSecurityService.getServerToken();
AlarmParam deviceData = new AlarmParam();
deviceData.setMonitor(equipment != null ? equipment.getName() : "");
......
......@@ -1074,13 +1074,12 @@ public class RiskSourceServiceImpl implements IRiskSourceService {
equipmentSpecificIndexVo.setType(typeCode);
TopicEntityVo topicEntity = new TopicEntityVo();
Equipment equipment = equipmentService.queryOne(id);
topicEntity.setMessage(JSON.toJSONString(equipmentSpecificIndexVo));
topicEntity.setEquipment(equipment);
String data = JSON.toJSONString(topicEntity);
System.out.println(data);
iEquipmentHandlerService.handlerMqttMessage("",data );
Equipment equipment = equipmentService.queryOne(id);
if (equipment != null) {
equipment.setStartTime(DateUtil.getDateNow());
equipment.setEndTime(null);
......
package com.yeejoin.amos.fas.business.vo;
import com.yeejoin.amos.fas.dao.entity.Equipment;
import io.swagger.annotations.ApiModel;
import lombok.Data;
......@@ -22,4 +24,6 @@ public class TopicEntityVo {
private String message;
private String type;
private Equipment equipment;
}
......@@ -52,7 +52,7 @@
left join f_fire_fighting_system as manage on spe.system_id = manage.SEQUENCE_NBR
where sto.amount <![CDATA[>]]> 0
<if test="name != null and name!='null' ">
and det.name like CONCAT('%',#{name},'%' )
and (det.name like CONCAT('%',#{name},'%') or ware.full_name like CONCAT('%',#{name},'%') or spe.iot_code like CONCAT('%',#{name},'%') or spe.code like CONCAT('%',#{name},'%'))
</if>
<if test="code != null and code!='null' ">
and cate.code like CONCAT('%',#{code},'%' )
......@@ -76,7 +76,7 @@
left join f_equipment_fire_equipment as fire on sto.id = fire.fire_equipment_id
where sto.amount <![CDATA[>]]> 0
<if test="name != null and name!='null' ">
and det.name like CONCAT('%',#{name},'%' )
and (det.name like CONCAT('%',#{name},'%') or ware.full_name like CONCAT('%',#{name},'%') or spe.iot_code like CONCAT('%',#{name},'%') or spe.code like CONCAT('%',#{name},'%'))
</if>
<if test="code != null and code!='null' ">
and cate.code like CONCAT('%',#{code},'%' )
......
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