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
jinan
traffic-signal-platform
Commits
6879bee8
Commit
6879bee8
authored
Mar 19, 2025
by
黄伟铭
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修正干线路口问题列表状态
parent
d728164e
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
19 additions
and
26 deletions
+19
-26
TrunkLineImpl.java
...in/java/net/wanji/opt/servicev2/implv2/TrunkLineImpl.java
+5
-1
TrunkLineCrossProblemEntity.java
...wanji/opt/synthesis/pojo/TrunkLineCrossProblemEntity.java
+2
-1
TrunkLineCrossProblemVO.java
.../main/java/net/wanji/opt/vo2/TrunkLineCrossProblemVO.java
+2
-1
TrunkLineMapper.xml
...ize-service/src/main/resources/mapper/TrunkLineMapper.xml
+10
-23
No files found.
signal-optimize-service/src/main/java/net/wanji/opt/servicev2/implv2/TrunkLineImpl.java
View file @
6879bee8
...
@@ -40,10 +40,14 @@ public class TrunkLineImpl implements TrunkLineService {
...
@@ -40,10 +40,14 @@ public class TrunkLineImpl implements TrunkLineService {
vo
.
setCrossID
(
e
.
getCrossID
());
vo
.
setCrossID
(
e
.
getCrossID
());
vo
.
setName
(
e
.
getName
());
vo
.
setName
(
e
.
getName
());
vo
.
setWkt
(
e
.
getWkt
());
if
(
e
.
getDirection
()
!=
null
)
{
if
(
e
.
getDirection
()
!=
null
)
{
String
temp
=
e
.
getDirection
().
substring
(
1
,
e
.
getDirection
().
length
()
-
1
);
temp
=
temp
.
replace
(
"\""
,
""
);
String
[]
temp1
=
temp
.
split
(
","
);
Map
<
String
,
Integer
>
directionMap
=
new
HashMap
<>();
Map
<
String
,
Integer
>
directionMap
=
new
HashMap
<>();
for
(
String
s
:
e
.
getDirection
()
)
{
for
(
String
s
:
temp1
)
{
directionMap
.
put
(
s
,
directionMap
.
getOrDefault
(
s
,
0
)
+
1
);
directionMap
.
put
(
s
,
directionMap
.
getOrDefault
(
s
,
0
)
+
1
);
}
}
...
...
signal-optimize-service/src/main/java/net/wanji/opt/synthesis/pojo/TrunkLineCrossProblemEntity.java
View file @
6879bee8
...
@@ -9,6 +9,7 @@ public class TrunkLineCrossProblemEntity {
...
@@ -9,6 +9,7 @@ public class TrunkLineCrossProblemEntity {
private
Integer
inDir
;
private
Integer
inDir
;
private
Integer
outDir
;
private
Integer
outDir
;
private
Integer
status
;
private
Integer
status
;
private
String
[]
direction
;
private
String
direction
;
private
String
startTime
;
private
String
startTime
;
private
String
wkt
;
}
}
signal-optimize-service/src/main/java/net/wanji/opt/vo2/TrunkLineCrossProblemVO.java
View file @
6879bee8
...
@@ -23,6 +23,7 @@ public class TrunkLineCrossProblemVO {
...
@@ -23,6 +23,7 @@ public class TrunkLineCrossProblemVO {
private
String
dir_1_name
;
private
String
dir_1_name
;
@ApiModelProperty
(
value
=
"方向2"
)
@ApiModelProperty
(
value
=
"方向2"
)
private
String
dir_2_name
;
private
String
dir_2_name
;
@ApiModelProperty
(
value
=
"路口坐标"
)
private
String
wkt
;
}
}
signal-optimize-service/src/main/resources/mapper/TrunkLineMapper.xml
View file @
6879bee8
...
@@ -74,30 +74,17 @@
...
@@ -74,30 +74,17 @@
) b
) b
</select>
</select>
<select
id=
"getTrunkLineCrossProblem"
parameterType=
"map"
resultType=
"net.wanji.opt.synthesis.pojo.TrunkLineCrossProblemEntity"
>
<select
id=
"getTrunkLineCrossProblem"
parameterType=
"map"
resultType=
"net.wanji.opt.synthesis.pojo.TrunkLineCrossProblemEntity"
>
select
select a.cross_id,b.name,SUBSTR(b.location , 7 , LENGTH(b.location) - 7) as wkt,a.status,a.direction , a.start_time
a.cross_id,
from t_cross_data_hist a
b.name,
left join t_base_cross_info b on a.cross_id = b.id
a.`status`,
where a.cross_id in (select cross_id from t_greenwave_cross where green_id = 1)
a.direction ,
<if
test=
"time == null or time == '' "
>
MAX(a.start_time) as start_time
and DATE_FORMAT(a.start_time, '%Y-%m-%d %H:%i:00')= DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(DATE_SUB(now(),INTERVAL 5 MINUTE)) / 300 ) * 300), '%Y-%m-%d %H:%i:00')
from
</if>
t_cross_data_hist a
<if
test=
"time != null and time != '' "
>
left join t_base_cross_info b on
and DATE_FORMAT(a.start_time, '%Y-%m-%d %H:%i:00')= DATE_FORMAT(FROM_UNIXTIME(FLOOR(UNIX_TIMESTAMP(#{time}) / 300 ) * 300), '%Y-%m-%d %H:%i:00')
a.cross_id = b.id
</if>
where
a.cross_id in (
select
cross_id
from
t_greenwave_cross
where
green_id = #{greenID})
<if
test=
"time != null and time != ''"
>
and DATE_FORMAT(a.start_time, '%Y-%m-%d %H:%i:%s')
<![CDATA[ <= ]]>
DATE_FORMAT(#{time}, '%Y-%m-%d %H:%i:%s')
</if>
group by
a.cross_id
</select>
</select>
<select
id=
"getIODir"
parameterType=
"map"
resultType=
"net.wanji.opt.synthesis.pojo.TrunkLineCrossProblemEntity"
>
<select
id=
"getIODir"
parameterType=
"map"
resultType=
"net.wanji.opt.synthesis.pojo.TrunkLineCrossProblemEntity"
>
select
select
...
...
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