Commit 0b901a5a47d2ccd61edf27b28c9500b398238cc5
1 parent
21dfa3a7
update
Showing
1 changed file
with
8 additions
and
2 deletions
src/main/java/com/bsth/service/impl/BusIntervalServiceImpl.java
| ... | ... | @@ -958,6 +958,8 @@ public class BusIntervalServiceImpl implements BusIntervalService { |
| 958 | 958 | if(tsSet.contains(schedule2.getId()) || schedule2.getBcType().toString().equals("in") || schedule2.getBcType().toString().equals("out")){ |
| 959 | 959 | fcsj2 = schedule1.getZdsjT(); |
| 960 | 960 | } |
| 961 | + if(fcsj2 < fcsj1) | |
| 962 | + fcsj2 += 1440l; | |
| 961 | 963 | if(sfqr == 1 && time1 > fcsj1){ |
| 962 | 964 | jhyysj += fcsj2 - time1; |
| 963 | 965 | }else if(sfqr == 1 && time2 < fcsj2){ |
| ... | ... | @@ -966,7 +968,7 @@ public class BusIntervalServiceImpl implements BusIntervalService { |
| 966 | 968 | jhyysj += fcsj2 - fcsj1; |
| 967 | 969 | } |
| 968 | 970 | if(jhyysj < 0){ |
| 969 | - System.out.println(fcsj2 + " - " + fcsj1); | |
| 971 | + System.out.println(fcsj2 + " - " + fcsj1 + " = " + (fcsj2 - fcsj1)); | |
| 970 | 972 | } |
| 971 | 973 | jhyysj1 += fcsj2 - fcsj1; |
| 972 | 974 | } |
| ... | ... | @@ -1010,7 +1012,8 @@ public class BusIntervalServiceImpl implements BusIntervalService { |
| 1010 | 1012 | List<ChildTaskPlan> cTasks = cMap.get(schedule.getId()); |
| 1011 | 1013 | for(ChildTaskPlan childTaskPlan : cTasks){ |
| 1012 | 1014 | Map<String, Object> temp = new HashMap<String, Object>(); |
| 1013 | - if(childTaskPlan.getMileageType().equals("empty") || childTaskPlan.isDestroy()){ | |
| 1015 | + if(!childTaskPlan.getMileageType().equals("service") || childTaskPlan.isDestroy() | |
| 1016 | + || !childTaskPlan.getType1().equals("正常") || childTaskPlan.getCcId() != null){ | |
| 1014 | 1017 | temp.put("lc", null); |
| 1015 | 1018 | temp.put("fcsj", null); |
| 1016 | 1019 | temp.put("zdsj", null); |
| ... | ... | @@ -1071,6 +1074,9 @@ public class BusIntervalServiceImpl implements BusIntervalService { |
| 1071 | 1074 | } else if(i == keyList.size() - 1){ |
| 1072 | 1075 | fcsj2 = Long.valueOf(m2.get("zdsj").toString()); |
| 1073 | 1076 | } |
| 1077 | + if(fcsj2 < fcsj1){ | |
| 1078 | + fcsj2 += 1440l; | |
| 1079 | + } | |
| 1074 | 1080 | if(sfqr == 1 && time1 > fcsj1){ |
| 1075 | 1081 | sjyysj += fcsj2 - time1; |
| 1076 | 1082 | }else if(sfqr == 1 && time2 < fcsj2){ | ... | ... |