Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YeeAmosFireAutoSysRoot
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
station
YeeAmosFireAutoSysRoot
Commits
718a5316
Commit
718a5316
authored
Jun 17, 2022
by
maoying
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加物联信号自动触发预案事件
parent
dc587efd
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
22 additions
and
25 deletions
+22
-25
DeviceRo.java
.../com/yeejoin/amos/fas/business/action/model/DeviceRo.java
+4
-4
HandlerMqttMessageImpl.java
...mos/fas/business/service/impl/HandlerMqttMessageImpl.java
+15
-21
application.properties
...ireAutoSysStart/src/main/resources/application.properties
+3
-0
No files found.
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/action/model/DeviceRo.java
View file @
718a5316
...
@@ -19,13 +19,13 @@ public class DeviceRo implements Serializable{
...
@@ -19,13 +19,13 @@ public class DeviceRo implements Serializable{
private
String
pointCode
;
private
String
pointCode
;
@Label
(
"值"
)
@Label
(
"值"
)
private
String
value
;
private
String
value
;
@Label
(
"装备ID"
)
@Label
(
"
电力
装备ID"
)
private
Long
equipmentId
;
private
Long
equipmentId
;
@Label
(
"装备编码"
)
@Label
(
"
电力
装备编码"
)
private
String
equipmentCode
;
private
String
equipmentCode
;
@Label
(
"
重点
装备编码"
)
@Label
(
"
消防
装备编码"
)
private
String
equipmentSpecificCode
;
private
String
equipmentSpecificCode
;
@Label
(
"
重点
装备ID"
)
@Label
(
"
消防
装备ID"
)
private
Long
equipmentSpecificId
;
private
Long
equipmentSpecificId
;
@Label
(
"物联编码"
)
@Label
(
"物联编码"
)
private
String
iotCode
;
private
String
iotCode
;
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/impl/HandlerMqttMessageImpl.java
View file @
718a5316
...
@@ -135,6 +135,9 @@ public class HandlerMqttMessageImpl implements IEquipmentHandlerService {
...
@@ -135,6 +135,9 @@ public class HandlerMqttMessageImpl implements IEquipmentHandlerService {
@Value
(
"${autoSys.fire.pool.index_key}"
)
@Value
(
"${autoSys.fire.pool.index_key}"
)
private
String
firePoolIndexKey
;
private
String
firePoolIndexKey
;
@Value
(
"${plan.index}"
)
private
String
planIndex
;
@Autowired
@Autowired
PlanDetailMapper
planDetailMapper
;
PlanDetailMapper
planDetailMapper
;
...
@@ -198,17 +201,6 @@ public class HandlerMqttMessageImpl implements IEquipmentHandlerService {
...
@@ -198,17 +201,6 @@ public class HandlerMqttMessageImpl implements IEquipmentHandlerService {
String
msg
=
JSON
.
toJSONString
(
equipmentSpecificIndex
);
String
msg
=
JSON
.
toJSONString
(
equipmentSpecificIndex
);
String
title
=
String
.
format
(
"/%s/%s"
,
serviceName
,
"data/refresh/indexStatus"
);
String
title
=
String
.
format
(
"/%s/%s"
,
serviceName
,
"data/refresh/indexStatus"
);
webMqttComponent
.
publish
(
title
,
msg
);
webMqttComponent
.
publish
(
title
,
msg
);
// // 中心级系统指标推送消息
// if ("FIREALARM".equals(typeCode) && "true".equals(equipmentSpecificIndex.getValue()) && PlanFlagBo.getFlag()) {
// log.info("RocketMQ发送的主题是: " + rocketTopic + ", 消息体是: " + msg + "!");
// try {
// // rocketMQTemplate.convertAndSend(rocketTopic, msg);
// PlanFlagBo.setFlag(Boolean.FALSE);
// } catch (Exception e) {
// throw new RuntimeException("RocketMQ消息发送失败!");
// }
// }
}
}
Equipment
equipment
=
topicEntity
.
getEquipment
()
==
null
?
impAndFireEquipMapper
.
queryImpEqumtByFireEquipmt
(
eqSpecId
)
:
topicEntity
.
getEquipment
();
Equipment
equipment
=
topicEntity
.
getEquipment
()
==
null
?
impAndFireEquipMapper
.
queryImpEqumtByFireEquipmt
(
eqSpecId
)
:
topicEntity
.
getEquipment
();
...
@@ -281,16 +273,18 @@ public class HandlerMqttMessageImpl implements IEquipmentHandlerService {
...
@@ -281,16 +273,18 @@ public class HandlerMqttMessageImpl implements IEquipmentHandlerService {
String
title
=
String
.
format
(
"/%s/%s/%s"
,
serviceName
,
stationName
,
"data/refresh/monitorData"
);
String
title
=
String
.
format
(
"/%s/%s/%s"
,
serviceName
,
stationName
,
"data/refresh/monitorData"
);
webMqttComponent
.
publish
(
title
,
JSON
.
toJSONString
(
view3dService
.
getEquipStatusList
(
equipmentSpecific
.
getOrgCode
())));
webMqttComponent
.
publish
(
title
,
JSON
.
toJSONString
(
view3dService
.
getEquipStatusList
(
equipmentSpecific
.
getOrgCode
())));
}
}
DeviceRo
deviceRo
=
new
DeviceRo
();
//根据指标数据处理预案按钮
// Equipment equipment1 = impAndFireEquipMapper.queryImpEqumtByFireEquipmt(eqSpecId);
if
(
planIndex
.
contains
(
nameKey
)
&&
!
ObjectUtils
.
isEmpty
(
equipment
)){
// deviceRo.setEquipmentCode(equipment1.getCode());
DeviceRo
deviceRo
=
new
DeviceRo
();
// deviceRo.setEquipmentId(equipment1.getId());
deviceRo
.
setEquipmentCode
(
equipment
.
getCode
());
deviceRo
.
setEquipmentSpecificId
(
equipmentSpecific
.
getId
());
deviceRo
.
setEquipmentId
(
equipment
.
getId
());
deviceRo
.
setEquipmentSpecificCode
(
equipmentSpecific
.
getCode
());
deviceRo
.
setEquipmentSpecificId
(
equipmentSpecific
.
getId
());
deviceRo
.
setIotCode
(
equipmentSpecific
.
getIotCode
());
deviceRo
.
setEquipmentSpecificCode
(
equipmentSpecific
.
getCode
());
deviceRo
.
setValue
(
equipmentSpecificIndex
.
getValue
());
deviceRo
.
setIotCode
(
equipmentSpecific
.
getIotCode
());
deviceRo
.
setEquipmentIndexKey
(
equipmentSpecificIndex
.
getNameKey
());
deviceRo
.
setValue
(
equipmentSpecificIndex
.
getValue
());
planAutoExec
(
equipment
,
toke
,
deviceRo
);
deviceRo
.
setEquipmentIndexKey
(
equipmentSpecificIndex
.
getNameKey
());
planAutoExec
(
equipment
,
toke
,
deviceRo
);
}
}
}
/**
/**
...
...
YeeAmosFireAutoSysStart/src/main/resources/application.properties
View file @
718a5316
...
@@ -113,6 +113,9 @@ privilege.fegin.name=AMOS-API-PRIVILEGE
...
@@ -113,6 +113,9 @@ privilege.fegin.name=AMOS-API-PRIVILEGE
#当前gateway的IP地址
#当前gateway的IP地址
now.gateway.address
=
http://172.16.10.72:10005/
now.gateway.address
=
http://172.16.10.72:10005/
#预案指标配置
plan.index
=
ONL_OilDischargeDeviceOilPillowDischargeOpen,CAFS_CAFSFireGunEquipmentValveStatus,DCCP_DCCPStreamTransformerCharged,WSS_DelugeValve_Start
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment