Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
traffic-signal-platform
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
signal
traffic-signal-platform
Commits
c2efea8a
Commit
c2efea8a
authored
Apr 05, 2023
by
duanruiming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[update] 离线告警;锁定恢复优化
parent
2226de7f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
5 deletions
+14
-5
FeignProxyServiceImpl.java
...ava/net/wanji/web/service/impl/FeignProxyServiceImpl.java
+3
-1
CommonEventWarnTask.java
...src/main/java/net/wanji/web/task/CommonEventWarnTask.java
+10
-3
CommonEventAlarmOutVo.java
...anji/web/vo/situationDetection/CommonEventAlarmOutVo.java
+1
-1
No files found.
signal-control-service/src/main/java/net/wanji/web/service/impl/FeignProxyServiceImpl.java
View file @
c2efea8a
...
...
@@ -124,14 +124,16 @@ public class FeignProxyServiceImpl implements FeignProxyService {
@Override
public
JsonViewObject
lockControl
(
LockControlVO
lockControlVO
)
{
String
resultMessage
=
"锁定控制-相位锁定控制成功"
;
Integer
control
=
4
;
if
(
lockControlVO
.
getCommand
()
==
0
)
{
resultMessage
=
"锁定控制-相位锁定恢复成功"
;
control
=
1
;
}
JsonViewObject
jsonViewObject
=
utcFeignClients
.
lockControl
(
lockControlVO
);
if
(
Objects
.
isNull
(
jsonViewObject
)
||
jsonViewObject
.
getCode
()
!=
200
)
{
return
jsonViewObject
.
fail
(
"锁定控制-相位锁定/解锁UTC服务调用异常"
);
}
insertControlHist
(
lockControlVO
.
getCrossCode
(),
4
,
Constants
.
ProcessService
.
ADMIN_ID
);
insertControlHist
(
lockControlVO
.
getCrossCode
(),
control
,
Constants
.
ProcessService
.
ADMIN_ID
);
return
jsonViewObject
.
success
(
resultMessage
);
}
...
...
signal-control-service/src/main/java/net/wanji/web/task/CommonEventWarnTask.java
View file @
c2efea8a
...
...
@@ -30,7 +30,7 @@ import java.util.*;
*/
@Component
@Slf4j
public
class
CommonEventWarnTask
{
public
class
CommonEventWarnTask
{
@Autowired
private
UtcFeignClients
utcFeignClients
;
...
...
@@ -95,10 +95,12 @@ public class CommonEventWarnTask {
Map
<
String
,
Object
>
result
=
map
;
String
signalId
=
(
String
)
result
.
get
(
"signalId"
);
String
crossId
=
(
String
)
result
.
get
(
"crossId"
);
Integer
currentStatus
=
(
Integer
)
result
.
get
(
"status"
);
Integer
currentFaultType
=
(
Integer
)
result
.
get
(
"faultType"
);
String
coordinate
=
""
;
String
crossName
=
""
;
int
faultTypeDB
=
0
;
int
statusDB
=
0
;
if
(
StringUtils
.
isNotEmpty
(
crossId
))
{
CrossInfoPO
tBaseCrossInfo
=
situationDetectionService
.
selectCrossInfoById
(
crossId
);
if
(
Objects
.
nonNull
(
tBaseCrossInfo
))
{
...
...
@@ -108,16 +110,21 @@ public class CommonEventWarnTask {
TDeviceStatusInfo
tDeviceStatusInfo
=
tDeviceStatusMapper
.
selectOne
(
queryWrapper
.
eq
(
"code"
,
crossId
));
if
(
Objects
.
nonNull
(
tDeviceStatusInfo
))
{
faultTypeDB
=
tDeviceStatusInfo
.
getFaultType
();
statusDB
=
tDeviceStatusInfo
.
getStatus
();
crossName
=
tDeviceStatusInfo
.
getName
();
}
}
if
(
Objects
.
nonNull
(
currentFaultType
)
&&
currentFaultType
!=
faultType
DB
)
{
if
(
(
Objects
.
nonNull
(
currentFaultType
)
&&
currentFaultType
!=
faultTypeDB
)
||
currentStatus
!=
status
DB
)
{
CommonEventAlarmOutVo
commonEventAlarmOutVo
=
new
CommonEventAlarmOutVo
();
commonEventAlarmOutVo
.
setEventType
(
3
);
commonEventAlarmOutVo
.
setEventId
(
signalId
);
commonEventAlarmOutVo
.
setEventName
(
crossName
);
commonEventAlarmOutVo
.
setEventDesc
(
crossName
.
concat
(
"信号机告警"
));
commonEventAlarmOutVo
.
setStatus
(
String
.
valueOf
(
currentFaultType
));
if
(
currentStatus
==
0
)
{
commonEventAlarmOutVo
.
setStatus
(
"11"
);
}
else
{
commonEventAlarmOutVo
.
setStatus
(
String
.
valueOf
(
currentFaultType
));
}
commonEventAlarmOutVo
.
setStartTime
(
formatNow
);
commonEventAlarmOutVo
.
setCoordinate
(
coordinate
);
results
.
add
(
commonEventAlarmOutVo
);
...
...
signal-control-service/src/main/java/net/wanji/web/vo/situationDetection/CommonEventAlarmOutVo.java
View file @
c2efea8a
...
...
@@ -24,7 +24,7 @@ public class CommonEventAlarmOutVo {
@ApiModelProperty
(
value
=
"事件描述"
)
String
eventDesc
;
@ApiModelProperty
(
value
=
"事件状态:路口报警:状态 0正常 1失衡 2拥堵 3溢出 4死锁;事件报警:1事故 2拥堵 3管制 4施工; 信号机故障:0正常 1检测器故障 2时钟故障 3电源故障 4驱动模块故障 5信号灯故障 6箱门开启 7方案错误 8绿冲突 9红全熄 10行人红熄"
)
@ApiModelProperty
(
value
=
"事件状态:路口报警:状态 0正常 1失衡 2拥堵 3溢出 4死锁;事件报警:1事故 2拥堵 3管制 4施工; 信号机故障:0正常 1检测器故障 2时钟故障 3电源故障 4驱动模块故障 5信号灯故障 6箱门开启 7方案错误 8绿冲突 9红全熄 10行人红熄
11通讯中断
"
)
String
status
;
@ApiModelProperty
(
value
=
"发生时间"
)
...
...
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