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
6d06f3ed
Commit
6d06f3ed
authored
Jan 04, 2025
by
zhoushiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
速度保留2位小数
parent
fde4db49
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
5 deletions
+5
-5
MainlineEvaluateServiceImpl.java
...t/wanji/opt/service/impl/MainlineEvaluateServiceImpl.java
+4
-4
GreenwaveHistMapper.xml
...service/src/main/resources/mapper/GreenwaveHistMapper.xml
+1
-1
No files found.
signal-optimize-service/src/main/java/net/wanji/opt/service/impl/MainlineEvaluateServiceImpl.java
View file @
6d06f3ed
...
...
@@ -267,7 +267,7 @@ public class MainlineEvaluateServiceImpl implements MainlineEvaluateService {
.
average
()
.
orElse
(
0.0
);
double
round
=
(
double
)
(
Math
.
round
(
v
));
vo
.
setValue
(
round
);
vo
.
setValue
(
v
);
}
else
if
(
Objects
.
equals
(
metricCode
,
StrategyAndMetricsEnum
.
Metrics
.
GREEN_LIGHT_EFFICIENCY
.
getCode
()))
{
double
v
=
filteredList
.
stream
()
.
mapToDouble
(
CrossDataHistPOExt:
:
getGreenLightEfficiency
)
...
...
@@ -400,7 +400,7 @@ public class MainlineEvaluateServiceImpl implements MainlineEvaluateService {
.
average
()
.
orElse
(
0.0
);
double
round
=
(
double
)
(
Math
.
round
(
v
));
vo
.
setValue
(
round
);
vo
.
setValue
(
v
);
}
else
if
(
Objects
.
equals
(
metricCode
,
StrategyAndMetricsEnum
.
Metrics
.
GREEN_LIGHT_EFFICIENCY
.
getCode
()))
{
double
v
=
filteredList
.
stream
()
.
mapToDouble
(
CrossDirDataHistPO:
:
getGreenLightEfficiency
)
...
...
@@ -515,7 +515,7 @@ public class MainlineEvaluateServiceImpl implements MainlineEvaluateService {
.
average
()
.
orElse
(
0.0
);
double
round
=
(
double
)
(
Math
.
round
(
v
));
vo
.
setValue
(
round
);
vo
.
setValue
(
v
);
}
else
if
(
Objects
.
equals
(
metricCode
,
StrategyAndMetricsEnum
.
Metrics
.
GREEN_LIGHT_EFFICIENCY
.
getCode
()))
{
double
v
=
filteredList
.
stream
()
.
mapToDouble
(
CrossTurnDataHistPO:
:
getGreenLightEfficiency
)
...
...
@@ -635,7 +635,7 @@ public class MainlineEvaluateServiceImpl implements MainlineEvaluateService {
.
average
()
.
orElse
(
0.0
);
double
round
=
(
double
)
(
Math
.
round
(
v
));
vo
.
setValue
(
round
);
vo
.
setValue
(
v
);
}
else
if
(
Objects
.
equals
(
metricCode
,
StrategyAndMetricsEnum
.
Metrics
.
GREEN_LIGHT_EFFICIENCY
.
getCode
()))
{
double
v
=
filteredList
.
stream
()
.
mapToDouble
(
CrossLaneDataHistPOExt:
:
getGreenLightEfficiency
)
...
...
signal-optimize-service/src/main/resources/mapper/GreenwaveHistMapper.xml
View file @
6d06f3ed
...
...
@@ -333,7 +333,7 @@
<select
id=
"findGreenWaveRunState"
resultType=
"net.wanji.opt.vo.GreenWaveRunStateVO"
>
select type as state,count(*) count,
SUM(TIMESTAMPDIFF(SECOND,start_time, end_time)) duration,
TIMESTAMPDIFF(SECOND,#{startDate}, #{endDate}) total
T
ime
TIMESTAMPDIFF(SECOND,#{startDate}, #{endDate}) total
_t
ime
from t_event_info t
where start_time > #{startDate} and start_time
<
#{endDate}
<if
test=
"eventTypeList!=null and eventTypeList.size>0"
>
...
...
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