Commit 775e21e3 authored by duanruiming's avatar duanruiming

[add] 海信灯态下一方案相位优化

parent f758e2be
......@@ -65,9 +65,11 @@ public class HisensePhaseCountDownTask {
String currentTime = String.valueOf(currentDate.getTime());
Date date2HoursAgo = DateUtils.addHours(currentDate, -1);
if (StringUtils.equalsIgnoreCase(schemeStartTime, currentTime) || Long.parseLong(schemeStartTime) < date2HoursAgo.getTime()) {
if (StringUtils.isNotBlank(nextSectionSchemeNo)) {
crossSchemePO = crossSchemeMapper.selectByCrossIdAndSchemeNo(crossId, Integer.valueOf(nextSectionSchemeNo));
executeNextSectionScheme(crossId, lightsStatusVO, crossSchemePO);
lightsStatusVO.setCycleLen(crossSchemePO.getCycle());
}
} else {
executeNextPeriod(crossId, lightsStatusVO, phaseId, crossSchemePO);
}
......@@ -268,7 +270,7 @@ public class HisensePhaseCountDownTask {
if (StringUtils.equalsIgnoreCase(phaseId, crossPhasePOS.get(i).getPhaseNo())) {
if (i == crossPhasePOS.size() - 1) {
nextPhaseTime = crossPhasePOS.get(0).getPhaseTime();
nextPhaseId = "1";
nextPhaseId = crossPhasePOS.get(0).getPhaseNo();
} else {
nextPhaseTime = crossPhasePOS.get(i + 1).getPhaseTime();
nextPhaseId = crossPhasePOS.get(i + 1).getPhaseNo();
......
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