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
bff3bdd5
Commit
bff3bdd5
authored
Nov 11, 2024
by
duanruiming
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[update] 策略管理代码提交
parent
763365d3
Changes
11
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
145 additions
and
19 deletions
+145
-19
SignalCommandOptController.java
.../controller/signalcontrol/SignalCommandOptController.java
+3
-3
DiagnoServiceImpl.java
...in/java/net/wanji/opt/service/impl/DiagnoServiceImpl.java
+1
-1
FeignProxyService.java
...et/wanji/opt/service/signalcontrol/FeignProxyService.java
+1
-1
FeignProxyServiceImpl.java
...opt/service/signalcontrol/impl/FeignProxyServiceImpl.java
+1
-1
StrategyControlController.java
...i/opt/synthesis/controller/StrategyControlController.java
+12
-0
StrategyControlDataEntity.java
...t/wanji/opt/synthesis/pojo/StrategyControlDataEntity.java
+2
-0
StrategyControlDetailList.java
...t/wanji/opt/synthesis/pojo/StrategyControlDetailList.java
+1
-0
StrategyPlanDTO.java
...in/java/net/wanji/opt/synthesis/pojo/StrategyPlanDTO.java
+2
-1
StrategyPlanInfoEntity.java
.../net/wanji/opt/synthesis/pojo/StrategyPlanInfoEntity.java
+1
-0
StrategyControlService.java
...t/wanji/opt/synthesis/service/StrategyControlService.java
+1
-0
StrategyControlServiceImpl.java
...pt/synthesis/service/impl/StrategyControlServiceImpl.java
+120
-12
No files found.
signal-optimize-service/src/main/java/net/wanji/opt/controller/signalcontrol/SignalCommandOptController.java
View file @
bff3bdd5
...
@@ -7,8 +7,8 @@ import io.swagger.annotations.ApiResponses;
...
@@ -7,8 +7,8 @@ import io.swagger.annotations.ApiResponses;
import
net.wanji.common.annotation.aspect.AspectLog
;
import
net.wanji.common.annotation.aspect.AspectLog
;
import
net.wanji.common.enums.BaseEnum
;
import
net.wanji.common.enums.BaseEnum
;
import
net.wanji.common.framework.rest.JsonViewObject
;
import
net.wanji.common.framework.rest.JsonViewObject
;
import
net.wanji.databus.vo.SchemeOptSendVO
;
import
net.wanji.opt.service.signalcontrol.FeignProxyService
;
import
net.wanji.opt.service.signalcontrol.FeignProxyService
;
import
net.wanji.opt.vo.SchemeOptSendVO
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.PostMapping
;
...
@@ -37,7 +37,7 @@ public class SignalCommandOptController {
...
@@ -37,7 +37,7 @@ public class SignalCommandOptController {
@PostMapping
(
value
=
"/schemeOptSend"
,
@PostMapping
(
value
=
"/schemeOptSend"
,
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
JsonViewObject
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
JsonViewObject
.
class
)})
public
JsonViewObject
schemeOptSend
(
@RequestBody
@Validated
SchemeOptSendVO
schemeOptSendVO
)
throws
Exception
{
public
JsonViewObject
schemeOptSend
(
@RequestBody
@Validated
SchemeOptSendVO
schemeOptSendVO
)
throws
Exception
{
JsonViewObject
jsonViewObject
=
feignProxyService
.
schemeOptSend
(
schemeOptSendVO
);
JsonViewObject
jsonViewObject
=
feignProxyService
.
schemeOptSend
(
schemeOptSendVO
);
return
jsonViewObject
;
return
jsonViewObject
;
}
}
...
@@ -48,7 +48,7 @@ public class SignalCommandOptController {
...
@@ -48,7 +48,7 @@ public class SignalCommandOptController {
@PostMapping
(
value
=
"/schemeOptRestore"
,
@PostMapping
(
value
=
"/schemeOptRestore"
,
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
JsonViewObject
.
class
)})
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
JsonViewObject
.
class
)})
public
JsonViewObject
schemeOptRestore
(
@RequestBody
@NotBlank
String
crossId
)
throws
Exception
{
public
JsonViewObject
schemeOptRestore
(
@RequestBody
@NotBlank
String
crossId
)
throws
Exception
{
JsonViewObject
jsonViewObject
=
feignProxyService
.
schemeOptRestore
(
crossId
);
JsonViewObject
jsonViewObject
=
feignProxyService
.
schemeOptRestore
(
crossId
);
return
jsonViewObject
;
return
jsonViewObject
;
}
}
...
...
signal-optimize-service/src/main/java/net/wanji/opt/service/impl/DiagnoServiceImpl.java
View file @
bff3bdd5
...
@@ -29,7 +29,7 @@ import net.wanji.opt.service.signalcontrol.FeignProxyService;
...
@@ -29,7 +29,7 @@ import net.wanji.opt.service.signalcontrol.FeignProxyService;
import
net.wanji.opt.service.strategy.SceneService
;
import
net.wanji.opt.service.strategy.SceneService
;
import
net.wanji.opt.vo.CrossIdAndLocationVO
;
import
net.wanji.opt.vo.CrossIdAndLocationVO
;
import
net.wanji.opt.vo.OptEffectVO
;
import
net.wanji.opt.vo.OptEffectVO
;
import
net.wanji.
opt
.vo.SchemeOptSendVO
;
import
net.wanji.
databus
.vo.SchemeOptSendVO
;
import
net.wanji.opt.vo.SchemeOptVO
;
import
net.wanji.opt.vo.SchemeOptVO
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
org.springframework.util.CollectionUtils
;
import
org.springframework.util.CollectionUtils
;
...
...
signal-optimize-service/src/main/java/net/wanji/opt/service/signalcontrol/FeignProxyService.java
View file @
bff3bdd5
package
net
.
wanji
.
opt
.
service
.
signalcontrol
;
package
net
.
wanji
.
opt
.
service
.
signalcontrol
;
import
net.wanji.common.framework.rest.JsonViewObject
;
import
net.wanji.common.framework.rest.JsonViewObject
;
import
net.wanji.
opt
.vo.SchemeOptSendVO
;
import
net.wanji.
databus
.vo.SchemeOptSendVO
;
/**
/**
* @author duanruiming
* @author duanruiming
...
...
signal-optimize-service/src/main/java/net/wanji/opt/service/signalcontrol/impl/FeignProxyServiceImpl.java
View file @
bff3bdd5
...
@@ -13,7 +13,7 @@ import net.wanji.opt.dto.CrossPhaseDTO;
...
@@ -13,7 +13,7 @@ import net.wanji.opt.dto.CrossPhaseDTO;
import
net.wanji.opt.po.base.CrossSchemeOptLogPO
;
import
net.wanji.opt.po.base.CrossSchemeOptLogPO
;
import
net.wanji.opt.service.impl.CrossOptimizeServiceImpl
;
import
net.wanji.opt.service.impl.CrossOptimizeServiceImpl
;
import
net.wanji.opt.service.signalcontrol.FeignProxyService
;
import
net.wanji.opt.service.signalcontrol.FeignProxyService
;
import
net.wanji.
opt
.vo.SchemeOptSendVO
;
import
net.wanji.
databus
.vo.SchemeOptSendVO
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
...
...
signal-optimize-service/src/main/java/net/wanji/opt/synthesis/controller/StrategyControlController.java
View file @
bff3bdd5
...
@@ -77,6 +77,18 @@ public class StrategyControlController {
...
@@ -77,6 +77,18 @@ public class StrategyControlController {
return
strategyControlService
.
strategyPlanDetail
(
crossId
);
return
strategyControlService
.
strategyPlanDetail
(
crossId
);
}
}
@ApiOperation
(
value
=
"策略管理计划详情下发"
,
notes
=
"策略管理计划详情下发"
,
response
=
JsonViewObject
.
class
,
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
@PostMapping
(
value
=
"/strategyPush"
,
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
@ApiResponses
({
@ApiResponse
(
code
=
200
,
message
=
"OK"
,
response
=
StrategyControlDetailList
.
class
),
})
public
JsonViewObject
strategyPush
(
@RequestBody
@Validated
StrategyControlDetailList
list
)
throws
Exception
{
return
strategyControlService
.
strategyPush
(
list
);
}
@ApiOperation
(
value
=
"策略管理计划保存"
,
notes
=
"策略管理计划列表查询"
,
@ApiOperation
(
value
=
"策略管理计划保存"
,
notes
=
"策略管理计划列表查询"
,
response
=
JsonViewObject
.
class
,
response
=
JsonViewObject
.
class
,
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
produces
=
MediaType
.
APPLICATION_JSON
,
consumes
=
MediaType
.
APPLICATION_JSON
)
...
...
signal-optimize-service/src/main/java/net/wanji/opt/synthesis/pojo/StrategyControlDataEntity.java
View file @
bff3bdd5
...
@@ -38,4 +38,6 @@ public class StrategyControlDataEntity extends PageVO {
...
@@ -38,4 +38,6 @@ public class StrategyControlDataEntity extends PageVO {
private
Integer
frequency
;
private
Integer
frequency
;
/** value = 状态(1=开启,0=停止) */
/** value = 状态(1=开启,0=停止) */
private
Integer
status
;
private
Integer
status
;
@TableField
(
exist
=
false
)
private
String
crossName
;
}
}
signal-optimize-service/src/main/java/net/wanji/opt/synthesis/pojo/StrategyControlDetailList.java
View file @
bff3bdd5
...
@@ -25,6 +25,7 @@ public class StrategyControlDetailList {
...
@@ -25,6 +25,7 @@ public class StrategyControlDetailList {
private
Integer
type
;
private
Integer
type
;
private
Integer
planId
;
private
Integer
planId
;
private
String
company
;
private
String
company
;
private
Integer
status
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
private
Date
startTime
;
private
Date
startTime
;
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
@JsonFormat
(
shape
=
JsonFormat
.
Shape
.
STRING
,
pattern
=
"yyyy-MM-dd HH:mm:ss"
,
timezone
=
"GMT+8"
)
...
...
signal-optimize-service/src/main/java/net/wanji/opt/synthesis/pojo/StrategyPlanDTO.java
View file @
bff3bdd5
...
@@ -19,5 +19,6 @@ public class StrategyPlanDTO {
...
@@ -19,5 +19,6 @@ public class StrategyPlanDTO {
private
List
<
Integer
>
weeks
;
private
List
<
Integer
>
weeks
;
private
Date
startTime
;
private
Date
startTime
;
private
Date
endTime
;
private
Date
endTime
;
private
Integer
status
;
private
Integer
freq
;
}
}
signal-optimize-service/src/main/java/net/wanji/opt/synthesis/pojo/StrategyPlanInfoEntity.java
View file @
bff3bdd5
...
@@ -37,6 +37,7 @@ public class StrategyPlanInfoEntity {
...
@@ -37,6 +37,7 @@ public class StrategyPlanInfoEntity {
@ApiModelProperty
(
"endTime"
)
@ApiModelProperty
(
"endTime"
)
@TableField
(
"end_time"
)
@TableField
(
"end_time"
)
private
Date
endTime
;
private
Date
endTime
;
private
Integer
status
;
private
String
company
;
private
String
company
;
@ApiModelProperty
(
"planDetails"
)
@ApiModelProperty
(
"planDetails"
)
@TableField
(
"plan_details"
)
@TableField
(
"plan_details"
)
...
...
signal-optimize-service/src/main/java/net/wanji/opt/synthesis/service/StrategyControlService.java
View file @
bff3bdd5
...
@@ -16,5 +16,6 @@ public interface StrategyControlService {
...
@@ -16,5 +16,6 @@ public interface StrategyControlService {
JsonViewObject
crossStrategyInfoList
(
Integer
type
)
throws
Exception
;
JsonViewObject
crossStrategyInfoList
(
Integer
type
)
throws
Exception
;
JsonViewObject
strategyPlanDetail
(
String
crossId
)
throws
Exception
;
JsonViewObject
strategyPlanDetail
(
String
crossId
)
throws
Exception
;
JsonViewObject
strategyPush
(
StrategyControlDetailList
list
)
throws
Exception
;
JsonViewObject
strategyPlanSave
(
StrategyControlDetailList
list
)
throws
Exception
;
JsonViewObject
strategyPlanSave
(
StrategyControlDetailList
list
)
throws
Exception
;
}
}
signal-optimize-service/src/main/java/net/wanji/opt/synthesis/service/impl/StrategyControlServiceImpl.java
View file @
bff3bdd5
This diff is collapsed.
Click to expand it.
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