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
f28ed374
Commit
f28ed374
authored
Aug 27, 2020
by
高东东
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改动态预案
parent
9d09c034
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
26 additions
and
9 deletions
+26
-9
ContingencyAction.java
...m/yeejoin/amos/fas/business/action/ContingencyAction.java
+22
-8
ContingencyRo.java
...yeejoin/amos/fas/business/action/model/ContingencyRo.java
+2
-0
RiskSourceServiceImpl.java
...amos/fas/business/service/impl/RiskSourceServiceImpl.java
+2
-1
No files found.
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/action/ContingencyAction.java
View file @
f28ed374
...
...
@@ -672,9 +672,6 @@ public class ContingencyAction implements CustomerAction {
content
.
put
(
"stepCode"
,
stepCode
);
content
.
put
(
"buttonCode"
,
buttonCode
);
result
.
add
(
tempmap1
);
DeviceRo
ro
=
(
DeviceRo
)
paramObj
;
Map
<
String
,
Object
>
equipemtnPoints
=
pointCache
.
get
(
ro
.
getEquipmentId
());
...
...
@@ -684,8 +681,8 @@ public class ContingencyAction implements CustomerAction {
equipemtnPoints
.
put
(
stepCode
+
"-"
+
buttonCode
,
content
);
tempmap1
.
put
(
"type"
,
"buttonCache"
);
tempmap1
.
put
(
"content"
,
equipemtnPoints
.
values
());
this
.
sendcmd
(
"message"
,
null
,
result
);
result
.
add
(
tempmap1
);
this
.
sendcmd
(
"message"
,
ro
,
result
);
}
@RuleMethod
(
methodLabel
=
"清除步骤执行"
,
project
=
"青海换流站消防预案"
)
...
...
@@ -712,11 +709,9 @@ public class ContingencyAction implements CustomerAction {
}
else
{
tempmap1
.
put
(
"content"
,
new
ArrayList
());
}
tempmap1
.
put
(
"content"
,
equipemtnPoints
.
values
());
result
.
add
(
tempmap1
);
this
.
sendcmd
(
"message"
,
paramObj
,
result
);
this
.
sendcmd
(
"message"
,
ro
,
result
);
}
@RuleMethod
(
methodLabel
=
"同步自动执行步骤"
,
project
=
"青海换流站消防预案"
)
...
...
@@ -734,6 +729,25 @@ public class ContingencyAction implements CustomerAction {
this
.
sendcmd
(
"message"
,
paramObj
,
result
);
}
public
void
sendcmd
(
String
msgType
,
DeviceRo
deviceRo
,
SafteyPlanResult
result
)
{
Constructor
<?>
constructor
;
try
{
constructor
=
Class
.
forName
(
PACKAGEURL
+
result
.
getClass
().
getSimpleName
()
+
"Message"
)
.
getConstructor
(
ActionResult
.
class
);
AbstractActionResultMessage
<?>
action
=
(
AbstractActionResultMessage
<?>)
constructor
.
newInstance
(
result
);
if
(
"mqtt"
.
equals
(
pushType
.
toLowerCase
()))
{
ToipResponse
toipResponse
=
action
.
buildResponse
(
msgType
,
deviceRo
,
result
.
toJson
());
String
topic
=
String
.
format
(
"/%s/%s/%s"
,
serviceName
,
"yinan"
,
"plan"
);
log
.
info
(
String
.
format
(
"mqtt[%s]:【 %s 】"
,
topic
,
toipResponse
.
toJsonStr
()));
webMqttComponent
.
publish
(
topic
,
toipResponse
.
toJsonStr
());
}
else
if
(
"websocket"
.
equals
(
pushType
.
toLowerCase
())){
action
.
execute
(
msgType
,
deviceRo
);
}
}
catch
(
Exception
e
)
{
e
.
printStackTrace
();
}
}
private
void
stopSnapshop
(
ContingencyRo
contingencyRo
)
{
if
(
RuleRunigSnapshotServiceImpl
.
getReplayBatchNo
()
!=
null
&&
!
RuleRunigSnapshotServiceImpl
.
getReplayBatchNo
().
equals
(
contingencyRo
.
getBatchNo
()))
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/action/model/ContingencyRo.java
View file @
f28ed374
...
...
@@ -71,6 +71,8 @@ public class ContingencyRo implements Serializable {
private
String
buttonState
;
@Label
(
"步骤状态"
)
private
String
stepState
;
//步骤操作状态
@Label
(
"重点设备编码"
)
private
String
equipmentCode
;
private
Date
createDate
=
new
Date
();
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/impl/RiskSourceServiceImpl.java
View file @
f28ed374
...
...
@@ -538,7 +538,8 @@ public class RiskSourceServiceImpl implements IRiskSourceService {
contingencyRo
.
setFireTruckRoute
(
equipment
.
getFireTruckRoute
());
contingencyRo
.
setRunstep
(
false
);
contingencyRo
.
setEquipmentPosition3d
(
equipment
.
getPosition3d
());
contingencyRo
.
setEquipmentCode
(
equipment
.
getCode
());
Map
cameraInfo
=
impAndFireEquipMapper
.
queryForCamera
(
String
.
valueOf
(
equipment
.
getId
()));
if
(
cameraInfo
!=
null
)
{
...
...
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