Commit f3732b5c authored by zhoushiguang's avatar zhoushiguang

Merge remote-tracking branch 'origin/master'

parents afc6ff71 fd841aec
...@@ -44,7 +44,7 @@ public interface PushStrategyControlService { ...@@ -44,7 +44,7 @@ public interface PushStrategyControlService {
* @return * @return
* @throws Exception * @throws Exception
*/ */
Result StartegyPriorityPlanPush(StrategyPriorityPlanPush req) throws Exception; Result StartegyPriorityPlanPush(List<StrategyPriorityPlanPush> req) throws Exception;
/** /**
* 策略管理参数配置推送 * 策略管理参数配置推送
...@@ -52,6 +52,6 @@ public interface PushStrategyControlService { ...@@ -52,6 +52,6 @@ public interface PushStrategyControlService {
* @return * @return
* @throws Exception * @throws Exception
*/ */
Result StartegyPriorityParameterPush(StrategyParameterPush req) throws Exception; Result StartegyPriorityParameterPush(List<StrategyParameterPush> req) throws Exception;
} }
...@@ -101,13 +101,13 @@ public class PushStrategyControlServiceImpl implements PushStrategyControlServic ...@@ -101,13 +101,13 @@ public class PushStrategyControlServiceImpl implements PushStrategyControlServic
* 日计划配置推送 * 日计划配置推送
* */ * */
@Override @Override
public Result StartegyPriorityPlanPush(StrategyPriorityPlanPush req) throws Exception { public Result StartegyPriorityPlanPush(List<StrategyPriorityPlanPush> req) throws Exception {
try { try {
ObjectMapper mapper = JacksonUtils.getInstance(); ObjectMapper mapper = JacksonUtils.getInstance();
System.out.println("req~~"+req);
// 序列化请求参数 // 序列化请求参数
String jsonReq = mapper.writeValueAsString(req); String jsonReq = mapper.writeValueAsString(req);
String resultStr = RestTemplateTool.post(switchUrl, jsonReq); System.out.println("req~~"+jsonReq);
String resultStr = RestTemplateTool.postList(switchUrl, jsonReq);
if (StringUtils.isNotBlank(resultStr)) { if (StringUtils.isNotBlank(resultStr)) {
log.info("下发神思策略管理日计划配置推送成功,内容: {}", req); log.info("下发神思策略管理日计划配置推送成功,内容: {}", req);
Result result = mapper.readValue(resultStr, Result.class); Result result = mapper.readValue(resultStr, Result.class);
...@@ -129,13 +129,13 @@ public class PushStrategyControlServiceImpl implements PushStrategyControlServic ...@@ -129,13 +129,13 @@ public class PushStrategyControlServiceImpl implements PushStrategyControlServic
* @throws Exception * @throws Exception
*/ */
@Override @Override
public Result StartegyPriorityParameterPush(StrategyParameterPush req) throws Exception { public Result StartegyPriorityParameterPush(List<StrategyParameterPush> req) throws Exception {
try { try {
ObjectMapper mapper = JacksonUtils.getInstance(); ObjectMapper mapper = JacksonUtils.getInstance();
System.out.println("req~~"+req);
// 序列化请求参数 // 序列化请求参数
String jsonReq = mapper.writeValueAsString(req); String jsonReq = mapper.writeValueAsString(req);
String resultStr = RestTemplateTool.post(switchUrl, jsonReq); System.out.println("req~~"+jsonReq);
String resultStr = RestTemplateTool.postList(switchUrl, jsonReq);
if (StringUtils.isNotBlank(resultStr)) { if (StringUtils.isNotBlank(resultStr)) {
log.info("下发神思策略管理参数配置推送成功,内容: {}", req); log.info("下发神思策略管理参数配置推送成功,内容: {}", req);
Result result = mapper.readValue(resultStr, Result.class); Result result = mapper.readValue(resultStr, Result.class);
......
...@@ -285,11 +285,13 @@ ...@@ -285,11 +285,13 @@
JOIN t_base_rid_info t3 JOIN t_base_rid_info t3
ON sub_t2.cross_id=t3.end_cross_id ON sub_t2.cross_id=t3.end_cross_id
AND sub_t2.dir_type=t3.in_dir AND sub_t2.dir_type=t3.in_dir
AND t1.in_dir=t3.in_dir
WHERE WHERE
1=1 1=1
<if test="greenId!=null and greenId!=''"> <if test="greenId!=null and greenId!=''">
AND t1.green_id=#{greenId} AND t1.green_id=#{greenId}
</if> </if>
and t1.sort!=1
ORDER BY ORDER BY
sub_t2.traffic_index DESC sub_t2.traffic_index DESC
limit 1 limit 1
......
...@@ -52,7 +52,7 @@ ...@@ -52,7 +52,7 @@
and year_week = #{yearWeek} and year_week = #{yearWeek}
</if> </if>
<if test="crossIdList != null"> <if test="crossIdList != null">
and t4.cross_id in and cross_id in
<foreach collection="crossIdList" item="crossId" open="(" close=")" separator=","> <foreach collection="crossIdList" item="crossId" open="(" close=")" separator=",">
#{crossId} #{crossId}
</foreach> </foreach>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment