|
@@ -77,7 +77,7 @@ public class WODispatchPlanTmDoBizFun {
|
|
|
}
|
|
|
|
|
|
private static ResponseCode handleProduceCmd(String planId, long checkTm){
|
|
|
- if(planId.equals("PLP29FC2A943900184748")){
|
|
|
+ if(planId.equals("PLP2A012D8D2E815028Y8")){
|
|
|
System.out.println(111);
|
|
|
}
|
|
|
ResponseCode code = ResponseCode.RESULT_BAD;
|
|
@@ -581,11 +581,14 @@ public class WODispatchPlanTmDoBizFun {
|
|
|
}
|
|
|
|
|
|
//TODO 如果当前时间大于生效时间,说明生效时间过期,则加一天
|
|
|
+ LocalDateTime localNext = LocalDateTime.ofInstant(Instant.ofEpochMilli(nextTakeTime), ZoneId.systemDefault());
|
|
|
if(limitNextTakeTime<TimeTool.getCurMsUTC()){
|
|
|
nextTakeTime = Instant.ofEpochMilli(nextTakeTime)
|
|
|
.plus(1, ChronoUnit.DAYS).toEpochMilli();
|
|
|
limitNextTakeTime = Instant.ofEpochMilli(limitNextTakeTime).toEpochMilli();
|
|
|
- }else if(oldTm!=null&&nextTakeTime<=oldTm.atZone(ZoneId.systemDefault()).toEpochSecond()){
|
|
|
+ }else if(oldTm!=null&&(localNext
|
|
|
+ .isBefore(oldTm)||localNext.isEqual(oldTm))
|
|
|
+ ){
|
|
|
//TODO 连续时需考虑
|
|
|
//TODO 如果传递了对比值, 则说明当前计算的时间与old不符合条件,则再加一算一次
|
|
|
nextTakeTime = Instant.ofEpochMilli(nextTakeTime)
|