Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
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
项目统一框架
amos-boot-biz
Commits
2bd4b812
Commit
2bd4b812
authored
Sep 08, 2022
by
zhangsen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
向iot推送消息配置代码
parent
ca8eb07d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
0 deletions
+9
-0
MqttReceiveServiceImpl.java
...join/equipmanage/service/impl/MqttReceiveServiceImpl.java
+7
-0
application-dev.properties
...ystem-equip/src/main/resources/application-dev.properties
+2
-0
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/impl/MqttReceiveServiceImpl.java
View file @
2bd4b812
...
@@ -151,6 +151,9 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
...
@@ -151,6 +151,9 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
@Value
(
"${isSendApp}"
)
@Value
(
"${isSendApp}"
)
private
Boolean
isSendApp
;
private
Boolean
isSendApp
;
@Value
(
"${isSendIot:false}"
)
private
Boolean
isSendIot
;
private
static
Boolean
bool
=
Boolean
.
FALSE
;
private
static
Boolean
bool
=
Boolean
.
FALSE
;
@Override
@Override
...
@@ -171,6 +174,10 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
...
@@ -171,6 +174,10 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
if
(
eqIotCodeList
.
size
()
>
1
)
{
if
(
eqIotCodeList
.
size
()
>
1
)
{
log
.
info
(
"有重复的{}数据!"
,
iotCode
);
log
.
info
(
"有重复的{}数据!"
,
iotCode
);
}
}
//给 iot服务 推送消息 插数据到 influxdb
if
(
isSendIot
)
{
mqttSendGateway
.
sendToMqtt
(
"influxdb/"
+
topic
.
substring
(
0
,
endIndex
),
message
);
}
EquipmentSpecificVo
vo
=
eqIotCodeList
.
get
(
0
);
EquipmentSpecificVo
vo
=
eqIotCodeList
.
get
(
0
);
topicEntity
.
setType
(
vo
.
getType
());
topicEntity
.
setType
(
vo
.
getType
());
topicEntity
.
setCode
(
vo
.
getCode
());
topicEntity
.
setCode
(
vo
.
getCode
());
...
...
amos-boot-system-equip/src/main/resources/application-dev.properties
View file @
2bd4b812
...
@@ -93,4 +93,6 @@ equipment.plan.pump=92010600,92030600,92130400,92140200,92150300
...
@@ -93,4 +93,6 @@ equipment.plan.pump=92010600,92030600,92130400,92140200,92150300
#iot.code.prefix.have.used=20210003,20210004,20210005
#iot.code.prefix.have.used=20210003,20210004,20210005
# 电力使用
# 电力使用
iot.code.prefix.have.used
=
iot.code.prefix.have.used
=
#是否向iot推送消息
isSendIot
=
false
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