|
@@ -402,19 +402,21 @@ public class SysEarlyWarningServiceImpl extends ServiceImpl<SysEarlyWarningMappe
|
402
|
402
|
private static Date getStartAtDate4ToBeDone(String periodType) {
|
403
|
403
|
Date startAt = null;
|
404
|
404
|
if(periodType.equals(GrainConstant.STR_MINUTE)) {
|
405
|
|
- startAt = DateUtil.getCurrMinute();
|
|
405
|
+ startAt = DateUtil.getNextMinute();
|
406
|
406
|
} else if(periodType.equals(GrainConstant.STR_HOUR)) {
|
407
|
|
- startAt = DateUtil.getCurrHour();
|
408
|
|
- } else if(periodType.equals(GrainConstant.STR_DAY) || periodType.equals(GrainConstant.STR_WEEKDAY)) {
|
409
|
|
- startAt = DateUtil.getCurrDate();
|
|
407
|
+ startAt = DateUtil.getNextHour();
|
|
408
|
+ } else if(periodType.equals(GrainConstant.STR_DAY)) {
|
|
409
|
+ startAt = DateUtil.getNextDate();
|
|
410
|
+ } else if(periodType.equals(GrainConstant.STR_WEEKDAY)) {
|
|
411
|
+ startAt = DateUtil.getNextWeekday();
|
410
|
412
|
} else if(periodType.equals(GrainConstant.STR_WEEK)) {
|
411
|
|
- startAt = DateUtil.getFirstDateOfCurrWeek();
|
|
413
|
+ startAt = DateUtil.getFirstDateOfNextWeek();
|
412
|
414
|
} else if(periodType.equals(GrainConstant.STR_MONTH)) {
|
413
|
|
- startAt = DateUtil.getFirstDateOfCurrMonth();
|
|
415
|
+ startAt = DateUtil.getFirstDateOfNextMonth();
|
414
|
416
|
} else if(periodType.equals(GrainConstant.STR_SEASON)) {
|
415
|
|
- startAt = DateUtil.getFirstDateOfCurrSeason();
|
|
417
|
+ startAt = DateUtil.getFirstDateOfNextSeason();
|
416
|
418
|
} else if(periodType.equals(GrainConstant.STR_YEAR)) {
|
417
|
|
- startAt = DateUtil.getFirstDateOfCurrYear();
|
|
419
|
+ startAt = DateUtil.getFirstDateOfNextYear();
|
418
|
420
|
}
|
419
|
421
|
|
420
|
422
|
return startAt;
|