Commit a82d13817792ff368356a019ff40703b2c65df80
Merge branch 'minhang' of http://222.66.0.204:8090//panzhaov5/bsth_control into minhang
Showing
51 changed files
with
6597 additions
and
5224 deletions
src/main/java/com/bsth/controller/realcontrol/ScheduleRealInfoController.java
| ... | ... | @@ -36,35 +36,13 @@ public class ScheduleRealInfoController extends BaseController<ScheduleRealInfo, |
| 36 | 36 | |
| 37 | 37 | /** |
| 38 | 38 | * |
| 39 | - * 改由通过 websocket 注册监听!!! | |
| 40 | - * | |
| 41 | - * @Title: registerLine @Description: TODO(注册线路,后续才能收到数据推送) @param @param | |
| 42 | - * lineCodes @throws | |
| 43 | - * 用GET 防止监控模式下被拦截 | |
| 44 | - | |
| 45 | - @RequestMapping(value = "/registerLine", method = RequestMethod.GET) | |
| 46 | - public int registerLine(@RequestParam String lineCodes) { | |
| 47 | - List<String> list = Splitter.on(",").trimResults().omitEmptyStrings().splitToList(lineCodes); | |
| 48 | - String userName = SecurityUtils.getCurrentUser().getUserName(); | |
| 49 | - // 注销之前的绑定 | |
| 50 | - for (String line : list) | |
| 51 | - BasicData.lineCode2SocketUserMap.get(line).remove(userName); | |
| 52 | - // 重新绑定 | |
| 53 | - for (String line : list) | |
| 54 | - BasicData.lineCode2SocketUserMap.put(line, userName); | |
| 55 | - | |
| 56 | - return 0; | |
| 57 | - }*/ | |
| 58 | - | |
| 59 | - /** | |
| 60 | - * | |
| 61 | 39 | * @Title: outgoAdjust @Description: TODO(待发调整) @param @param id |
| 62 | 40 | * 主键 @param @param remarks 备注 @param @param dfsj 待发时间(HH:mm) @throws |
| 63 | 41 | */ |
| 64 | 42 | @RequestMapping(value = "/outgoAdjust", method = RequestMethod.POST) |
| 65 | 43 | public Map<String, Object> outgoAdjust(@RequestParam Long id, @RequestParam String remarks, |
| 66 | - @RequestParam String dfsj/*, String clZbh, String jsy, String spy*/) { | |
| 67 | - return scheduleRealInfoService.outgoAdjust(id, remarks, dfsj/*, clZbh, jsy, spy*/); | |
| 44 | + @RequestParam String dfsj,@RequestParam String bcType) { | |
| 45 | + return scheduleRealInfoService.outgoAdjust(id, remarks, dfsj, bcType); | |
| 68 | 46 | } |
| 69 | 47 | |
| 70 | 48 | /** |
| ... | ... | @@ -125,19 +103,6 @@ public class ScheduleRealInfoController extends BaseController<ScheduleRealInfo, |
| 125 | 103 | public List<Map<String, String>> sreachVehic(@RequestParam String nbbm) { |
| 126 | 104 | return scheduleRealInfoService.sreachVehic(nbbm); |
| 127 | 105 | } |
| 128 | - | |
| 129 | - /** | |
| 130 | - * | |
| 131 | - * @Title: adjust @Description: TODO(调整人车) @param @param id | |
| 132 | - * 班次ID @param @param nbbm 内部编码 @param @param jsy 驾驶员 @param @param spy | |
| 133 | - * 售票员 @throws | |
| 134 | - | |
| 135 | - @RequestMapping(value = "/adjust", method = RequestMethod.POST) | |
| 136 | - public Map<String, Object> adjust(@RequestParam Long id, String nbbm, String jsy, | |
| 137 | - String spy, Integer revertLine, Integer borrowLine, String borrowTimeStr, String revertTimeStr) { | |
| 138 | - return scheduleRealInfoService.adjust(id, nbbm, jsy, spy, revertLine, borrowLine, borrowTimeStr, revertTimeStr); | |
| 139 | - } | |
| 140 | - */ | |
| 141 | 106 | /** |
| 142 | 107 | * |
| 143 | 108 | * @Title: realOutAdjust |
| ... | ... | @@ -299,10 +264,17 @@ public class ScheduleRealInfoController extends BaseController<ScheduleRealInfo, |
| 299 | 264 | |
| 300 | 265 | @RequestMapping(value = "/exportWaybill") |
| 301 | 266 | public List<ScheduleRealInfo> exportWaybill(@RequestParam String jName, @RequestParam String clZbh, |
| 302 | - @RequestParam String lpName,@RequestParam String date) { | |
| 303 | - return scheduleRealInfoService.exportWaybill(jName, clZbh, lpName,date); | |
| 267 | + @RequestParam String lpName,@RequestParam String date,@RequestParam String line) { | |
| 268 | + return scheduleRealInfoService.exportWaybill(jName, clZbh, lpName,date,line); | |
| 269 | + } | |
| 270 | + | |
| 271 | + @RequestMapping(value = "/exportWaybillQp") | |
| 272 | + public List<ScheduleRealInfo> exportWaybillQp(@RequestParam String clZbh | |
| 273 | + ,@RequestParam String date,@RequestParam String line) { | |
| 274 | + return scheduleRealInfoService.exportWaybillQp( clZbh, date,line); | |
| 304 | 275 | } |
| 305 | 276 | |
| 277 | + | |
| 306 | 278 | @RequestMapping(value = "/dailyInfo") |
| 307 | 279 | public List<Map<String, Object>> dailyInfo(@RequestParam String line, @RequestParam String date,@RequestParam String type) { |
| 308 | 280 | return scheduleRealInfoService.dailyInfo(line, date, type); |
| ... | ... | @@ -321,8 +293,14 @@ public class ScheduleRealInfoController extends BaseController<ScheduleRealInfo, |
| 321 | 293 | |
| 322 | 294 | @RequestMapping(value="/findKMBC") |
| 323 | 295 | public Map<String,Object> findKMBC(@RequestParam String jName,@RequestParam String clZbh,@RequestParam String lpName |
| 324 | - ,@RequestParam String date){ | |
| 325 | - return scheduleRealInfoService.findKMBC(jName, clZbh,lpName,date); | |
| 296 | + ,@RequestParam String date,@RequestParam String line){ | |
| 297 | + return scheduleRealInfoService.findKMBC(jName, clZbh,lpName,date,line); | |
| 298 | + } | |
| 299 | + | |
| 300 | + @RequestMapping(value="/findKMBCQp") | |
| 301 | + public Map<String,Object> findKMBCQp(@RequestParam String clZbh | |
| 302 | + ,@RequestParam String date,@RequestParam String line){ | |
| 303 | + return scheduleRealInfoService.findKMBCQp(clZbh,date,line); | |
| 326 | 304 | } |
| 327 | 305 | |
| 328 | 306 | @RequestMapping(value="/findLpName") |
| ... | ... | @@ -351,16 +329,14 @@ public class ScheduleRealInfoController extends BaseController<ScheduleRealInfo, |
| 351 | 329 | */ |
| 352 | 330 | @RequestMapping(value="/queryListWaybill") |
| 353 | 331 | public List<ScheduleRealInfo> queryListWaybill(@RequestParam String jName,@RequestParam String clZbh,@RequestParam String lpName |
| 354 | - ,@RequestParam String date){ | |
| 355 | - String type="fqp"; | |
| 356 | - return scheduleRealInfoService.queryListWaybill(jName, clZbh,lpName,date,type); | |
| 332 | + ,@RequestParam String date,@RequestParam String line){ | |
| 333 | + return scheduleRealInfoService.queryListWaybill(jName, clZbh,lpName,date,line); | |
| 357 | 334 | } |
| 358 | 335 | |
| 359 | 336 | @RequestMapping(value="/queryListWaybillQp") |
| 360 | - public List<ScheduleRealInfo> queryListWaybillQp(@RequestParam String jName,@RequestParam String clZbh,@RequestParam String lpName | |
| 361 | - ,@RequestParam String date){ | |
| 362 | - String type="qp"; | |
| 363 | - return scheduleRealInfoService.queryListWaybill(jName, clZbh,lpName,date,type); | |
| 337 | + public List<ScheduleRealInfo> queryListWaybillQp(@RequestParam String clZbh, | |
| 338 | + @RequestParam String date,@RequestParam String line){ | |
| 339 | + return scheduleRealInfoService.queryListWaybillQp(clZbh,date,line); | |
| 364 | 340 | } |
| 365 | 341 | |
| 366 | 342 | @RequestMapping(value="/statisticsDaily") |
| ... | ... | @@ -368,6 +344,11 @@ public class ScheduleRealInfoController extends BaseController<ScheduleRealInfo, |
| 368 | 344 | return scheduleRealInfoService.statisticsDaily(line, date,xlName); |
| 369 | 345 | } |
| 370 | 346 | |
| 347 | + @RequestMapping(value="/MapById",method = RequestMethod.GET) | |
| 348 | + public Map<String, Object> MapById(@RequestParam("id") Long id){ | |
| 349 | + return scheduleRealInfoService.MapById(id); | |
| 350 | + } | |
| 351 | + | |
| 371 | 352 | /** |
| 372 | 353 | * @Title: scheduleDaily |
| 373 | 354 | * @Description: TODO(调度日报表) |
| ... | ... | @@ -427,4 +408,14 @@ public class ScheduleRealInfoController extends BaseController<ScheduleRealInfo, |
| 427 | 408 | } |
| 428 | 409 | return rs; |
| 429 | 410 | } |
| 411 | + | |
| 412 | + @RequestMapping(value = "svgAttr", method = RequestMethod.POST) | |
| 413 | + public Map<String, Object> svgAttr(@RequestParam String jsonStr){ | |
| 414 | + return scheduleRealInfoService.svgAttr(jsonStr); | |
| 415 | + } | |
| 416 | + | |
| 417 | + @RequestMapping(value = "svgAttr", method = RequestMethod.GET) | |
| 418 | + public Map<String, Object> findSvgAttr(@RequestParam String idx){ | |
| 419 | + return scheduleRealInfoService.findSvgAttr(idx); | |
| 420 | + } | |
| 430 | 421 | } | ... | ... |
src/main/java/com/bsth/data/gpsdata/arrival/handlers/InOutStationSignalHandle.java
| ... | ... | @@ -169,6 +169,10 @@ public class InOutStationSignalHandle extends SignalHandle{ |
| 169 | 169 | |
| 170 | 170 | if(gps.getStopNo().equals(sch.getZdzCode())){ |
| 171 | 171 | |
| 172 | + //进场最多提前1.2小时 | |
| 173 | + if(sch.getBcType().equals("in") && sch.getZdsjT() - gps.getTimestamp() > MAX_BEFORE_TIME) | |
| 174 | + return; | |
| 175 | + | |
| 172 | 176 | //实达时间不覆盖 |
| 173 | 177 | if(StringUtils.isNotEmpty(sch.getZdsjActual())) |
| 174 | 178 | return; | ... | ... |
src/main/java/com/bsth/entity/realcontrol/SvgAttribute.java
0 → 100644
| 1 | +package com.bsth.entity.realcontrol; | |
| 2 | + | |
| 3 | +import javax.persistence.Entity; | |
| 4 | +import javax.persistence.Id; | |
| 5 | +import javax.persistence.Table; | |
| 6 | + | |
| 7 | +/** | |
| 8 | + * 主页SVG模拟图属性设置 | |
| 9 | + * Created by panzhao on 2017/1/6. | |
| 10 | + */ | |
| 11 | +@Entity | |
| 12 | +@Table(name = "bsth_c_svg_attr") | |
| 13 | +public class SvgAttribute { | |
| 14 | + | |
| 15 | + @Id | |
| 16 | + private String lineCode; | |
| 17 | + | |
| 18 | + /** | |
| 19 | + * 要隐藏的站点编码 , 号分割多个 | |
| 20 | + */ | |
| 21 | + private String hideStations; | |
| 22 | + | |
| 23 | + /** | |
| 24 | + * 站点别名 json对象字符串 | |
| 25 | + */ | |
| 26 | + private String nicknames; | |
| 27 | + | |
| 28 | + public String getLineCode() { | |
| 29 | + return lineCode; | |
| 30 | + } | |
| 31 | + | |
| 32 | + public void setLineCode(String lineCode) { | |
| 33 | + this.lineCode = lineCode; | |
| 34 | + } | |
| 35 | + | |
| 36 | + public String getHideStations() { | |
| 37 | + return hideStations; | |
| 38 | + } | |
| 39 | + | |
| 40 | + public void setHideStations(String hideStations) { | |
| 41 | + this.hideStations = hideStations; | |
| 42 | + } | |
| 43 | + | |
| 44 | + public String getNicknames() { | |
| 45 | + return nicknames; | |
| 46 | + } | |
| 47 | + | |
| 48 | + public void setNicknames(String nicknames) { | |
| 49 | + this.nicknames = nicknames; | |
| 50 | + } | |
| 51 | +} | ... | ... |
src/main/java/com/bsth/repository/realcontrol/ScheduleRealInfoRepository.java
| ... | ... | @@ -24,7 +24,7 @@ public interface ScheduleRealInfoRepository extends BaseRepository<ScheduleRealI |
| 24 | 24 | @Query(value="select min(s.id), s.jGh,s.clZbh,s.lpName,s.jName from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.jGh,s.clZbh,s.lpName ,s.jName order by (lpName+1)") |
| 25 | 25 | List<ScheduleRealInfo> queryUserInfo2(String line,String date); |
| 26 | 26 | |
| 27 | - @Query(value="select min(s.id), s.jGh,s.clZbh,s.lpName,s.jName from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.jGh,s.clZbh,s.lpName ,s.jName order by (lpName+1)") | |
| 27 | + @Query(value="select min(s.id), s.clZbh from ScheduleRealInfo s where s.xlBm = ?1 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') = ?2 GROUP BY s.clZbh order by (lpName+1)") | |
| 28 | 28 | List<ScheduleRealInfo> queryUserInfo3(String line,String date); |
| 29 | 29 | |
| 30 | 30 | @Query(value="select s from ScheduleRealInfo s where s.jName = ?1 and s.clZbh = ?2 and s.lpName = ?3 order by bcs") |
| ... | ... | @@ -79,13 +79,13 @@ public interface ScheduleRealInfoRepository extends BaseRepository<ScheduleRealI |
| 79 | 79 | + " and clZbh like %?5% order by s.fcsj") |
| 80 | 80 | List<ScheduleRealInfo> correctForm(String line,String startDate,String endDate,String lpName,String code); |
| 81 | 81 | |
| 82 | - @Query(value="select s from ScheduleRealInfo s where s.jName = ?1 and s.clZbh = ?2 and s.lpName = ?3 and s.scheduleDate = str_to_date(?4,'%Y-%m-%d') order by bcs") | |
| 83 | - List<ScheduleRealInfo> queryListWaybill(String jName,String clZbh,String lpName,String date); | |
| 82 | + @Query(value="select s from ScheduleRealInfo s where s.jName = ?1 and s.clZbh = ?2 and s.lpName = ?3 and s.scheduleDate = str_to_date(?4,'%Y-%m-%d') and s.xlBm=?5 order by realExecDate,fcsjActual") | |
| 83 | + List<ScheduleRealInfo> queryListWaybill(String jName,String clZbh,String lpName,String date,String line); | |
| 84 | 84 | |
| 85 | - @Query(value="select s from ScheduleRealInfo s where s.jName = ?1 and s.clZbh = ?2 and s.lpName = ?3 and s.scheduleDate = str_to_date(?4,'%Y-%m-%d') and bcType='normal' order by bcs") | |
| 86 | - List<ScheduleRealInfo> queryListWaybill2(String jName,String clZbh,String lpName,String date); | |
| 85 | + @Query(value="select s from ScheduleRealInfo s where s.clZbh = ?1 and s.scheduleDate = str_to_date(?2,'%Y-%m-%d') and xlBm =?3 order by realExecDate,fcsjActual") | |
| 86 | + List<ScheduleRealInfo> queryListWaybill2(String clZbh,String date,String line); | |
| 87 | 87 | |
| 88 | - @Query(value="select s from ScheduleRealInfo s where s.jGh = ?1 and s.clZbh = ?2 and s.scheduleDate = str_to_date(?3,'%Y-%m-%d') order by bcs") | |
| 88 | + @Query(value="select s from ScheduleRealInfo s where s.jGh = ?1 and s.clZbh = ?2 and s.scheduleDate = str_to_date(?3,'%Y-%m-%d') order by realExecDate,fcsjActual") | |
| 89 | 89 | List<ScheduleRealInfo> queryListWaybill3(String jName,String clZbh,String date); |
| 90 | 90 | |
| 91 | 91 | @Query(value="select s from ScheduleRealInfo s where s.jName = ?1 and s.clZbh = ?2 and DATE_FORMAT(s.scheduleDate,'%Y-%m-%d') between str_to_date(?3,'%Y-%m-%d') and str_to_date(?4,'%Y-%m-%d') order by bcs") | ... | ... |
src/main/java/com/bsth/repository/realcontrol/SvgAttributeRepository.java
0 → 100644
| 1 | +package com.bsth.repository.realcontrol; | |
| 2 | + | |
| 3 | +import com.bsth.entity.realcontrol.SvgAttribute; | |
| 4 | +import com.bsth.repository.BaseRepository; | |
| 5 | +import org.springframework.data.jpa.repository.Query; | |
| 6 | +import org.springframework.stereotype.Repository; | |
| 7 | + | |
| 8 | +import java.util.List; | |
| 9 | + | |
| 10 | +/** | |
| 11 | + * Created by panzhao on 2017/1/8. | |
| 12 | + */ | |
| 13 | +@Repository | |
| 14 | +public interface SvgAttributeRepository extends BaseRepository<SvgAttribute, String> { | |
| 15 | + @Query("select s from SvgAttribute s where s.lineCode in ?1") | |
| 16 | + List<SvgAttribute> findSvgAttr(List<String> lineCodes); | |
| 17 | +} | ... | ... |
src/main/java/com/bsth/service/impl/BusIntervalServiceImpl.java
| ... | ... | @@ -11,6 +11,7 @@ import java.util.Collections; |
| 11 | 11 | import java.util.Comparator; |
| 12 | 12 | import java.util.Date; |
| 13 | 13 | import java.util.HashMap; |
| 14 | +import java.util.Iterator; | |
| 14 | 15 | import java.util.List; |
| 15 | 16 | import java.util.Map; |
| 16 | 17 | import java.util.Set; |
| ... | ... | @@ -25,6 +26,7 @@ import com.bsth.entity.realcontrol.ScheduleRealInfo; |
| 25 | 26 | import com.bsth.repository.realcontrol.ScheduleRealInfoRepository; |
| 26 | 27 | import com.bsth.service.BusIntervalService; |
| 27 | 28 | import com.bsth.service.schedule.PeopleCarPlanService; |
| 29 | +import com.bsth.util.ReportUtils; | |
| 28 | 30 | |
| 29 | 31 | |
| 30 | 32 | @Service |
| ... | ... | @@ -514,6 +516,24 @@ public class BusIntervalServiceImpl implements BusIntervalService { |
| 514 | 516 | } |
| 515 | 517 | } |
| 516 | 518 | } |
| 519 | + | |
| 520 | + if(type != null && type.length() != 0 && type.equals("export")){ | |
| 521 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 522 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 523 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 524 | + Map<String, Object> m = new HashMap<String, Object>(); | |
| 525 | + ReportUtils ee = new ReportUtils(); | |
| 526 | + try { | |
| 527 | + listI.add(resList.iterator()); | |
| 528 | + String path = this.getClass().getResource("/").getPath()+"static\\pages\\forms\\"; | |
| 529 | + ee.excelReplace(listI, new Object[] { m }, path+"mould\\interval.xls", | |
| 530 | + path+"export\\班次间隔统计表" + sdfSimple.format(sdfMonth.parse(startDate)) | |
| 531 | + + "-" + sdfSimple.format(sdfMonth.parse(endDate)) + ".xls"); | |
| 532 | + } catch (Exception e) { | |
| 533 | + // TODO: handle exception | |
| 534 | + e.printStackTrace(); | |
| 535 | + } | |
| 536 | + } | |
| 517 | 537 | |
| 518 | 538 | return resList; |
| 519 | 539 | } |
| ... | ... | @@ -672,8 +692,8 @@ public class BusIntervalServiceImpl implements BusIntervalService { |
| 672 | 692 | String[] date1 = startDate.split("-"); |
| 673 | 693 | String[] date2 = endDate.split("-"); |
| 674 | 694 | String date = ""; |
| 675 | - startDate = date1[0] + "年" + date1[1] + "月" + date1[2] + "日"; | |
| 676 | - endDate = date2[0] + "年" + date2[1] + "月" + date2[2] + "日"; | |
| 695 | +// startDate = date1[0] + "年" + date1[1] + "月" + date1[2] + "日"; | |
| 696 | +// endDate = date2[0] + "年" + date2[1] + "月" + date2[2] + "日"; | |
| 677 | 697 | if(startDate.equals(endDate)){ |
| 678 | 698 | date = date1[0] + "年" + date1[1] + "月" + date1[2] + "日"; |
| 679 | 699 | } else { |
| ... | ... | @@ -1044,6 +1064,27 @@ public class BusIntervalServiceImpl implements BusIntervalService { |
| 1044 | 1064 | modelMap.put("dataList", dataList); |
| 1045 | 1065 | } |
| 1046 | 1066 | |
| 1067 | + if(type != null && type.length() != 0 && type.equals("export")){ | |
| 1068 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 1069 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 1070 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 1071 | + ReportUtils ee = new ReportUtils(); | |
| 1072 | + if(statu.equals("0")) | |
| 1073 | + modelMap.put("lpType", "路牌数量"); | |
| 1074 | + else if(statu.equals("1")) | |
| 1075 | + modelMap.put("lpType", "路牌名"); | |
| 1076 | + try { | |
| 1077 | + listI.add(((List<Map<String, Object>>)modelMap.get("dataList")).iterator()); | |
| 1078 | + String path = this.getClass().getResource("/").getPath()+"static\\pages\\forms\\"; | |
| 1079 | + ee.excelReplace(listI, new Object[] { modelMap }, path+"mould\\timeAndSpeed.xls", | |
| 1080 | + path+"export\\行驶时间及车速统计表" + sdfSimple.format(sdfMonth.parse(startDate)) | |
| 1081 | + + "-" + sdfSimple.format(sdfMonth.parse(endDate)) + ".xls"); | |
| 1082 | + } catch (Exception e) { | |
| 1083 | + // TODO: handle exception | |
| 1084 | + e.printStackTrace(); | |
| 1085 | + } | |
| 1086 | + } | |
| 1087 | + | |
| 1047 | 1088 | return modelMap; |
| 1048 | 1089 | } |
| 1049 | 1090 | ... | ... |
src/main/java/com/bsth/service/impl/StationRouteServiceImpl.java
| 1 | 1 | package com.bsth.service.impl; |
| 2 | 2 | |
| 3 | -import java.io.ByteArrayInputStream; | |
| 4 | -import java.io.File; | |
| 5 | -import java.io.InputStream; | |
| 6 | -import java.text.DecimalFormat; | |
| 7 | -import java.util.ArrayList; | |
| 8 | -import java.util.HashMap; | |
| 9 | -import java.util.List; | |
| 10 | -import java.util.Map; | |
| 11 | -import java.util.Properties; | |
| 12 | - | |
| 13 | -import org.springframework.beans.factory.annotation.Autowired; | |
| 14 | -import org.springframework.data.jpa.repository.EntityGraph; | |
| 15 | -import org.springframework.stereotype.Service; | |
| 16 | - | |
| 17 | -import com.alibaba.fastjson.JSON; | |
| 18 | -import com.alibaba.fastjson.JSONArray; | |
| 19 | -import com.alibaba.fastjson.serializer.PropertyFilter; | |
| 20 | 3 | import com.bsth.common.ResponseCode; |
| 21 | 4 | import com.bsth.entity.Line; |
| 22 | 5 | import com.bsth.entity.Station; |
| ... | ... | @@ -30,7 +13,14 @@ import com.bsth.util.FTPClientUtils; |
| 30 | 13 | import com.bsth.util.PackTarGZUtils; |
| 31 | 14 | import com.bsth.util.db.DBUtils_MS; |
| 32 | 15 | import com.google.common.base.Splitter; |
| 33 | -import com.google.common.collect.Lists; | |
| 16 | +import org.springframework.beans.factory.annotation.Autowired; | |
| 17 | +import org.springframework.stereotype.Service; | |
| 18 | + | |
| 19 | +import java.io.ByteArrayInputStream; | |
| 20 | +import java.io.File; | |
| 21 | +import java.io.InputStream; | |
| 22 | +import java.text.DecimalFormat; | |
| 23 | +import java.util.*; | |
| 34 | 24 | |
| 35 | 25 | /** |
| 36 | 26 | * |
| ... | ... | @@ -985,6 +975,8 @@ public class StationRouteServiceImpl extends BaseServiceImpl<StationRoute, Integ |
| 985 | 975 | List<String> idx = Splitter.on(',').splitToList(lineIds); |
| 986 | 976 | //路由 |
| 987 | 977 | List<StationRoute> list = new ArrayList<>(); |
| 978 | + | |
| 979 | + | |
| 988 | 980 | /** |
| 989 | 981 | * in 查询符 无法和 @EntityGraph 同时配合使用,这可能是一个bug |
| 990 | 982 | * 暂时只能循环单线路查询 |
| ... | ... | @@ -993,9 +985,12 @@ public class StationRouteServiceImpl extends BaseServiceImpl<StationRoute, Integ |
| 993 | 985 | for(String id : idx){ |
| 994 | 986 | list.addAll(repository.findByLineCode(id)); |
| 995 | 987 | } |
| 996 | - | |
| 988 | + | |
| 989 | + for(StationRoute sr : list){ | |
| 990 | + sr.setLine(null); | |
| 991 | + } | |
| 997 | 992 | //过滤部分字段 |
| 998 | - String jsonStr = JSON.toJSONString(list, new PropertyFilter() { | |
| 993 | + /*String jsonStr = JSON.toJSONString(list, new PropertyFilter() { | |
| 999 | 994 | |
| 1000 | 995 | @Override |
| 1001 | 996 | public boolean apply(Object object, String name, Object value) { |
| ... | ... | @@ -1003,10 +998,10 @@ public class StationRouteServiceImpl extends BaseServiceImpl<StationRoute, Integ |
| 1003 | 998 | return false; |
| 1004 | 999 | return true; |
| 1005 | 1000 | } |
| 1006 | - }); | |
| 1001 | + });*/ | |
| 1007 | 1002 | |
| 1008 | 1003 | rs.put("status", ResponseCode.SUCCESS); |
| 1009 | - rs.put("list", jsonStr); | |
| 1004 | + rs.put("list", list); | |
| 1010 | 1005 | }catch(Exception e){ |
| 1011 | 1006 | logger.error("", e); |
| 1012 | 1007 | rs.put("status", ResponseCode.ERROR); | ... | ... |
src/main/java/com/bsth/service/realcontrol/ScheduleRealInfoService.java
| ... | ... | @@ -15,7 +15,7 @@ public interface ScheduleRealInfoService extends BaseService<ScheduleRealInfo, L |
| 15 | 15 | |
| 16 | 16 | Map<String, Collection<ScheduleRealInfo>> findByLines(String lines); |
| 17 | 17 | |
| 18 | - Map<String, Object> outgoAdjust(Long id, String remarks, String dfsj/*,String nbbm,String jsy,String spy*/); | |
| 18 | + Map<String, Object> outgoAdjust(Long id, String remarks, String dfsj, String bcType); | |
| 19 | 19 | |
| 20 | 20 | Map<String, Object> destroy(String idsStr/*, int spaceAdjust*/, String remarks, String reason/*, int spaceNum*/); |
| 21 | 21 | |
| ... | ... | @@ -61,7 +61,9 @@ public interface ScheduleRealInfoService extends BaseService<ScheduleRealInfo, L |
| 61 | 61 | |
| 62 | 62 | List<ScheduleRealInfo> queryUserInfo(String line,String date,String state); |
| 63 | 63 | |
| 64 | - List<ScheduleRealInfo> exportWaybill(String jName,String clZbh,String lpName,String date); | |
| 64 | + List<ScheduleRealInfo> exportWaybill(String jName,String clZbh,String lpName,String date,String line); | |
| 65 | + | |
| 66 | + List<ScheduleRealInfo> exportWaybillQp(String clZbh,String date,String line); | |
| 65 | 67 | |
| 66 | 68 | List<Map<String,Object>> dailyInfo(String line,String date,String type); |
| 67 | 69 | |
| ... | ... | @@ -87,7 +89,9 @@ public interface ScheduleRealInfoService extends BaseService<ScheduleRealInfo, L |
| 87 | 89 | |
| 88 | 90 | Map<String,Object> findKMBC1(String jName,String clZbh, String date,String enddate); |
| 89 | 91 | |
| 90 | - Map<String,Object> findKMBC(String jName,String clZbh,String lpName,String date); | |
| 92 | + Map<String,Object> findKMBC(String jName,String clZbh,String lpName,String date,String line); | |
| 93 | + | |
| 94 | + Map<String,Object> findKMBCQp(String clZbh,String date,String line); | |
| 91 | 95 | |
| 92 | 96 | Map<String,Object> findKMBC2(String jName,String clZbh,String date); |
| 93 | 97 | |
| ... | ... | @@ -97,8 +101,10 @@ public interface ScheduleRealInfoService extends BaseService<ScheduleRealInfo, L |
| 97 | 101 | |
| 98 | 102 | List<ScheduleRealInfo> correctForm(String line,String startDate,String endDate,String lpName,String code, String type); |
| 99 | 103 | |
| 100 | - List<ScheduleRealInfo> queryListWaybill(String jName,String clZbh,String lpName,String date,String type); | |
| 104 | + List<ScheduleRealInfo> queryListWaybill(String jName,String clZbh,String lpName,String date,String line); | |
| 101 | 105 | |
| 106 | + List<ScheduleRealInfo> queryListWaybillQp(String clZbh,String date,String line); | |
| 107 | + | |
| 102 | 108 | Map<String, Object> removeChildTask(Long taskId); |
| 103 | 109 | |
| 104 | 110 | List<Map<String,Object>> statisticsDaily(String line,String date,String xlName); |
| ... | ... | @@ -128,4 +134,10 @@ public interface ScheduleRealInfoService extends BaseService<ScheduleRealInfo, L |
| 128 | 134 | Map<String,Object> changeBcType(Long id, String bcType, String remarks); |
| 129 | 135 | |
| 130 | 136 | Map<String,Object> historySave(ScheduleRealInfo sch); |
| 137 | + | |
| 138 | + Map<String, Object> MapById(Long id) ; | |
| 139 | + | |
| 140 | + Map<String,Object> svgAttr(String jsonStr); | |
| 141 | + | |
| 142 | + Map<String,Object> findSvgAttr(String idx); | |
| 131 | 143 | } | ... | ... |
src/main/java/com/bsth/service/realcontrol/impl/ScheduleRealInfoServiceImpl.java
| ... | ... | @@ -18,13 +18,16 @@ import com.bsth.entity.Personnel; |
| 18 | 18 | import com.bsth.entity.realcontrol.ChildTaskPlan; |
| 19 | 19 | import com.bsth.entity.realcontrol.LineConfig; |
| 20 | 20 | import com.bsth.entity.realcontrol.ScheduleRealInfo; |
| 21 | +import com.bsth.entity.realcontrol.SvgAttribute; | |
| 21 | 22 | import com.bsth.entity.schedule.CarConfigInfo; |
| 22 | 23 | import com.bsth.entity.schedule.EmployeeConfigInfo; |
| 23 | 24 | import com.bsth.entity.schedule.GuideboardInfo; |
| 25 | +import com.bsth.entity.sys.DutyEmployee; | |
| 24 | 26 | import com.bsth.entity.sys.SysUser; |
| 25 | 27 | import com.bsth.repository.LineRepository; |
| 26 | 28 | import com.bsth.repository.realcontrol.ChildTaskPlanRepository; |
| 27 | 29 | import com.bsth.repository.realcontrol.ScheduleRealInfoRepository; |
| 30 | +import com.bsth.repository.realcontrol.SvgAttributeRepository; | |
| 28 | 31 | import com.bsth.repository.schedule.CarConfigInfoRepository; |
| 29 | 32 | import com.bsth.repository.schedule.EmployeeConfigInfoRepository; |
| 30 | 33 | import com.bsth.repository.schedule.GuideboardInfoRepository; |
| ... | ... | @@ -32,12 +35,15 @@ import com.bsth.security.util.SecurityUtils; |
| 32 | 35 | import com.bsth.service.SectionRouteService; |
| 33 | 36 | import com.bsth.service.impl.BaseServiceImpl; |
| 34 | 37 | import com.bsth.service.realcontrol.ScheduleRealInfoService; |
| 38 | +import com.bsth.service.sys.DutyEmployeeService; | |
| 35 | 39 | import com.bsth.util.*; |
| 36 | 40 | import com.bsth.websocket.handler.SendUtils; |
| 37 | 41 | import com.google.common.base.Splitter; |
| 38 | 42 | import com.google.common.collect.ArrayListMultimap; |
| 43 | +import com.google.common.collect.BiMap; | |
| 39 | 44 | import com.google.common.collect.Lists; |
| 40 | 45 | import com.google.common.collect.Multimap; |
| 46 | +import org.apache.commons.lang3.StringEscapeUtils; | |
| 41 | 47 | import org.apache.commons.lang3.StringUtils; |
| 42 | 48 | import org.joda.time.format.DateTimeFormat; |
| 43 | 49 | import org.joda.time.format.DateTimeFormatter; |
| ... | ... | @@ -46,7 +52,6 @@ import org.slf4j.LoggerFactory; |
| 46 | 52 | import org.springframework.beans.factory.annotation.Autowired; |
| 47 | 53 | import org.springframework.stereotype.Service; |
| 48 | 54 | |
| 49 | -import java.net.URLEncoder; | |
| 50 | 55 | import java.text.DecimalFormat; |
| 51 | 56 | import java.text.ParseException; |
| 52 | 57 | import java.text.SimpleDateFormat; |
| ... | ... | @@ -54,431 +59,390 @@ import java.util.*; |
| 54 | 59 | |
| 55 | 60 | @Service |
| 56 | 61 | public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInfo, Long> |
| 57 | - implements ScheduleRealInfoService { | |
| 62 | + implements ScheduleRealInfoService { | |
| 58 | 63 | |
| 59 | - @Autowired | |
| 60 | - ScheduleRealInfoRepository scheduleRealInfoRepository; | |
| 64 | + @Autowired | |
| 65 | + ScheduleRealInfoRepository scheduleRealInfoRepository; | |
| 61 | 66 | |
| 62 | - @Autowired | |
| 63 | - EmployeeConfigInfoRepository employeeConfigInfoRepository; | |
| 67 | + @Autowired | |
| 68 | + EmployeeConfigInfoRepository employeeConfigInfoRepository; | |
| 64 | 69 | |
| 65 | - @Autowired | |
| 66 | - CarConfigInfoRepository carConfigInfoRepository; | |
| 67 | - | |
| 68 | - @Autowired | |
| 69 | - SectionRouteService sectionRouteService; | |
| 70 | - | |
| 71 | - /*@Autowired | |
| 72 | - BorrowCenter borrowCenter;*/ | |
| 73 | - | |
| 74 | - @Autowired | |
| 75 | - LineRepository lineRepository; | |
| 76 | - | |
| 77 | - @Autowired | |
| 78 | - GuideboardInfoRepository guideboardInfoRepository; | |
| 79 | - | |
| 80 | - @Autowired | |
| 81 | - ChildTaskPlanRepository cTaskPlanRepository; | |
| 82 | - | |
| 83 | - @Autowired | |
| 84 | - SendUtils sendUtils; | |
| 85 | - | |
| 86 | - @Autowired | |
| 87 | - DayOfSchedule dayOfSchedule; | |
| 88 | - | |
| 89 | - @Autowired | |
| 90 | - SchAttrCalculator schAttrCalculator; | |
| 91 | - | |
| 92 | - @Autowired | |
| 93 | - LineConfigData lineConfigData; | |
| 94 | - | |
| 95 | - Logger logger = LoggerFactory.getLogger(this.getClass()); | |
| 96 | - | |
| 97 | - SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 98 | - sdfMinute = new SimpleDateFormat("yyyy-MM-dd HH:mm"), sdfShort = new SimpleDateFormat("HH:mm"), | |
| 99 | - sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 100 | - | |
| 101 | - @Override | |
| 102 | - public Map<String, Collection<ScheduleRealInfo>> findByLines(String lines) { | |
| 103 | - List<String> lineList = Lists.newArrayList(Splitter.on(',').trimResults().omitEmptyStrings().split(lines)); | |
| 104 | - | |
| 105 | - Multimap<String, ScheduleRealInfo> mMap = ArrayListMultimap.create(); | |
| 106 | - | |
| 107 | - for (String lineCode : lineList) { | |
| 108 | - mMap.putAll(lineCode, dayOfSchedule.findByLineCode(lineCode)); | |
| 109 | - } | |
| 110 | - return mMap.asMap(); | |
| 111 | - } | |
| 112 | - | |
| 113 | - private final static long DAY_TIME = 1000 * 60 * 60 * 24L; | |
| 114 | - private static DateTimeFormatter fmtyyyyMMdd = DateTimeFormat.forPattern("yyyy-MM-dd"); | |
| 115 | - @Override | |
| 116 | - public Map<String, Object> outgoAdjust(Long id, String remarks, String dfsj/*, String nbbm,String jsy,String spy*/) { | |
| 117 | - Map<String, Object> map = new HashMap<>(); | |
| 118 | - try { | |
| 119 | - | |
| 120 | - ScheduleRealInfo schedule = dayOfSchedule.get(id); | |
| 121 | - | |
| 122 | - | |
| 123 | - LineConfig config = lineConfigData.get(schedule.getXlBm()); | |
| 124 | - //小于线路开始运营时间,则默认跨过24点 | |
| 125 | - if(dfsj.compareTo(config.getStartOpt()) < 0){ | |
| 126 | - schedule.setRealExecDate(fmtyyyyMMdd.print(schedule.getScheduleDate().getTime() + DAY_TIME)); | |
| 127 | - } | |
| 128 | - else { | |
| 129 | - schedule.setRealExecDate(schedule.getScheduleDateStr()); | |
| 130 | - } | |
| 131 | - | |
| 132 | - schedule.setDfsjAll(dfsj); | |
| 133 | - schedule.addRemarks(remarks); | |
| 134 | - | |
| 135 | - List<ScheduleRealInfo> ts = new ArrayList<>(); | |
| 136 | - ts.add(schedule); | |
| 137 | - //调整终点时间和下一个班次的应到时间 | |
| 138 | - schedule.calcEndTime(); | |
| 139 | - ScheduleRealInfo nextSch = dayOfSchedule.next(schedule); | |
| 140 | - if(null != nextSch){ | |
| 141 | - nextSch.setQdzArrDateJH(schedule.getZdsj()); | |
| 142 | - ts.add(nextSch); | |
| 143 | - } | |
| 144 | - | |
| 145 | - // 持久化到数据库 | |
| 146 | - dayOfSchedule.save(schedule); | |
| 147 | - | |
| 148 | - map.put("status", ResponseCode.SUCCESS); | |
| 149 | - map.put("ts", ts); | |
| 150 | - } catch (Exception e) { | |
| 151 | - logger.error("", e); | |
| 152 | - map.put("status", ResponseCode.ERROR); | |
| 153 | - } | |
| 154 | - return map; | |
| 155 | - } | |
| 156 | - | |
| 157 | - @Override | |
| 158 | - public Map<String, Object> destroy(String idsStr, /*int spaceAdjust, */String remarks, String reason/*, int spaceNum*/) { | |
| 159 | - | |
| 160 | - Map<String, Object> map = new HashMap<>(); | |
| 161 | - List<ScheduleRealInfo> rsList = new ArrayList<>(); | |
| 162 | - map.put("ts", rsList); | |
| 163 | - try { | |
| 164 | - List<String> idList = Lists.newArrayList(Splitter.on(',').trimResults().omitEmptyStrings().split(idsStr)); | |
| 165 | - | |
| 166 | - ScheduleRealInfo schedule = null; | |
| 167 | - for (String id : idList) { | |
| 168 | - schedule = dayOfSchedule.get(Long.parseLong(id)); | |
| 169 | - if(schedule.isDestroy()){ | |
| 170 | - map.put("status", ResponseCode.ERROR); | |
| 171 | - map.put("msg", "不必要的重复烂班!"); | |
| 172 | - return map; | |
| 173 | - } | |
| 174 | - | |
| 175 | - schedule.setAdjustExps(reason); | |
| 176 | - schedule.destroy(); | |
| 177 | - schedule.addRemarks(remarks); | |
| 178 | - | |
| 179 | - dayOfSchedule.save(schedule); | |
| 180 | - rsList.add(schedule); | |
| 181 | - } | |
| 182 | - | |
| 183 | - map.put("status", ResponseCode.SUCCESS); | |
| 184 | - } catch (Exception e) { | |
| 185 | - logger.error("", e); | |
| 186 | - map.put("status", ResponseCode.ERROR); | |
| 187 | - } | |
| 188 | - return map; | |
| 189 | - } | |
| 190 | - | |
| 191 | - // 线路id获取驾驶员 | |
| 192 | - @Override | |
| 193 | - public List<Map<String, String>> findDriverByLine(String lineCode) { | |
| 194 | - List<EmployeeConfigInfo> list = employeeConfigInfoRepository.findBylineCode(lineCode); | |
| 195 | - | |
| 196 | - List<Map<String, String>> rsList = new ArrayList<>(); | |
| 197 | - Map<String, String> map = null; | |
| 198 | - Personnel driver = null; | |
| 199 | - String code = null; | |
| 200 | - | |
| 201 | - for (EmployeeConfigInfo employee : list) { | |
| 202 | - driver = employee.getJsy(); | |
| 203 | - if (driver != null) { | |
| 204 | - map = new HashMap<>(); | |
| 205 | - code = driver.getJobCode(); | |
| 206 | - map.put("id", code + "/" + driver.getPersonnelName()); | |
| 207 | - map.put("text", code + "/" + driver.getPersonnelName()); | |
| 208 | - rsList.add(map); | |
| 209 | - } | |
| 210 | - } | |
| 211 | - return rsList; | |
| 212 | - } | |
| 213 | - | |
| 214 | - // 线路id获取售票员 | |
| 215 | - @Override | |
| 216 | - public List<Map<String, String>> findConductorByLine(String lineCode) { | |
| 217 | - List<EmployeeConfigInfo> list = employeeConfigInfoRepository.findBylineCode(lineCode); | |
| 218 | - | |
| 219 | - List<Map<String, String>> rsList = new ArrayList<>(); | |
| 220 | - Map<String, String> map = null; | |
| 221 | - Personnel conductor = null; | |
| 222 | - String code = null; | |
| 223 | - | |
| 224 | - for (EmployeeConfigInfo employee : list) { | |
| 225 | - conductor = employee.getSpy(); | |
| 226 | - if (conductor != null) { | |
| 227 | - code = conductor.getJobCode(); | |
| 228 | - map = new HashMap<>(); | |
| 229 | - map.put("id", code + "/" + conductor.getPersonnelName()); | |
| 230 | - map.put("text", code + "/" + conductor.getPersonnelName()); | |
| 231 | - rsList.add(map); | |
| 232 | - } | |
| 233 | - } | |
| 234 | - return rsList; | |
| 235 | - } | |
| 236 | - | |
| 237 | - @Override | |
| 238 | - public List<Map<String, String>> findCarByLine(String lineCode) { | |
| 239 | - | |
| 240 | - List<CarConfigInfo> list = carConfigInfoRepository.findBylineCode(lineCode); | |
| 241 | - | |
| 242 | - List<Map<String, String>> rsList = new ArrayList<>(); | |
| 243 | - Map<String, String> map = null; | |
| 244 | - Cars car = null; | |
| 245 | - String code = null; | |
| 246 | - | |
| 247 | - for (CarConfigInfo cci : list) { | |
| 248 | - car = cci.getCl(); | |
| 249 | - if (car != null) { | |
| 250 | - code = car.getInsideCode(); | |
| 251 | - map = new HashMap<>(); | |
| 252 | - map.put("id", code); | |
| 253 | - map.put("text", code); | |
| 254 | - rsList.add(map); | |
| 255 | - } | |
| 256 | - } | |
| 257 | - return rsList; | |
| 258 | - } | |
| 259 | - | |
| 260 | - | |
| 261 | - /** | |
| 262 | - * 临加班次 | |
| 263 | - */ | |
| 264 | - @Override | |
| 265 | - public Map<String, Object> save(ScheduleRealInfo t) { | |
| 266 | - Map<String, Object> rs = new HashMap<>(); | |
| 267 | - try{ | |
| 268 | - SysUser user = SecurityUtils.getCurrentUser(); | |
| 269 | - String schDate = DayOfSchedule.currSchDateMap.get(t.getXlBm()); | |
| 270 | - | |
| 271 | - SimpleDateFormat sdfyyyyMMdd = new SimpleDateFormat("yyyy-MM-dd") | |
| 272 | - ,sdfyyyyMMddHHmm = new SimpleDateFormat("yyyy-MM-ddHH:mm"); | |
| 273 | - | |
| 274 | - if(StringUtils.isEmpty(t.getjGh())){ | |
| 275 | - rs.put("status", ResponseCode.ERROR); | |
| 276 | - rs.put("msg", "驾驶员工号不能为空!"); | |
| 277 | - return rs; | |
| 278 | - } | |
| 279 | - //截取工号 | |
| 280 | - if(t.getjGh().indexOf("-") != -1){ | |
| 281 | - t.setjGh(t.getjGh().split("-")[1]); | |
| 282 | - } | |
| 283 | - | |
| 284 | - t.setScheduleDateStr(schDate); | |
| 285 | - t.setScheduleDate(sdfyyyyMMdd.parse(schDate)); | |
| 286 | - t.setRealExecDate(schDate); | |
| 287 | - t.setCreateBy(user); | |
| 288 | - t.setSflj(true); | |
| 289 | - t.setLate(false); | |
| 290 | - t.setDfsj(t.getFcsj()); | |
| 291 | - t.setZdsjT(sdfyyyyMMddHHmm.parse(schDate + t.getZdsj()).getTime()); | |
| 292 | - | |
| 293 | - | |
| 294 | - //班次历时 | |
| 295 | - t.setBcsj(DateUtils.calcHHmmDiff(t.getFcsj(), t.getZdsj()) / 1000 / 60); | |
| 296 | - | |
| 297 | - //起终点名称 | |
| 298 | - String prefix = t.getXlBm() + "_" + t.getXlDir() + "_"; | |
| 299 | - t.setQdzName(BasicData.getStationNameByCode(t.getQdzCode(), prefix)); | |
| 300 | - t.setZdzName(BasicData.getStationNameByCode(t.getZdzCode(), prefix)); | |
| 301 | - | |
| 302 | - //计算班次实际时间 | |
| 303 | - schAttrCalculator.calcRealDate(t).calcAllTimeByFcsj(t); | |
| 304 | - if(t.getZdsjT() < t.getFcsjT()){ | |
| 305 | - rs.put("status", ResponseCode.ERROR); | |
| 306 | - rs.put("msg", "起终点时间异常!"); | |
| 307 | - return rs; | |
| 308 | - } | |
| 309 | - | |
| 310 | - //实时入库 | |
| 311 | - super.save(t); | |
| 312 | - | |
| 313 | - // 加入缓存 | |
| 314 | - dayOfSchedule.put(t); | |
| 315 | - | |
| 316 | - //更新起点应到时间 | |
| 317 | - List<ScheduleRealInfo> ts = dayOfSchedule.updateQdzTimePlan(t.getClZbh()); | |
| 318 | - | |
| 319 | - | |
| 320 | - rs.put("ts", ts); | |
| 321 | - rs.put("t", t); | |
| 322 | - }catch(Exception e){ | |
| 323 | - logger.error("", e); | |
| 324 | - rs.put("status", ResponseCode.ERROR); | |
| 325 | - } | |
| 326 | - return rs; | |
| 327 | - } | |
| 328 | - | |
| 329 | - @Override | |
| 330 | - public Map<String, Object> delete(Long id) { | |
| 331 | - Map<String, Object> rs = new HashMap<>(); | |
| 332 | - rs.put("status", ResponseCode.ERROR); | |
| 333 | - | |
| 334 | - ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 335 | - if(sch == null){ | |
| 336 | - rs.put("msg", "无效的id号"); | |
| 337 | - return rs; | |
| 338 | - } | |
| 339 | - | |
| 340 | - if(!sch.isSflj()){ | |
| 341 | - rs.put("msg", "你只能删除临加班次"); | |
| 342 | - return rs; | |
| 343 | - } | |
| 344 | - | |
| 345 | - dayOfSchedule.delete(sch); | |
| 346 | - //ScheduleRealInfo sch = dayOfSchedule.delete(id); | |
| 347 | - //数据库删除 | |
| 348 | - rs = super.delete(id); | |
| 349 | - //更新起点应到时间 | |
| 350 | - List<ScheduleRealInfo> ts = dayOfSchedule.updateQdzTimePlan(sch.getClZbh()); | |
| 351 | - rs.put("ts", ts); | |
| 352 | - rs.put("delete", sch); | |
| 353 | - | |
| 354 | - return rs; | |
| 355 | - } | |
| 356 | - | |
| 357 | - @Override | |
| 358 | - public List<Map<String, String>> sreachVehic(String nbbm) { | |
| 359 | - // 转大写 | |
| 360 | - nbbm = nbbm.toUpperCase(); | |
| 361 | - | |
| 362 | - List<Map<String, String>> list = new ArrayList<>(); | |
| 363 | - Map<String, String> map; | |
| 364 | - Set<String> allSet = BasicData.nbbm2CompanyCodeMap.keySet(); | |
| 365 | - | |
| 366 | - Line line; | |
| 367 | - for (String k : allSet) { | |
| 368 | - if (k.indexOf(nbbm) != -1) { | |
| 369 | - // 所属线路 | |
| 370 | - map = new HashMap<>(); | |
| 371 | - line = BasicData.nbbm2LineMap.get(k); | |
| 372 | - map.put("id", k); | |
| 373 | - map.put("text", k); | |
| 374 | - if (null != line) { | |
| 375 | - map.put("lineName", line.getName()); | |
| 376 | - map.put("lineCode", line.getLineCode()); | |
| 377 | - } | |
| 378 | - | |
| 379 | - list.add(map); | |
| 380 | - } | |
| 381 | - | |
| 382 | - if (list.size() > 20) | |
| 383 | - break; | |
| 384 | - } | |
| 385 | - return list; | |
| 386 | - } | |
| 387 | - | |
| 388 | -/* @Override | |
| 389 | - public Map<String, Object> adjust(Long id, String nbbm, String jsy, String spy, Integer revertLine, Integer borrowLine, String borrowTimeStr, String revertTimeStr) { | |
| 390 | - // 班次 | |
| 391 | - ScheduleRealInfo schedule = dayOfSchedule.get(id); | |
| 392 | - int upDown = Integer.parseInt(schedule.getXlDir()); | |
| 70 | + @Autowired | |
| 71 | + CarConfigInfoRepository carConfigInfoRepository; | |
| 393 | 72 | |
| 394 | - String rq = sdfMonth.format(new Date()); | |
| 395 | - // 换车 | |
| 396 | - if (!StringUtils.isBlank(nbbm)) { | |
| 397 | - adjustCar(schedule, nbbm); | |
| 398 | - } | |
| 399 | - | |
| 400 | - List<String> tempArray; | |
| 401 | - // 换驾驶员 | |
| 402 | - if (!StringUtils.isBlank(jsy)) { | |
| 403 | - tempArray = Splitter.on("/").splitToList(jsy); | |
| 404 | - adjustDriver(schedule, tempArray.get(0), tempArray.get(1)); | |
| 405 | - } | |
| 406 | - | |
| 407 | - // 换售票员 | |
| 408 | - if (!StringUtils.isBlank(spy)) { | |
| 409 | - tempArray = Splitter.on("/").splitToList(spy); | |
| 410 | - adjustConductor(schedule, tempArray.get(0), tempArray.get(1)); | |
| 411 | - } | |
| 412 | - | |
| 413 | - if(borrowLine != null && borrowTimeStr != null){ | |
| 414 | - try { | |
| 415 | - //跨线路借车 | |
| 416 | - Long t = sdfMinute.parse(rq + " " + borrowTimeStr).getTime(); | |
| 417 | - //borrowCenter.put(nbbm, borrowLine, 0, t, upDown); | |
| 418 | - } catch (ParseException e) { | |
| 419 | - e.printStackTrace(); | |
| 420 | - } | |
| 421 | - } | |
| 422 | - | |
| 423 | - if(revertLine != null && revertTimeStr != null){ | |
| 424 | - //定时还车 | |
| 425 | - try { | |
| 426 | - Long t = sdfMinute.parse(rq + " " + revertTimeStr).getTime(); | |
| 427 | - //还车的时候不用切走向 | |
| 428 | - //borrowCenter.put(nbbm, revertLine, 1, t, -1); | |
| 429 | - } catch (ParseException e) { | |
| 430 | - e.printStackTrace(); | |
| 431 | - } | |
| 432 | - } | |
| 433 | - | |
| 434 | - scheduleRealInfoRepository.save(schedule); | |
| 435 | - //ScheduleBuffer.persistentList.add(schedule); | |
| 436 | - | |
| 437 | - Map<String, Object> map = new HashMap<>(); | |
| 438 | - map.put("status", 200); | |
| 439 | - map.put("t", schedule); | |
| 440 | - return map; | |
| 441 | - }*/ | |
| 442 | - | |
| 443 | - @Override | |
| 444 | - public void adjustCar(ScheduleRealInfo schedule, String car) { | |
| 445 | - schedule.setClZbh(car); | |
| 446 | - } | |
| 447 | - | |
| 448 | - @Override | |
| 449 | - public void adjustDriver(ScheduleRealInfo schedule, String driver, String driverName) { | |
| 450 | - if(driver.indexOf("-") != -1) | |
| 451 | - driver = driver.split("-")[1]; | |
| 452 | - schedule.setjGh(driver); | |
| 453 | - schedule.setjName(driverName); | |
| 454 | - } | |
| 73 | + @Autowired | |
| 74 | + SectionRouteService sectionRouteService; | |
| 455 | 75 | |
| 456 | - @Override | |
| 457 | - public void adjustConductor(ScheduleRealInfo schedule, String conductor, String conductorName) { | |
| 458 | - if(conductor.indexOf("-") != -1) | |
| 459 | - conductor = conductor.split("-")[1]; | |
| 460 | - schedule.setsGh(conductor); | |
| 461 | - schedule.setsName(conductorName); | |
| 462 | - } | |
| 76 | + /*@Autowired | |
| 77 | + BorrowCenter borrowCenter;*/ | |
| 463 | 78 | |
| 464 | - @Override | |
| 465 | - public List<ScheduleRealInfo> queryUserInfo(String line, String date,String state) { | |
| 466 | - if(state.equals("2")){ | |
| 467 | - return scheduleRealInfoRepository.queryUserInfo2(line, date); | |
| 468 | - }else{ | |
| 469 | - return scheduleRealInfoRepository.queryUserInfo3(line, date); | |
| 470 | - } | |
| 471 | - | |
| 472 | - } | |
| 473 | - /** | |
| 474 | - * | |
| 475 | - */ | |
| 476 | - @Override | |
| 477 | - public List<ScheduleRealInfo> exportWaybill(String jName, String clZbh, String lpName,String date) { | |
| 79 | + @Autowired | |
| 80 | + LineRepository lineRepository; | |
| 81 | + | |
| 82 | + @Autowired | |
| 83 | + GuideboardInfoRepository guideboardInfoRepository; | |
| 84 | + | |
| 85 | + @Autowired | |
| 86 | + ChildTaskPlanRepository cTaskPlanRepository; | |
| 87 | + | |
| 88 | + @Autowired | |
| 89 | + SendUtils sendUtils; | |
| 90 | + | |
| 91 | + @Autowired | |
| 92 | + DayOfSchedule dayOfSchedule; | |
| 93 | + | |
| 94 | + @Autowired | |
| 95 | + SchAttrCalculator schAttrCalculator; | |
| 96 | + | |
| 97 | + @Autowired | |
| 98 | + LineConfigData lineConfigData; | |
| 99 | + | |
| 100 | + @Autowired | |
| 101 | + DutyEmployeeService dutyEmployeeService; | |
| 102 | + | |
| 103 | + Logger logger = LoggerFactory.getLogger(this.getClass()); | |
| 104 | + | |
| 105 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 106 | + sdfMinute = new SimpleDateFormat("yyyy-MM-dd HH:mm"), sdfShort = new SimpleDateFormat("HH:mm"), | |
| 107 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 108 | + | |
| 109 | + @Override | |
| 110 | + public Map<String, Collection<ScheduleRealInfo>> findByLines(String lines) { | |
| 111 | + List<String> lineList = Lists.newArrayList(Splitter.on(',').trimResults().omitEmptyStrings().split(lines)); | |
| 112 | + | |
| 113 | + Multimap<String, ScheduleRealInfo> mMap = ArrayListMultimap.create(); | |
| 114 | + | |
| 115 | + for (String lineCode : lineList) { | |
| 116 | + mMap.putAll(lineCode, dayOfSchedule.findByLineCode(lineCode)); | |
| 117 | + } | |
| 118 | + return mMap.asMap(); | |
| 119 | + } | |
| 120 | + | |
| 121 | + private final static long DAY_TIME = 1000 * 60 * 60 * 24L; | |
| 122 | + private static DateTimeFormatter fmtyyyyMMdd = DateTimeFormat.forPattern("yyyy-MM-dd"); | |
| 123 | + | |
| 124 | + @Override | |
| 125 | + public Map<String, Object> outgoAdjust(Long id, String remarks, String dfsj, String bcType) { | |
| 126 | + Map<String, Object> map = new HashMap<>(); | |
| 127 | + try { | |
| 128 | + | |
| 129 | + ScheduleRealInfo schedule = dayOfSchedule.get(id); | |
| 130 | + | |
| 131 | + | |
| 132 | + LineConfig config = lineConfigData.get(schedule.getXlBm()); | |
| 133 | + //小于线路开始运营时间,则默认跨过24点 | |
| 134 | + if (dfsj.compareTo(config.getStartOpt()) < 0) { | |
| 135 | + schedule.setRealExecDate(fmtyyyyMMdd.print(schedule.getScheduleDate().getTime() + DAY_TIME)); | |
| 136 | + } else { | |
| 137 | + schedule.setRealExecDate(schedule.getScheduleDateStr()); | |
| 138 | + } | |
| 139 | + | |
| 140 | + schedule.setDfsjAll(dfsj); | |
| 141 | + schedule.addRemarks(remarks); | |
| 142 | + | |
| 143 | + List<ScheduleRealInfo> ts = new ArrayList<>(); | |
| 144 | + ts.add(schedule); | |
| 145 | + //调整终点时间和下一个班次的应到时间 | |
| 146 | + schedule.calcEndTime(); | |
| 147 | + ScheduleRealInfo nextSch = dayOfSchedule.next(schedule); | |
| 148 | + if (null != nextSch) { | |
| 149 | + nextSch.setQdzArrDateJH(schedule.getZdsj()); | |
| 150 | + ts.add(nextSch); | |
| 151 | + } | |
| 152 | + | |
| 153 | + //调整班次类型 | |
| 154 | + if(StringUtils.isNotEmpty(bcType)){ | |
| 155 | + schedule.setBcType(bcType); | |
| 156 | + } | |
| 157 | + | |
| 158 | + // 持久化到数据库 | |
| 159 | + dayOfSchedule.save(schedule); | |
| 160 | + | |
| 161 | + map.put("status", ResponseCode.SUCCESS); | |
| 162 | + map.put("ts", ts); | |
| 163 | + } catch (Exception e) { | |
| 164 | + logger.error("", e); | |
| 165 | + map.put("status", ResponseCode.ERROR); | |
| 166 | + } | |
| 167 | + return map; | |
| 168 | + } | |
| 169 | + | |
| 170 | + @Override | |
| 171 | + public Map<String, Object> destroy(String idsStr, /*int spaceAdjust, */String remarks, String reason/*, int spaceNum*/) { | |
| 172 | + | |
| 173 | + Map<String, Object> map = new HashMap<>(); | |
| 174 | + List<ScheduleRealInfo> rsList = new ArrayList<>(); | |
| 175 | + map.put("ts", rsList); | |
| 176 | + try { | |
| 177 | + List<String> idList = Lists.newArrayList(Splitter.on(',').trimResults().omitEmptyStrings().split(idsStr)); | |
| 178 | + | |
| 179 | + ScheduleRealInfo schedule = null; | |
| 180 | + for (String id : idList) { | |
| 181 | + schedule = dayOfSchedule.get(Long.parseLong(id)); | |
| 182 | + if (schedule.isDestroy()) { | |
| 183 | + map.put("status", ResponseCode.ERROR); | |
| 184 | + map.put("msg", "不必要的重复烂班!"); | |
| 185 | + return map; | |
| 186 | + } | |
| 187 | + | |
| 188 | + schedule.setAdjustExps(reason); | |
| 189 | + schedule.destroy(); | |
| 190 | + schedule.addRemarks(remarks); | |
| 191 | + | |
| 192 | + dayOfSchedule.save(schedule); | |
| 193 | + rsList.add(schedule); | |
| 194 | + } | |
| 195 | + | |
| 196 | + map.put("status", ResponseCode.SUCCESS); | |
| 197 | + } catch (Exception e) { | |
| 198 | + logger.error("", e); | |
| 199 | + map.put("status", ResponseCode.ERROR); | |
| 200 | + } | |
| 201 | + return map; | |
| 202 | + } | |
| 203 | + | |
| 204 | + // 线路id获取驾驶员 | |
| 205 | + @Override | |
| 206 | + public List<Map<String, String>> findDriverByLine(String lineCode) { | |
| 207 | + List<EmployeeConfigInfo> list = employeeConfigInfoRepository.findBylineCode(lineCode); | |
| 208 | + | |
| 209 | + List<Map<String, String>> rsList = new ArrayList<>(); | |
| 210 | + Map<String, String> map = null; | |
| 211 | + Personnel driver = null; | |
| 212 | + String code = null; | |
| 213 | + | |
| 214 | + for (EmployeeConfigInfo employee : list) { | |
| 215 | + driver = employee.getJsy(); | |
| 216 | + if (driver != null) { | |
| 217 | + map = new HashMap<>(); | |
| 218 | + code = driver.getJobCode(); | |
| 219 | + map.put("id", code + "/" + driver.getPersonnelName()); | |
| 220 | + map.put("text", code + "/" + driver.getPersonnelName()); | |
| 221 | + rsList.add(map); | |
| 222 | + } | |
| 223 | + } | |
| 224 | + return rsList; | |
| 225 | + } | |
| 226 | + | |
| 227 | + // 线路id获取售票员 | |
| 228 | + @Override | |
| 229 | + public List<Map<String, String>> findConductorByLine(String lineCode) { | |
| 230 | + List<EmployeeConfigInfo> list = employeeConfigInfoRepository.findBylineCode(lineCode); | |
| 231 | + | |
| 232 | + List<Map<String, String>> rsList = new ArrayList<>(); | |
| 233 | + Map<String, String> map = null; | |
| 234 | + Personnel conductor = null; | |
| 235 | + String code = null; | |
| 236 | + | |
| 237 | + for (EmployeeConfigInfo employee : list) { | |
| 238 | + conductor = employee.getSpy(); | |
| 239 | + if (conductor != null) { | |
| 240 | + code = conductor.getJobCode(); | |
| 241 | + map = new HashMap<>(); | |
| 242 | + map.put("id", code + "/" + conductor.getPersonnelName()); | |
| 243 | + map.put("text", code + "/" + conductor.getPersonnelName()); | |
| 244 | + rsList.add(map); | |
| 245 | + } | |
| 246 | + } | |
| 247 | + return rsList; | |
| 248 | + } | |
| 249 | + | |
| 250 | + @Override | |
| 251 | + public List<Map<String, String>> findCarByLine(String lineCode) { | |
| 252 | + | |
| 253 | + List<CarConfigInfo> list = carConfigInfoRepository.findBylineCode(lineCode); | |
| 254 | + | |
| 255 | + List<Map<String, String>> rsList = new ArrayList<>(); | |
| 256 | + Map<String, String> map = null; | |
| 257 | + Cars car = null; | |
| 258 | + String code = null; | |
| 259 | + | |
| 260 | + for (CarConfigInfo cci : list) { | |
| 261 | + car = cci.getCl(); | |
| 262 | + if (car != null) { | |
| 263 | + code = car.getInsideCode(); | |
| 264 | + map = new HashMap<>(); | |
| 265 | + map.put("id", code); | |
| 266 | + map.put("text", code); | |
| 267 | + rsList.add(map); | |
| 268 | + } | |
| 269 | + } | |
| 270 | + return rsList; | |
| 271 | + } | |
| 272 | + | |
| 273 | + | |
| 274 | + /** | |
| 275 | + * 临加班次 | |
| 276 | + */ | |
| 277 | + @Override | |
| 278 | + public Map<String, Object> save(ScheduleRealInfo t) { | |
| 279 | + Map<String, Object> rs = new HashMap<>(); | |
| 280 | + try { | |
| 281 | + if (BasicData.deviceId2NbbmMap.inverse().get(t.getClZbh()) == null) { | |
| 282 | + rs.put("msg", "车辆 " + t.getClZbh() + " <a href=\"/#/busInfoManage\" target=_blank>车辆基础信息</a> 里找不到!"); | |
| 283 | + rs.put("status", ResponseCode.ERROR); | |
| 284 | + return rs; | |
| 285 | + } | |
| 286 | + | |
| 287 | + SysUser user = SecurityUtils.getCurrentUser(); | |
| 288 | + String schDate = DayOfSchedule.currSchDateMap.get(t.getXlBm()); | |
| 289 | + | |
| 290 | + SimpleDateFormat sdfyyyyMMdd = new SimpleDateFormat("yyyy-MM-dd"), sdfyyyyMMddHHmm = new SimpleDateFormat("yyyy-MM-ddHH:mm"); | |
| 291 | + | |
| 292 | + if (StringUtils.isEmpty(t.getjGh())) { | |
| 293 | + rs.put("status", ResponseCode.ERROR); | |
| 294 | + rs.put("msg", "驾驶员工号不能为空!"); | |
| 295 | + return rs; | |
| 296 | + } | |
| 297 | + //截取工号 | |
| 298 | + if (t.getjGh().indexOf("-") != -1) { | |
| 299 | + t.setjGh(t.getjGh().split("-")[1]); | |
| 300 | + } | |
| 301 | + | |
| 302 | + t.setScheduleDateStr(schDate); | |
| 303 | + t.setScheduleDate(sdfyyyyMMdd.parse(schDate)); | |
| 304 | + t.setRealExecDate(schDate); | |
| 305 | + t.setCreateBy(user); | |
| 306 | + t.setSflj(true); | |
| 307 | + t.setLate(false); | |
| 308 | + t.setDfsj(t.getFcsj()); | |
| 309 | + t.setZdsjT(sdfyyyyMMddHHmm.parse(schDate + t.getZdsj()).getTime()); | |
| 310 | + | |
| 311 | + | |
| 312 | + //班次历时 | |
| 313 | + t.setBcsj(DateUtils.calcHHmmDiff(t.getFcsj(), t.getZdsj()) / 1000 / 60); | |
| 314 | + | |
| 315 | + //起终点名称 | |
| 316 | + String prefix = t.getXlBm() + "_" + t.getXlDir() + "_"; | |
| 317 | + t.setQdzName(BasicData.getStationNameByCode(t.getQdzCode(), prefix)); | |
| 318 | + t.setZdzName(BasicData.getStationNameByCode(t.getZdzCode(), prefix)); | |
| 319 | + | |
| 320 | + //计算班次实际时间 | |
| 321 | + schAttrCalculator.calcRealDate(t).calcAllTimeByFcsj(t); | |
| 322 | + if (t.getZdsjT() < t.getFcsjT()) { | |
| 323 | + rs.put("status", ResponseCode.ERROR); | |
| 324 | + rs.put("msg", "起终点时间异常!"); | |
| 325 | + return rs; | |
| 326 | + } | |
| 327 | + | |
| 328 | + //实时入库 | |
| 329 | + super.save(t); | |
| 330 | + | |
| 331 | + // 加入缓存 | |
| 332 | + dayOfSchedule.put(t); | |
| 333 | + | |
| 334 | + //更新起点应到时间 | |
| 335 | + List<ScheduleRealInfo> ts = dayOfSchedule.updateQdzTimePlan(t.getClZbh()); | |
| 336 | + | |
| 337 | + | |
| 338 | + rs.put("ts", ts); | |
| 339 | + rs.put("t", t); | |
| 340 | + } catch (Exception e) { | |
| 341 | + logger.error("", e); | |
| 342 | + rs.put("status", ResponseCode.ERROR); | |
| 343 | + } | |
| 344 | + return rs; | |
| 345 | + } | |
| 346 | + | |
| 347 | + @Override | |
| 348 | + public Map<String, Object> delete(Long id) { | |
| 349 | + Map<String, Object> rs = new HashMap<>(); | |
| 350 | + rs.put("status", ResponseCode.ERROR); | |
| 351 | + | |
| 352 | + ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 353 | + if (sch == null) { | |
| 354 | + rs.put("msg", "无效的id号"); | |
| 355 | + return rs; | |
| 356 | + } | |
| 357 | + | |
| 358 | + if (!sch.isSflj()) { | |
| 359 | + rs.put("msg", "你只能删除临加班次"); | |
| 360 | + return rs; | |
| 361 | + } | |
| 362 | + | |
| 363 | + dayOfSchedule.delete(sch); | |
| 364 | + //ScheduleRealInfo sch = dayOfSchedule.delete(id); | |
| 365 | + //数据库删除 | |
| 366 | + rs = super.delete(id); | |
| 367 | + //更新起点应到时间 | |
| 368 | + List<ScheduleRealInfo> ts = dayOfSchedule.updateQdzTimePlan(sch.getClZbh()); | |
| 369 | + rs.put("ts", ts); | |
| 370 | + rs.put("delete", sch); | |
| 371 | + | |
| 372 | + return rs; | |
| 373 | + } | |
| 374 | + | |
| 375 | + @Override | |
| 376 | + public List<Map<String, String>> sreachVehic(String nbbm) { | |
| 377 | + // 转大写 | |
| 378 | + nbbm = nbbm.toUpperCase(); | |
| 379 | + | |
| 380 | + List<Map<String, String>> list = new ArrayList<>(); | |
| 381 | + Map<String, String> map; | |
| 382 | + Set<String> allSet = BasicData.nbbm2CompanyCodeMap.keySet(); | |
| 383 | + | |
| 384 | + Line line; | |
| 385 | + for (String k : allSet) { | |
| 386 | + if (k.indexOf(nbbm) != -1) { | |
| 387 | + // 所属线路 | |
| 388 | + map = new HashMap<>(); | |
| 389 | + line = BasicData.nbbm2LineMap.get(k); | |
| 390 | + map.put("id", k); | |
| 391 | + map.put("text", k); | |
| 392 | + if (null != line) { | |
| 393 | + map.put("lineName", line.getName()); | |
| 394 | + map.put("lineCode", line.getLineCode()); | |
| 395 | + } | |
| 396 | + | |
| 397 | + list.add(map); | |
| 398 | + } | |
| 399 | + | |
| 400 | + if (list.size() > 20) | |
| 401 | + break; | |
| 402 | + } | |
| 403 | + return list; | |
| 404 | + } | |
| 405 | + | |
| 406 | + @Override | |
| 407 | + public void adjustCar(ScheduleRealInfo schedule, String car) { | |
| 408 | + schedule.setClZbh(car); | |
| 409 | + } | |
| 410 | + | |
| 411 | + @Override | |
| 412 | + public void adjustDriver(ScheduleRealInfo schedule, String driver, String driverName) { | |
| 413 | + if (driver.indexOf("-") != -1) | |
| 414 | + driver = driver.split("-")[1]; | |
| 415 | + schedule.setjGh(driver); | |
| 416 | + schedule.setjName(driverName); | |
| 417 | + } | |
| 418 | + | |
| 419 | + @Override | |
| 420 | + public void adjustConductor(ScheduleRealInfo schedule, String conductor, String conductorName) { | |
| 421 | + if (conductor.indexOf("-") != -1) | |
| 422 | + conductor = conductor.split("-")[1]; | |
| 423 | + schedule.setsGh(conductor); | |
| 424 | + schedule.setsName(conductorName); | |
| 425 | + } | |
| 426 | + | |
| 427 | + @Override | |
| 428 | + public List<ScheduleRealInfo> queryUserInfo(String line, String date, String state) { | |
| 429 | + if (state.equals("2")) { | |
| 430 | + return scheduleRealInfoRepository.queryUserInfo2(line, date); | |
| 431 | + } else { | |
| 432 | + return scheduleRealInfoRepository.queryUserInfo3(line, date); | |
| 433 | + } | |
| 434 | + | |
| 435 | + } | |
| 436 | + | |
| 437 | + /** | |
| 438 | + * | |
| 439 | + */ | |
| 440 | + @Override | |
| 441 | + public List<ScheduleRealInfo> exportWaybill(String jName, String clZbh, String lpName,String date,String line) { | |
| 478 | 442 | ReportUtils ee = new ReportUtils(); |
| 479 | 443 | ReportRelatedUtils rru = new ReportRelatedUtils(); |
| 480 | 444 | List<Iterator<?>> list = new ArrayList<Iterator<?>>(); |
| 481 | - List<ScheduleRealInfo> scheduleRealInfos = scheduleRealInfoRepository.queryListWaybill(jName, clZbh, lpName,date); | |
| 445 | + List<ScheduleRealInfo> scheduleRealInfos = scheduleRealInfoRepository.queryListWaybill(jName, clZbh, lpName,date,line); | |
| 482 | 446 | List<Map<String,Object>> listMap = new ArrayList<Map<String,Object>>(); |
| 483 | 447 | |
| 484 | 448 | DecimalFormat format = new DecimalFormat("0.00"); |
| ... | ... | @@ -499,7 +463,6 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 499 | 463 | //计划班次,烂班班次,增加班次 |
| 500 | 464 | tempJhlc = scheduleRealInfo.getJhlc()==null?0:scheduleRealInfo.getJhlc(); |
| 501 | 465 | if(scheduleRealInfo.isSflj()){ |
| 502 | - addMileage += tempJhlc; | |
| 503 | 466 | ljbc++; |
| 504 | 467 | }else{ |
| 505 | 468 | jhlc += tempJhlc; |
| ... | ... | @@ -513,7 +476,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 513 | 476 | //计算营运里程,空驶里程 |
| 514 | 477 | if(childTaskPlans.isEmpty()){ |
| 515 | 478 | if(scheduleRealInfo.getBcType().equals("in") || scheduleRealInfo.getBcType().equals("out") |
| 516 | - || scheduleRealInfo.getBcType().equals("venting")){ | |
| 479 | + ){ | |
| 517 | 480 | ksgl += tempJhlc; |
| 518 | 481 | }else{ |
| 519 | 482 | yygl += tempJhlc; |
| ... | ... | @@ -523,8 +486,14 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 523 | 486 | while(it.hasNext()){ |
| 524 | 487 | ChildTaskPlan childTaskPlan = it.next(); |
| 525 | 488 | if(childTaskPlan.getMileageType().equals("empty")){ |
| 489 | + if(scheduleRealInfo.isSflj()){ | |
| 490 | + addMileage += tempJhlc; | |
| 491 | + } | |
| 526 | 492 | ksgl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); |
| 527 | 493 | }else{ |
| 494 | + if(scheduleRealInfo.isSflj()){ | |
| 495 | + addMileage += tempJhlc; | |
| 496 | + } | |
| 528 | 497 | yygl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); |
| 529 | 498 | } |
| 530 | 499 | } |
| ... | ... | @@ -573,113 +542,141 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 573 | 542 | |
| 574 | 543 | list.add(listMap.iterator()); |
| 575 | 544 | ee.excelReplace(list, new Object[] { scheduleRealInfos.get(0),map }, path+"mould\\waybill_minhang.xls", |
| 576 | - path+"export\\" + jName + ".xls"); | |
| 545 | + path+"export\\" + date+"-"+jName+"-"+clZbh+"-"+lpName+"-行车路单.xls"); | |
| 577 | 546 | return scheduleRealInfos; |
| 578 | 547 | } |
| 579 | 548 | |
| 580 | - @Override | |
| 581 | - public List<Map<String, Object>> dailyInfo(String line, String date,String type) { | |
| 582 | - DecimalFormat format = new DecimalFormat("0.00"); | |
| 583 | - ReportUtils ee = new ReportUtils(); | |
| 584 | - List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 585 | - List<Map<String, Object>> list = scheduleRealInfoRepository.dailyInfo(line, date); | |
| 586 | - | |
| 587 | - double totalZGL = 0,totalKSGL=0,totalYH=0; | |
| 588 | - int totalBCS=0; | |
| 589 | - for(int i = 0;i < list.size();i++){ | |
| 590 | - String zgl = format.format(Double.parseDouble(list.get(i).get("zgl")==null?"0":list.get(i).get("zgl").toString())); | |
| 591 | - String ksgl = format.format(Double.parseDouble(list.get(i).get("ksgl")==null?"0":list.get(i).get("ksgl").toString())); | |
| 592 | - if(type.equals("export")){ | |
| 593 | - totalZGL += Double.parseDouble(zgl); | |
| 594 | - totalKSGL += Double.parseDouble(ksgl); | |
| 595 | - totalBCS += Integer.parseInt(list.get(i).get("bcs").toString()); | |
| 596 | - } | |
| 597 | - list.get(i).put("zgl", zgl); | |
| 598 | - list.get(i).put("ksgl", ksgl); | |
| 599 | - } | |
| 600 | - if(type.equals("export")){ | |
| 601 | - Map<String,Object> map = new HashMap<String, Object>(); | |
| 602 | - map.put("line", line); | |
| 603 | - map.put("date", date); | |
| 604 | - map.put("totalZGL", totalZGL); | |
| 605 | - map.put("totalKSGL", totalKSGL); | |
| 606 | - map.put("totalYH", totalYH); | |
| 607 | - map.put("totalBCS", totalBCS); | |
| 608 | - | |
| 609 | - String path = this.getClass().getResource("/").getPath()+"static\\pages\\forms\\"; | |
| 610 | - | |
| 611 | - listI.add(list.iterator()); | |
| 612 | - try { | |
| 613 | - ee.excelReplace(listI, new Object[] { map }, path+"mould\\daily.xls", | |
| 614 | - path+"export\\班次日报" + sdfSimple.format(sdfMonth.parse(date)) + ".xls"); | |
| 615 | - } catch (ParseException e) { | |
| 616 | - e.printStackTrace(); | |
| 617 | - } | |
| 618 | - } | |
| 619 | - return list; | |
| 620 | - } | |
| 621 | - | |
| 622 | - @Override | |
| 623 | - public List<Object[]> historyMessage(String line, String date, String code, String type) { | |
| 624 | - SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); | |
| 625 | - long d= 0; | |
| 626 | - long t=0; | |
| 627 | - if(date.length()>0){ | |
| 628 | - try { | |
| 629 | - d=sdf.parse(date+" 00:00:00").getTime(); | |
| 630 | - t=sdf.parse(date+" 23:59:59").getTime(); | |
| 631 | - } catch (ParseException e) { | |
| 632 | - // TODO Auto-generated catch block | |
| 633 | - e.printStackTrace(); | |
| 634 | - } | |
| 635 | - | |
| 636 | - } | |
| 637 | - | |
| 638 | - List<Object[]> list = scheduleRealInfoRepository.historyMessage(line,d,t, code); | |
| 639 | - for(Object[] obj:list){ | |
| 640 | - if(obj != null){ | |
| 641 | - obj[3] = sdf.format(new Date(Long.parseLong(obj[3].toString()))); | |
| 642 | - obj[4] = BasicData.lineCode2NameMap.get(line); | |
| 643 | - } | |
| 644 | - } | |
| 645 | - | |
| 646 | - if(type != null && type.length() != 0 && type.equals("export")){ | |
| 647 | - SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 648 | - sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 649 | - List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 650 | - Map<String,Object> m = new HashMap<String, Object>(); | |
| 651 | - ReportUtils ee = new ReportUtils(); | |
| 652 | - List<Map<String, Object>> newList = new ArrayList<Map<String, Object>>(); | |
| 653 | - for(int i = 0; i < list.size(); i++){ | |
| 654 | - Map<String, Object> map = new HashMap<String, Object>(); | |
| 655 | - Object[] obj = list.get(i); | |
| 656 | - map.put("num", i + 1); | |
| 657 | - map.put("line", obj[4]); | |
| 658 | - map.put("clZbh", obj[0]); | |
| 659 | - map.put("sender", obj[1]); | |
| 660 | - map.put("date", obj[3]); | |
| 661 | - map.put("text", obj[2]); | |
| 662 | - newList.add(map); | |
| 663 | - } | |
| 664 | - try { | |
| 665 | - listI.add(newList.iterator()); | |
| 666 | - String path = this.getClass().getResource("/").getPath()+"static\\pages\\forms\\"; | |
| 667 | - ee.excelReplace(listI, new Object[] { m }, path+"mould\\historyMessage.xls", | |
| 668 | - path+"export\\调度历史消息" + sdfSimple.format(sdfMonth.parse(date)) + ".xls"); | |
| 669 | - } catch (Exception e) { | |
| 670 | - // TODO: handle exception | |
| 671 | - e.printStackTrace(); | |
| 672 | - } | |
| 673 | - } | |
| 674 | - | |
| 675 | - return list; | |
| 676 | - } | |
| 677 | - | |
| 678 | - @Override | |
| 679 | - public Map<Integer, Integer> trustStatus(String lineStr) { | |
| 680 | - List<String> lineList = Lists.newArrayList(Splitter.on(',').trimResults().omitEmptyStrings().split(lineStr)); | |
| 681 | - | |
| 682 | - Map<Integer, Integer> map = new HashMap<>(); | |
| 549 | + @Override | |
| 550 | + public List<Map<String, Object>> dailyInfo(String line, String date, String type) { | |
| 551 | + DecimalFormat format = new DecimalFormat("0.00"); | |
| 552 | + ReportUtils ee = new ReportUtils(); | |
| 553 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 554 | + List<Map<String, Object>> list = scheduleRealInfoRepository.dailyInfo(line, date); | |
| 555 | + | |
| 556 | + double totalZGL = 0, totalKSGL = 0, totalYH = 0; | |
| 557 | + int totalBCS = 0; | |
| 558 | + for (int i = 0; i < list.size(); i++) { | |
| 559 | + String zgl = format.format(Double.parseDouble(list.get(i).get("zgl") == null ? "0" : list.get(i).get("zgl").toString())); | |
| 560 | + String ksgl = format.format(Double.parseDouble(list.get(i).get("ksgl") == null ? "0" : list.get(i).get("ksgl").toString())); | |
| 561 | + if (type.equals("export")) { | |
| 562 | + totalZGL += Double.parseDouble(zgl); | |
| 563 | + totalKSGL += Double.parseDouble(ksgl); | |
| 564 | + totalBCS += Integer.parseInt(list.get(i).get("bcs").toString()); | |
| 565 | + } | |
| 566 | + list.get(i).put("zgl", zgl); | |
| 567 | + list.get(i).put("ksgl", ksgl); | |
| 568 | + } | |
| 569 | + if (type.equals("export")) { | |
| 570 | + Map<String, Object> map = new HashMap<String, Object>(); | |
| 571 | + map.put("line", line); | |
| 572 | + map.put("date", date); | |
| 573 | + map.put("totalZGL", totalZGL); | |
| 574 | + map.put("totalKSGL", totalKSGL); | |
| 575 | + map.put("totalYH", totalYH); | |
| 576 | + map.put("totalBCS", totalBCS); | |
| 577 | + | |
| 578 | + String path = this.getClass().getResource("/").getPath() + "static\\pages\\forms\\"; | |
| 579 | + | |
| 580 | + listI.add(list.iterator()); | |
| 581 | + try { | |
| 582 | + ee.excelReplace(listI, new Object[]{map}, path + "mould\\daily.xls", | |
| 583 | + path + "export\\班次日报" + sdfSimple.format(sdfMonth.parse(date)) + ".xls"); | |
| 584 | + } catch (ParseException e) { | |
| 585 | + e.printStackTrace(); | |
| 586 | + } | |
| 587 | + } | |
| 588 | + return list; | |
| 589 | + } | |
| 590 | + | |
| 591 | + @Override | |
| 592 | + public List<Object[]> historyMessage(String line, String date, String code, String type) { | |
| 593 | + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); | |
| 594 | + long d = 0; | |
| 595 | + long t = 0; | |
| 596 | + if (date.length() > 0) { | |
| 597 | + try { | |
| 598 | + d = sdf.parse(date + " 00:00:00").getTime(); | |
| 599 | + t = sdf.parse(date + " 23:59:59").getTime(); | |
| 600 | + } catch (ParseException e) { | |
| 601 | + // TODO Auto-generated catch block | |
| 602 | + e.printStackTrace(); | |
| 603 | + } | |
| 604 | + | |
| 605 | + } | |
| 606 | + | |
| 607 | + List<Object[]> list = scheduleRealInfoRepository.historyMessage(line, d, t, code); | |
| 608 | + for (Object[] obj : list) { | |
| 609 | + if (obj != null) { | |
| 610 | + obj[3] = sdf.format(new Date(Long.parseLong(obj[3].toString()))); | |
| 611 | + obj[4] = BasicData.lineCode2NameMap.get(line); | |
| 612 | + } | |
| 613 | + } | |
| 614 | + | |
| 615 | + if (type != null && type.length() != 0 && type.equals("export")) { | |
| 616 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 617 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 618 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 619 | + Map<String, Object> m = new HashMap<String, Object>(); | |
| 620 | + ReportUtils ee = new ReportUtils(); | |
| 621 | + List<Map<String, Object>> newList = new ArrayList<Map<String, Object>>(); | |
| 622 | + for (int i = 0; i < list.size(); i++) { | |
| 623 | + Map<String, Object> map = new HashMap<String, Object>(); | |
| 624 | + Object[] obj = list.get(i); | |
| 625 | + map.put("num", i + 1); | |
| 626 | + map.put("line", obj[4]); | |
| 627 | + map.put("clZbh", obj[0]); | |
| 628 | + map.put("sender", obj[1]); | |
| 629 | + map.put("date", obj[3]); | |
| 630 | + map.put("text", obj[2]); | |
| 631 | + newList.add(map); | |
| 632 | + } | |
| 633 | + try { | |
| 634 | + listI.add(newList.iterator()); | |
| 635 | + String path = this.getClass().getResource("/").getPath() + "static\\pages\\forms\\"; | |
| 636 | + ee.excelReplace(listI, new Object[]{m}, path + "mould\\historyMessage.xls", | |
| 637 | + path + "export\\调度历史消息" + sdfSimple.format(sdfMonth.parse(date)) + ".xls"); | |
| 638 | + } catch (Exception e) { | |
| 639 | + // TODO: handle exception | |
| 640 | + e.printStackTrace(); | |
| 641 | + } | |
| 642 | + } | |
| 643 | + | |
| 644 | + if (type != null && type.length() != 0 && type.equals("export_msg")) { | |
| 645 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 646 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 647 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 648 | + Map<String, Object> m = new HashMap<String, Object>(); | |
| 649 | + ReportUtils ee = new ReportUtils(); | |
| 650 | + List<Map<String, Object>> newList = new ArrayList<Map<String, Object>>(); | |
| 651 | + for (int i = 0; i < list.size(); i++) { | |
| 652 | + Map<String, Object> map = new HashMap<String, Object>(); | |
| 653 | + Object[] obj = list.get(i); | |
| 654 | + map.put("num", i + 1); | |
| 655 | + map.put("line", obj[4]); | |
| 656 | + map.put("clZbh", obj[0]); | |
| 657 | + map.put("sender", obj[1]); | |
| 658 | + map.put("date", obj[3]); | |
| 659 | + map.put("text", obj[2]); | |
| 660 | + newList.add(map); | |
| 661 | + } | |
| 662 | + try { | |
| 663 | + listI.add(newList.iterator()); | |
| 664 | + String path = this.getClass().getResource("/").getPath() + "static\\pages\\forms\\"; | |
| 665 | + ee.excelReplace(listI, new Object[]{m}, path + "mould\\message.xls", | |
| 666 | + path + "export\\调度消息分析" + sdfSimple.format(sdfMonth.parse(date)) + ".xls"); | |
| 667 | + } catch (Exception e) { | |
| 668 | + // TODO: handle exception | |
| 669 | + e.printStackTrace(); | |
| 670 | + } | |
| 671 | + } | |
| 672 | + return list; | |
| 673 | + } | |
| 674 | + | |
| 675 | + @Override | |
| 676 | + public Map<Integer, Integer> trustStatus(String lineStr) { | |
| 677 | + List<String> lineList = Lists.newArrayList(Splitter.on(',').trimResults().omitEmptyStrings().split(lineStr)); | |
| 678 | + | |
| 679 | + Map<Integer, Integer> map = new HashMap<>(); | |
| 683 | 680 | /*Integer code; |
| 684 | 681 | for (String lineCode : lineList) { |
| 685 | 682 | code = Integer.parseInt(lineCode); |
| ... | ... | @@ -688,485 +685,1519 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 688 | 685 | |
| 689 | 686 | map.put(code, ScheduleBuffer.trustMap.get(code)); |
| 690 | 687 | }*/ |
| 691 | - return map; | |
| 692 | - } | |
| 693 | - | |
| 694 | - @Override | |
| 695 | - public Map<String, Object> realOutAdjust(Long id, String fcsjActual, String remarks) { | |
| 696 | - Map<String, Object> rs = new HashMap<>(); | |
| 697 | - List<ScheduleRealInfo> ts = new ArrayList<>(); | |
| 698 | - try { | |
| 699 | - ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 700 | - | |
| 701 | - LineConfig config = lineConfigData.get(sch.getXlBm()); | |
| 702 | - //小于线路开始运营时间,则默认跨过24点 | |
| 703 | - if(fcsjActual.compareTo(config.getStartOpt()) < 0){ | |
| 704 | - sch.setRealExecDate(fmtyyyyMMdd.print(sch.getScheduleDate().getTime() + DAY_TIME)); | |
| 705 | - } | |
| 706 | - else { | |
| 707 | - sch.setRealExecDate(sch.getScheduleDateStr()); | |
| 688 | + return map; | |
| 689 | + } | |
| 690 | + | |
| 691 | + @Override | |
| 692 | + public Map<String, Object> realOutAdjust(Long id, String fcsjActual, String remarks) { | |
| 693 | + Map<String, Object> rs = new HashMap<>(); | |
| 694 | + List<ScheduleRealInfo> ts = new ArrayList<>(); | |
| 695 | + try { | |
| 696 | + ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 697 | + | |
| 698 | + LineConfig config = lineConfigData.get(sch.getXlBm()); | |
| 699 | + //小于线路开始运营时间,则默认跨过24点 | |
| 700 | + if (fcsjActual.compareTo(config.getStartOpt()) < 0) { | |
| 701 | + sch.setRealExecDate(fmtyyyyMMdd.print(sch.getScheduleDate().getTime() + DAY_TIME)); | |
| 702 | + } else { | |
| 703 | + sch.setRealExecDate(sch.getScheduleDateStr()); | |
| 704 | + } | |
| 705 | + | |
| 706 | + sch.setFcsjActualAll(fcsjActual); | |
| 707 | + sch.addRemarks(remarks); | |
| 708 | + sch.calcStatus(); | |
| 709 | + | |
| 710 | + dayOfSchedule.save(sch); | |
| 711 | + //scheduleRealInfoRepository.save(sch); | |
| 712 | + | |
| 713 | + ts.add(sch); | |
| 714 | + | |
| 715 | + rs.put("status", ResponseCode.SUCCESS); | |
| 716 | + rs.put("ts", ts); | |
| 717 | + | |
| 718 | + //通知页面刷新 | |
| 719 | + sendUtils.refreshSch(ts); | |
| 720 | + } catch (Exception e) { | |
| 721 | + logger.error("", e); | |
| 722 | + rs.put("status", ResponseCode.ERROR); | |
| 723 | + } | |
| 724 | + | |
| 725 | + return rs; | |
| 726 | + } | |
| 727 | + | |
| 728 | + @Override | |
| 729 | + public Map<String, Object> revokeDestroy(Long id) { | |
| 730 | + Map<String, Object> rs = new HashMap<>(); | |
| 731 | + try { | |
| 732 | + ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 733 | + if (sch.getStatus() != -1) { | |
| 734 | + rs.put("status", ResponseCode.ERROR); | |
| 735 | + rs.put("msg", "未烂班,无法撤销!"); | |
| 736 | + } else { | |
| 737 | + sch.setStatus(0); | |
| 738 | + rs.put("status", ResponseCode.SUCCESS); | |
| 739 | + rs.put("t", sch); | |
| 740 | + | |
| 741 | + } | |
| 742 | + } catch (Exception e) { | |
| 743 | + logger.error("", e); | |
| 744 | + rs.put("status", ResponseCode.ERROR); | |
| 745 | + } | |
| 746 | + return rs; | |
| 747 | + } | |
| 748 | + | |
| 749 | + @Override | |
| 750 | + public Map<String, Object> revokeRealOutgo(Long id) { | |
| 751 | + Map<String, Object> rs = new HashMap<>(); | |
| 752 | + List<ScheduleRealInfo> ts = new ArrayList<>(); | |
| 753 | + | |
| 754 | + try { | |
| 755 | + ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 756 | + if (sch.getFcsjActual() == null) { | |
| 757 | + rs.put("status", ResponseCode.ERROR); | |
| 758 | + rs.put("msg", "无实发时间,无法撤销!"); | |
| 759 | + } else { | |
| 760 | + //将对应的到离站数据标记为不可信 | |
| 761 | + List<ArrivalEntity> list = ArrivalData_GPS.findByNbbm(sch.getClZbh()); | |
| 762 | + for (ArrivalEntity arr : list) { | |
| 763 | + if (arr.getInOut() == 1 | |
| 764 | + && arr.getUpDown() == Integer.parseInt(sch.getXlDir()) | |
| 765 | + && arr.getStopNo().equals(sch.getQdzCode()) | |
| 766 | + && Math.abs(arr.getTs() - sch.getFcsjActualTime()) < 1000 * 60) { | |
| 767 | + arr.setEnable(false); | |
| 768 | + break; | |
| 769 | + } | |
| 770 | + } | |
| 771 | + | |
| 772 | + sch.clearFcsjActual(); | |
| 773 | + rs.put("status", ResponseCode.SUCCESS); | |
| 774 | + | |
| 775 | + ts.add(sch); | |
| 776 | + rs.put("ts", ts); | |
| 777 | + | |
| 778 | + } | |
| 779 | + } catch (Exception e) { | |
| 780 | + logger.error("", e); | |
| 781 | + rs.put("status", ResponseCode.ERROR); | |
| 782 | + } | |
| 783 | + return rs; | |
| 784 | + } | |
| 785 | + | |
| 786 | + @Override | |
| 787 | + public Map<String, Object> spaceAdjust(Long[] ids, Integer space) { | |
| 788 | + | |
| 789 | + List<ScheduleRealInfo> list = new ArrayList<>(), updateList = new ArrayList<>(); | |
| 790 | + Map<String, Object> rs = new HashMap<>(); | |
| 791 | + try { | |
| 792 | + ScheduleRealInfo sch, next; | |
| 793 | + for (Long id : ids) { | |
| 794 | + sch = dayOfSchedule.get(id); | |
| 795 | + if (null != sch) | |
| 796 | + list.add(sch); | |
| 797 | + } | |
| 798 | + | |
| 799 | + int size = list.size(); | |
| 800 | + if (size == 0) { | |
| 801 | + rs.put("status", ResponseCode.ERROR); | |
| 802 | + } else { | |
| 803 | + // 按发车时间排序 | |
| 804 | + Collections.sort(list, new ScheduleComparator.FCSJ()); | |
| 805 | + | |
| 806 | + // 以第一个实际发车/待发时间为起点,调整间隔 | |
| 807 | + sch = list.get(0); | |
| 808 | + Long st = sch.getFcsjActualTime() == null ? sch.getDfsjT() : sch.getFcsjActualTime(), plus = space * 60 * 1000L; | |
| 809 | + | |
| 810 | + for (int i = 1; i < size; i++) { | |
| 811 | + st += plus; | |
| 812 | + sch = list.get(i); | |
| 813 | + sch.setDfsjAll(st); | |
| 814 | + //重新计算终点时间 | |
| 815 | + sch.calcEndTime(); | |
| 816 | + | |
| 817 | + dayOfSchedule.save(sch); | |
| 818 | + | |
| 819 | + updateList.add(sch); | |
| 820 | + next = dayOfSchedule.next(sch); | |
| 821 | + if (next.getQdzName().equals(sch.getZdzName())) { | |
| 822 | + next.setQdzArrDateJH(sch.getZdsj()); | |
| 823 | + updateList.add(next); | |
| 824 | + } | |
| 825 | + } | |
| 826 | + | |
| 827 | + | |
| 828 | + rs.put("status", ResponseCode.SUCCESS); | |
| 829 | + rs.put("ts", updateList); | |
| 830 | + } | |
| 831 | + | |
| 832 | + } catch (Exception e) { | |
| 833 | + logger.error("", e); | |
| 834 | + rs.put("status", ResponseCode.ERROR); | |
| 835 | + } | |
| 836 | + return rs; | |
| 837 | + } | |
| 838 | + | |
| 839 | + private static DateTimeFormatter fmtyyyyMMddHHmm = DateTimeFormat.forPattern("yyyy-MM-ddHH:mm"); | |
| 840 | + | |
| 841 | + @Override | |
| 842 | + public Map<String, Object> schInfoFineTune(Map<String, String> map) { | |
| 843 | + Map<String, Object> rs = new HashMap<>(); | |
| 844 | + List<ScheduleRealInfo> ts = new ArrayList<>(); | |
| 845 | + try { | |
| 846 | + Long id = Long.parseLong(map.get("id")); | |
| 847 | + //班次类型 | |
| 848 | + //String bcType = map.get("bcType"); | |
| 849 | + //车辆自编号 | |
| 850 | + //String clZbh = map.get("clZbh"); | |
| 851 | + //计划发车时间 | |
| 852 | + //String fcsj = map.get("fcsj"); | |
| 853 | + //实际发车时间 | |
| 854 | + String fcsjActual = map.get("fcsjActual"); | |
| 855 | + //实际终点时间 | |
| 856 | + String zdsjActual = map.get("zdsjActual"); | |
| 857 | + //备注 | |
| 858 | + String remarks = map.get("remarks"); | |
| 859 | + ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 860 | + if (null != sch) { | |
| 861 | + if (StringUtils.isNotBlank(fcsjActual)) { | |
| 862 | + LineConfig config = lineConfigData.get(sch.getXlBm()); | |
| 863 | + long t = 0L; | |
| 864 | + //小于线路开始运营时间,则默认跨过24点 | |
| 865 | + if (fcsjActual.compareTo(config.getStartOpt()) < 0) | |
| 866 | + t = fmtyyyyMMddHHmm.parseMillis(fmtyyyyMMdd.print(sch.getScheduleDate().getTime() + DAY_TIME) + fcsjActual); | |
| 867 | + else | |
| 868 | + t = fmtyyyyMMddHHmm.parseMillis(sch.getScheduleDateStr() + fcsjActual); | |
| 869 | + | |
| 870 | + //调整实发 | |
| 871 | + if (!fcsjActual.equals(sch.getFcsjActual())) | |
| 872 | + sch.setFcsjActualAll(t); | |
| 873 | + } else { | |
| 874 | + //撤销实发 | |
| 875 | + if (sch.getFcsjActual() != null) | |
| 876 | + revokeRealOutgo(sch.getId()); | |
| 877 | + } | |
| 878 | + //实达时间 | |
| 879 | + if (StringUtils.isNotBlank(zdsjActual)) { | |
| 880 | + if (!zdsjActual.equals(sch.getZdsjActual())) { | |
| 881 | + //调整实达 | |
| 882 | + sch.setZdsjActualAll(zdsjActual); | |
| 883 | + //下一班次起点到达时间 | |
| 884 | + ScheduleRealInfo next = dayOfSchedule.next(sch); | |
| 885 | + if (null != next) { | |
| 886 | + next.setQdzArrDateSJ(zdsjActual); | |
| 887 | + ts.add(next); | |
| 888 | + } | |
| 889 | + | |
| 890 | + //重新计算车辆执行班次 | |
| 891 | + dayOfSchedule.reCalcExecPlan(sch.getClZbh()); | |
| 892 | + } | |
| 893 | + } else { | |
| 894 | + //清除实达时间 | |
| 895 | + sch.clearZdsjActual(); | |
| 896 | + //清除下一班次起点到达时间 | |
| 897 | + ScheduleRealInfo next = dayOfSchedule.next(sch); | |
| 898 | + if (null != next) { | |
| 899 | + next.setQdzArrDateSJ(null); | |
| 900 | + ts.add(next); | |
| 901 | + } | |
| 902 | + } | |
| 903 | + sch.setRemarks(remarks); | |
| 904 | + | |
| 905 | + try { | |
| 906 | + //烂班 | |
| 907 | + if(map.get("status") != null | |
| 908 | + && Integer.parseInt(map.get("status").toString()) == -1){ | |
| 909 | + destroy(sch.getId() + "", "", map.get("adjustExps").toString()); | |
| 910 | + } | |
| 911 | + } catch (NumberFormatException e) { | |
| 912 | + logger.error("", e); | |
| 913 | + } | |
| 914 | + } | |
| 915 | + | |
| 916 | + String bcType = map.get("bcType"); | |
| 917 | + if(StringUtils.isNotEmpty(bcType)){ | |
| 918 | + sch.setBcType(bcType); | |
| 919 | + } | |
| 920 | + //班次状态 | |
| 921 | + sch.calcStatus(); | |
| 922 | + dayOfSchedule.save(sch); | |
| 923 | + //页面需要更新的班次信息 | |
| 924 | + ts.add(sch); | |
| 925 | + | |
| 926 | + rs.put("status", ResponseCode.SUCCESS); | |
| 927 | + rs.put("ts", ts); | |
| 928 | + } catch (Exception e) { | |
| 929 | + logger.error("", e); | |
| 930 | + rs.put("status", ResponseCode.ERROR); | |
| 931 | + } | |
| 932 | + return rs; | |
| 933 | + } | |
| 934 | + | |
| 935 | + @Override | |
| 936 | + public Map<String, Object> outgoAdjustAll(String params) { | |
| 937 | + Map<String, Object> rs = new HashMap<>(); | |
| 938 | + try { | |
| 939 | + JSONArray jsonArray = JSONArray.parseArray(params); | |
| 940 | + | |
| 941 | + ScheduleRealInfo schedule = null; | |
| 942 | + JSONObject jsonObj; | |
| 943 | + String dfsj; | |
| 944 | + for (int i = 0; i < jsonArray.size(); i++) { | |
| 945 | + jsonObj = jsonArray.getJSONObject(i); | |
| 946 | + dfsj = jsonObj.getString("t"); | |
| 947 | + schedule = dayOfSchedule.get(jsonObj.getLong("id")); | |
| 948 | + //设置待发时间 | |
| 949 | + schedule.setDfsjAll(dfsj); | |
| 950 | + | |
| 951 | + dayOfSchedule.save(schedule); | |
| 952 | + } | |
| 953 | + | |
| 954 | + rs.put("status", ResponseCode.SUCCESS); | |
| 955 | + //将更新的最后一个班次返回 | |
| 956 | + rs.put("t", schedule); | |
| 957 | + } catch (Exception e) { | |
| 958 | + logger.error("", e); | |
| 959 | + rs.put("status", ResponseCode.ERROR); | |
| 960 | + } | |
| 961 | + return rs; | |
| 962 | + } | |
| 963 | + | |
| 964 | + @Override | |
| 965 | + public Map<String, Object> findRouteByLine(String lineCode) { | |
| 966 | + Map<String, Object> map = new HashMap<>(); | |
| 967 | + //上行 | |
| 968 | + Integer lineId = BasicData.lineId2CodeMap.inverse().get(lineCode); | |
| 969 | + map.put("line.id_eq", lineId); | |
| 970 | + map.put("directions_eq", 0); | |
| 971 | + List<Map<String, Object>> upList = sectionRouteService.getSectionRoute(map); | |
| 972 | + | |
| 973 | + //下行 | |
| 974 | + map.put("directions_eq", 1); | |
| 975 | + List<Map<String, Object>> downList = sectionRouteService.getSectionRoute(map); | |
| 976 | + | |
| 977 | + Map<String, Object> rs = new HashMap<>(); | |
| 978 | + | |
| 979 | + String upVectors = "", vec; | |
| 980 | + //拼接上行路段 | |
| 981 | + for (Map<String, Object> temp : upList) { | |
| 982 | + vec = temp.get("sectionBsectionVector").toString(); | |
| 983 | + upVectors += vec.subSequence(11, vec.length() - 2) + " "; | |
| 984 | + } | |
| 985 | + | |
| 986 | + //拼接下行路段 | |
| 987 | + String downVectors = ""; | |
| 988 | + for (Map<String, Object> temp : downList) {//LINESTRING( | |
| 989 | + vec = temp.get("sectionBsectionVector").toString(); | |
| 990 | + downVectors += vec.subSequence(11, vec.length() - 2) + " "; | |
| 991 | + } | |
| 992 | + | |
| 993 | + | |
| 994 | + rs.put("up", upVectors); | |
| 995 | + //上行gcj | |
| 996 | + rs.put("up_gcj", BdToGcjString(upVectors)); | |
| 997 | + rs.put("down", downVectors); | |
| 998 | + //下行gcj | |
| 999 | + rs.put("down_gcj", BdToGcjString(downVectors)); | |
| 1000 | + rs.put("lineId", lineId); | |
| 1001 | + | |
| 1002 | + return rs; | |
| 1003 | + } | |
| 1004 | + | |
| 1005 | + /** | |
| 1006 | + * @param @param bdStr | |
| 1007 | + * @throws | |
| 1008 | + * @Title: BdToGcjString | |
| 1009 | + * @Description: TODO(将百度路由字符串 转 成GCJ 字符串) | |
| 1010 | + */ | |
| 1011 | + public String BdToGcjString(String bdStr) { | |
| 1012 | + String[] array = bdStr.split(","), subArray; | |
| 1013 | + if (array.length == 0 || bdStr.length() < 2) | |
| 1014 | + return ""; | |
| 1015 | + | |
| 1016 | + String gcjStr = ""; | |
| 1017 | + TransGPS.Location location; | |
| 1018 | + for (String crd : array) { | |
| 1019 | + subArray = crd.split(" "); | |
| 1020 | + if (subArray.length != 2) | |
| 1021 | + continue; | |
| 1022 | + location = TransGPS.bd_decrypt(TransGPS.LocationMake(Double.parseDouble(subArray[0]), Double.parseDouble(subArray[1]))); | |
| 1023 | + | |
| 1024 | + gcjStr += location.getLng() + " " + location.getLat() + ","; | |
| 1025 | + } | |
| 1026 | + | |
| 1027 | + return gcjStr.substring(0, gcjStr.length() - 1); | |
| 1028 | + } | |
| 1029 | + | |
| 1030 | + public List<Map<String, String>> findLine(String line) { | |
| 1031 | + List<Line> listLine = lineRepository.findLine("%" + line + "%"); | |
| 1032 | + List<Map<String, String>> list = new ArrayList<Map<String, String>>(); | |
| 1033 | + Map<String, String> map; | |
| 1034 | + for (Line temp : listLine) { | |
| 1035 | + if (temp != null) { | |
| 1036 | + String xlName = temp.getName(); | |
| 1037 | + if (xlName.indexOf(line) != -1) { | |
| 1038 | + map = new HashMap<String, String>(); | |
| 1039 | + map.put("id", temp.getLineCode()); | |
| 1040 | + map.put("text", xlName); | |
| 1041 | + list.add(map); | |
| 1042 | + } | |
| 1043 | + } | |
| 1044 | + } | |
| 1045 | + return list; | |
| 1046 | + } | |
| 1047 | + | |
| 1048 | + public List<Map<String, String>> findLpName(String lpName) { | |
| 1049 | + List<GuideboardInfo> listLpName = guideboardInfoRepository.findLpName("%" + lpName + "%"); | |
| 1050 | + List<Map<String, String>> list = new ArrayList<Map<String, String>>(); | |
| 1051 | + Map<String, String> map; | |
| 1052 | + for (GuideboardInfo temp : listLpName) { | |
| 1053 | + if (temp != null) { | |
| 1054 | + String lp = temp.getLpName(); | |
| 1055 | + if (lp.indexOf(lpName) != -1) { | |
| 1056 | + map = new HashMap<String, String>(); | |
| 1057 | + map.put("id", lp); | |
| 1058 | + map.put("text", lp); | |
| 1059 | + list.add(map); | |
| 1060 | + } | |
| 1061 | + } | |
| 1062 | + } | |
| 1063 | + return list; | |
| 1064 | + } | |
| 1065 | + | |
| 1066 | + @Override | |
| 1067 | + public Map<String, Object> findKMBC2(String jName, String clZbh, String date) { | |
| 1068 | + List<ScheduleRealInfo> list = scheduleRealInfoRepository.queryListWaybill3(jName, clZbh, date); | |
| 1069 | + | |
| 1070 | + DecimalFormat format = new DecimalFormat("0.00"); | |
| 1071 | +// int cjbc = scheduleRealInfoRepository.findCjbc(jName, clZbh, lpName); | |
| 1072 | +// int ljbc = scheduleRealInfoRepository.findLjbc(jName, clZbh, lpName); | |
| 1073 | + int jhbc = 0, cjbc = 0, ljbc = 0; | |
| 1074 | + double jhlc = 0, yygl = 0, ksgl = 0, tempJhlc = 0; | |
| 1075 | + float addMileage = 0l, remMileage = 0l; | |
| 1076 | + String j_Name = ""; | |
| 1077 | + Map<String, Object> map = new HashMap<String, Object>(); | |
| 1078 | + for (ScheduleRealInfo scheduleRealInfo : list) { | |
| 1079 | + if (scheduleRealInfo != null) { | |
| 1080 | + j_Name = scheduleRealInfo.getjName(); | |
| 1081 | + //计划里程(主任务过滤掉临加班次), | |
| 1082 | + //烂班里程(主任务烂班), | |
| 1083 | + //临加里程(主任务临加), | |
| 1084 | + //计划班次,烂班班次,增加班次 | |
| 1085 | + tempJhlc = scheduleRealInfo.getJhlc() == null ? 0 : scheduleRealInfo.getJhlc(); | |
| 1086 | + if (scheduleRealInfo.isSflj()) { | |
| 1087 | + addMileage += tempJhlc; | |
| 1088 | + ljbc++; | |
| 1089 | + } else { | |
| 1090 | + jhlc += tempJhlc; | |
| 1091 | + jhbc++; | |
| 1092 | + if (scheduleRealInfo.getStatus() == -1) { | |
| 1093 | + remMileage += tempJhlc; | |
| 1094 | + cjbc++; | |
| 1095 | + } | |
| 1096 | + } | |
| 1097 | + Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1098 | + //计算营运里程,空驶里程 | |
| 1099 | + if (childTaskPlans.isEmpty()) { | |
| 1100 | + if (scheduleRealInfo.getBcType().equals("in") || scheduleRealInfo.getBcType().equals("out") | |
| 1101 | + || scheduleRealInfo.getBcType().equals("venting")) { | |
| 1102 | + ksgl += tempJhlc; | |
| 1103 | + } else { | |
| 1104 | + yygl += tempJhlc; | |
| 1105 | + } | |
| 1106 | + } else { | |
| 1107 | + Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1108 | + while (it.hasNext()) { | |
| 1109 | + ChildTaskPlan childTaskPlan = it.next(); | |
| 1110 | + if (childTaskPlan.getMileageType().equals("empty")) { | |
| 1111 | + ksgl += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1112 | + } else { | |
| 1113 | + yygl += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1114 | + } | |
| 1115 | + } | |
| 1116 | + } | |
| 1117 | + } | |
| 1118 | + } | |
| 1119 | + map.put("j_name", j_Name); | |
| 1120 | + map.put("jhlc", format.format(jhlc)); | |
| 1121 | + map.put("remMileage", format.format(remMileage)); | |
| 1122 | + map.put("addMileage", format.format(addMileage)); | |
| 1123 | + map.put("yygl", format.format(yygl)); | |
| 1124 | + map.put("ksgl", format.format(ksgl)); | |
| 1125 | + map.put("realMileage", format.format(yygl + ksgl)); | |
| 1126 | + map.put("jhbc", jhbc); | |
| 1127 | + map.put("cjbc", cjbc); | |
| 1128 | + map.put("ljbc", ljbc); | |
| 1129 | + map.put("sjbc", jhbc - cjbc + ljbc); | |
| 1130 | + return map; | |
| 1131 | + } | |
| 1132 | + | |
| 1133 | + | |
| 1134 | + | |
| 1135 | + @Override | |
| 1136 | + public Map<String, Object> findKMBC(String jName, String clZbh, | |
| 1137 | + String lpName, String date,String line) { | |
| 1138 | + List<ScheduleRealInfo> list = scheduleRealInfoRepository.queryListWaybill(jName, clZbh, lpName, date,line); | |
| 1139 | + DecimalFormat format = new DecimalFormat("0.00"); | |
| 1140 | +// int cjbc = scheduleRealInfoRepository.findCjbc(jName, clZbh, lpName); | |
| 1141 | +// int ljbc = scheduleRealInfoRepository.findLjbc(jName, clZbh, lpName); | |
| 1142 | + int jhbc = 0, cjbc = 0, ljbc = 0; | |
| 1143 | + double jhlc = 0, yygl = 0, ksgl = 0, tempJhlc = 0, jcclc = 0; | |
| 1144 | + float addMileage = 0l, remMileage = 0l; | |
| 1145 | + Map<String, Object> map = new HashMap<String, Object>(); | |
| 1146 | + for (ScheduleRealInfo scheduleRealInfo : list) { | |
| 1147 | + if (scheduleRealInfo != null) { | |
| 1148 | + //计划里程(主任务过滤掉临加班次), | |
| 1149 | + //烂班里程(主任务烂班), | |
| 1150 | + //临加里程(主任务临加), | |
| 1151 | + //计划班次,烂班班次,增加班次 | |
| 1152 | + tempJhlc = scheduleRealInfo.getJhlc() == null ? 0 : scheduleRealInfo.getJhlc(); | |
| 1153 | + if (scheduleRealInfo.isSflj()) { | |
| 1154 | + addMileage += tempJhlc; | |
| 1155 | + ljbc++; | |
| 1156 | + } else { | |
| 1157 | + if (!(scheduleRealInfo.getBcType().equals("in") | |
| 1158 | + || scheduleRealInfo.getBcType().equals("out"))) { | |
| 1159 | + jhbc++; | |
| 1160 | + jhlc += tempJhlc; | |
| 1161 | + } | |
| 1162 | + | |
| 1163 | + if (scheduleRealInfo.getStatus() == -1) { | |
| 1164 | + remMileage += tempJhlc; | |
| 1165 | + cjbc++; | |
| 1166 | + } | |
| 1167 | + } | |
| 1168 | + Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1169 | + //计算营运里程,空驶里程 | |
| 1170 | + if (childTaskPlans.isEmpty()) { | |
| 1171 | + if (scheduleRealInfo.getBcType().equals("in") || | |
| 1172 | + scheduleRealInfo.getBcType().equals("out")) { | |
| 1173 | + jcclc += tempJhlc; | |
| 1174 | + } | |
| 1175 | + //主任务 放空班次属于营运 | |
| 1176 | +// else if(scheduleRealInfo.getBcType().equals("venting")){ | |
| 1177 | +// ksgl += tempJhlc; | |
| 1178 | +// } | |
| 1179 | + else { | |
| 1180 | + if (scheduleRealInfo.getStatus() != -1) { | |
| 1181 | + yygl += tempJhlc; | |
| 1182 | + } | |
| 1183 | + } | |
| 1184 | + } else { | |
| 1185 | + Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1186 | + while (it.hasNext()) { | |
| 1187 | + ChildTaskPlan childTaskPlan = it.next(); | |
| 1188 | + if (childTaskPlan.getMileageType().equals("empty")) { | |
| 1189 | + if (childTaskPlan.isDestroy()) { | |
| 1190 | + remMileage += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1191 | + } else { | |
| 1192 | + ksgl += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1193 | + } | |
| 1194 | + } else { | |
| 1195 | + if (childTaskPlan.isDestroy()) { | |
| 1196 | + remMileage += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1197 | +// cjbc++; | |
| 1198 | + } else { | |
| 1199 | + yygl += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1200 | + } | |
| 1201 | + } | |
| 1202 | + } | |
| 1203 | + } | |
| 1204 | + } | |
| 1205 | + } | |
| 1206 | + map.put("jhlc", format.format(jhlc)); | |
| 1207 | + map.put("remMileage", format.format(remMileage)); | |
| 1208 | + map.put("addMileage", format.format(addMileage)); | |
| 1209 | + map.put("yygl", format.format(yygl)); | |
| 1210 | + map.put("ksgl", format.format(ksgl)); | |
| 1211 | + map.put("realMileage", format.format(yygl + ksgl + jcclc)); | |
| 1212 | + map.put("jhbc", jhbc); | |
| 1213 | + map.put("cjbc", cjbc); | |
| 1214 | + map.put("ljbc", ljbc); | |
| 1215 | + map.put("sjbc", jhbc - cjbc + ljbc); | |
| 1216 | + map.put("jcclc", jcclc); | |
| 1217 | + map.put("zkslc", format.format(ksgl + jcclc)); | |
| 1218 | + return map; | |
| 1219 | + } | |
| 1220 | + | |
| 1221 | + | |
| 1222 | + @Override | |
| 1223 | + public List<Map<String, Object>> account(String line, String date, | |
| 1224 | + String code, String xlName, String type) { | |
| 1225 | + List<Object[]> lsitObj = scheduleRealInfoRepository.account(line, date, code); | |
| 1226 | + List<Map<String, Object>> listMap = new ArrayList<Map<String, Object>>(); | |
| 1227 | + Map<String, Object> map; | |
| 1228 | + int i = 1; | |
| 1229 | + for (Object[] obj : lsitObj) { | |
| 1230 | + if (obj != null) { | |
| 1231 | + map = new HashMap<String, Object>(); | |
| 1232 | + map.put("num", i++); | |
| 1233 | + map.put("xlName", xlName); | |
| 1234 | + map.put("clZbh", obj[3]); | |
| 1235 | + map.put("company", obj[0]); | |
| 1236 | + map.put("requestType", "0x" + Integer.toHexString(Integer.parseInt(obj[1] + "")).toUpperCase()); | |
| 1237 | + map.put("requestTime", obj[2]); | |
| 1238 | + listMap.add(map); | |
| 1239 | + } | |
| 1240 | + } | |
| 1241 | + | |
| 1242 | + if (type != null && type.length() != 0 && type.equals("export")) { | |
| 1243 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 1244 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 1245 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 1246 | + Map<String, Object> m = new HashMap<String, Object>(); | |
| 1247 | + ReportUtils ee = new ReportUtils(); | |
| 1248 | + Map<String, Object> typeMap = new HashMap<String, Object>(); | |
| 1249 | + typeMap.put("0xA1", "请求恢复运营"); | |
| 1250 | + typeMap.put("0xA2", "申请调档"); | |
| 1251 | + typeMap.put("0xA3", "出场请求"); | |
| 1252 | + typeMap.put("0xA5", "进场请求"); | |
| 1253 | + typeMap.put("0xA7", "加油请求"); | |
| 1254 | + typeMap.put("0x50", "车辆故障"); | |
| 1255 | + typeMap.put("0x70", "路阻报告"); | |
| 1256 | + typeMap.put("0x60", "事故报告"); | |
| 1257 | + typeMap.put("0x11", "扣证纠纷"); | |
| 1258 | + typeMap.put("0x12", "报警"); | |
| 1259 | + for (Map<String, Object> map1 : listMap) { | |
| 1260 | + map1.put("requestText", typeMap.get(map1.get("requestType"))); | |
| 1261 | + } | |
| 1262 | + try { | |
| 1263 | + listI.add(listMap.iterator()); | |
| 1264 | + String path = this.getClass().getResource("/").getPath() + "static\\pages\\forms\\"; | |
| 1265 | + ee.excelReplace(listI, new Object[]{m}, path + "mould\\account.xls", | |
| 1266 | + path + "export\\驾驶员请求台账" + sdfSimple.format(sdfMonth.parse(date)) + ".xls"); | |
| 1267 | + } catch (Exception e) { | |
| 1268 | + // TODO: handle exception | |
| 1269 | + e.printStackTrace(); | |
| 1270 | + } | |
| 1271 | + } | |
| 1272 | + | |
| 1273 | + return listMap; | |
| 1274 | + } | |
| 1275 | + | |
| 1276 | + @Override | |
| 1277 | + public List<ScheduleRealInfo> correctForm(String line, String startDate, | |
| 1278 | + String endDate, String lpName, String code, String type) { | |
| 1279 | + List<ScheduleRealInfo> list = scheduleRealInfoRepository.correctForm(line, startDate, endDate, lpName, code); | |
| 1280 | + | |
| 1281 | + if (type != null && type.length() != 0 && type.equals("export")) { | |
| 1282 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 1283 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 1284 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 1285 | + Map<String, Object> m = new HashMap<String, Object>(); | |
| 1286 | + ReportUtils ee = new ReportUtils(); | |
| 1287 | + m.put("dates", startDate + " 至 " + endDate); | |
| 1288 | + List<Map<String, Object>> tempList = new ArrayList<Map<String, Object>>(); | |
| 1289 | + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); | |
| 1290 | + for (ScheduleRealInfo schedule : list) { | |
| 1291 | + Map<String, Object> tempMap = new HashMap<String, Object>(); | |
| 1292 | + tempMap.put("xlName", schedule.getXlName() != null ? schedule.getXlName() : ""); | |
| 1293 | + tempMap.put("lpName", schedule.getLpName() != null ? schedule.getLpName() : ""); | |
| 1294 | + tempMap.put("clZbh", schedule.getClZbh() != null ? schedule.getClZbh() : ""); | |
| 1295 | + tempMap.put("jName", schedule.getjName() != null ? schedule.getjName() : ""); | |
| 1296 | + tempMap.put("sName", schedule.getsName() != null ? schedule.getsName() : ""); | |
| 1297 | + tempMap.put("fcsj", schedule.getFcsj() != null ? schedule.getFcsj() : ""); | |
| 1298 | + tempMap.put("fcsjActual", schedule.getFcsjActual() != null ? schedule.getFcsjActual() : ""); | |
| 1299 | + tempMap.put("zdsj", schedule.getZdsj() != null ? schedule.getZdsj() : ""); | |
| 1300 | + tempMap.put("zdsjActual", schedule.getZdsjActual() != null ? schedule.getZdsjActual() : ""); | |
| 1301 | + if (schedule.getUpdateBy() != null) { | |
| 1302 | + if (schedule.getUpdateBy().getName() != null) | |
| 1303 | + tempMap.put("userName", schedule.getUpdateBy().getName()); | |
| 1304 | + else | |
| 1305 | + tempMap.put("userName", ""); | |
| 1306 | + } else { | |
| 1307 | + tempMap.put("userName", ""); | |
| 1308 | + } | |
| 1309 | + if (schedule.getUpdateDate() != null) { | |
| 1310 | + tempMap.put("updateDate", sdf.format(schedule.getUpdateDate())); | |
| 1311 | + } else { | |
| 1312 | + tempMap.put("updateDate", ""); | |
| 1313 | + } | |
| 1314 | + tempMap.put("remarks", schedule.getRemarks() != null ? schedule.getRemarks() : ""); | |
| 1315 | + tempList.add(tempMap); | |
| 1316 | + } | |
| 1317 | + try { | |
| 1318 | + listI.add(tempList.iterator()); | |
| 1319 | + String path = this.getClass().getResource("/").getPath() + "static\\pages\\forms\\"; | |
| 1320 | + ee.excelReplace(listI, new Object[]{m}, path + "mould\\correctForm.xls", | |
| 1321 | + path + "export\\修正报表" + sdfSimple.format(sdfMonth.parse(startDate)) + "-" + sdfSimple.format(sdfMonth.parse(endDate)) + ".xls"); | |
| 1322 | + } catch (Exception e) { | |
| 1323 | + // TODO: handle exception | |
| 1324 | + e.printStackTrace(); | |
| 1325 | + } | |
| 1326 | + Map<String, Object> map = tempList.get(tempList.size() - 1); | |
| 1327 | + System.out.println("tempMap:" + map); | |
| 1328 | + } | |
| 1329 | + | |
| 1330 | + return list; | |
| 1331 | + } | |
| 1332 | + | |
| 1333 | + @Override | |
| 1334 | + public List<ScheduleRealInfo> queryListWaybill(String jName, String clZbh, | |
| 1335 | + String lpName, String date,String line) { | |
| 1336 | + List<ScheduleRealInfo> list = null; | |
| 1337 | + list = scheduleRealInfoRepository.queryListWaybill(jName, clZbh, lpName, date,line); | |
| 1338 | + for (int i = 0; i < list.size(); i++) { | |
| 1339 | + ScheduleRealInfo s = list.get(i); | |
| 1340 | + String remarks = ""; | |
| 1341 | + if (s.getRemarks() != null) { | |
| 1342 | + remarks += s.getRemarks(); | |
| 1343 | + } | |
| 1344 | + Set<ChildTaskPlan> childTaskPlans = s.getcTasks(); | |
| 1345 | + if (!childTaskPlans.isEmpty()) { | |
| 1346 | + Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1347 | + while (it.hasNext()) { | |
| 1348 | + ChildTaskPlan c = it.next(); | |
| 1349 | + if (c.getRemarks() != null && c.getRemarks().length() > 0) { | |
| 1350 | + remarks += c.getRemarks(); | |
| 1351 | + } | |
| 1352 | + | |
| 1353 | + } | |
| 1354 | + } | |
| 1355 | + s.setRemarks(remarks); | |
| 1356 | + } | |
| 1357 | + | |
| 1358 | + return list; | |
| 1359 | + } | |
| 1360 | + | |
| 1361 | + @Override | |
| 1362 | + public Map<String, Object> removeChildTask(Long taskId) { | |
| 1363 | + Map<String, Object> rs = new HashMap<>(); | |
| 1364 | + ChildTaskPlan chTask = cTaskPlanRepository.findOne(taskId); | |
| 1365 | + | |
| 1366 | + ScheduleRealInfo sch = dayOfSchedule.get(chTask.getSchedule().getId()); | |
| 1367 | + try { | |
| 1368 | + | |
| 1369 | + sch.getcTasks().remove(chTask); | |
| 1370 | + scheduleRealInfoRepository.save(sch); | |
| 1371 | + rs.put("status", ResponseCode.SUCCESS); | |
| 1372 | + } catch (Exception e) { | |
| 1373 | + logger.error("", e); | |
| 1374 | + rs.put("status", ResponseCode.ERROR); | |
| 1375 | + } | |
| 1376 | + return rs; | |
| 1377 | + } | |
| 1378 | + | |
| 1379 | + @Override | |
| 1380 | + public List<Map<String, Object>> statisticsDaily(String line, String date, | |
| 1381 | + String xlName) { | |
| 1382 | + List<ScheduleRealInfo> list = scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1383 | + List<Map<String, Object>> lMap = new ArrayList<Map<String, Object>>(); | |
| 1384 | + DecimalFormat format = new DecimalFormat("0.00"); | |
| 1385 | + double jhlc = 0, tempJhlc = 0, childMileage = 0; | |
| 1386 | + float sjgl = 0f, ssgl = 0f, ssgl_lz = 0f, ssgl_dm = 0f, ssgl_gz = 0f, ssgl_jf = 0f, ssgl_zs = 0f, ssgl_qr = 0f, ssgl_qc = 0f, ssgl_kx = 0f, ssgl_qh = 0f, ssgl_yw = 0f, ssgl_other = 0f, ljgl = 0f; | |
| 1387 | + //班次 | |
| 1388 | + int sj_0 = 6 * 60 + 31, sj_1 = 8 * 60 + 30, sj_2 = 16 * 60 + 1, sj_3 = 18 * 60; | |
| 1389 | + int jhbc = 0, jhbc_m = 0, jhbc_a = 0; | |
| 1390 | + int sjbc = 0, sjbc_m = 0, sjbc_a = 0; | |
| 1391 | + int ljbc = 0, ljbc_m = 0, ljbc_a = 0; | |
| 1392 | + int fzbc = 0, fzbc_m = 0, fzbc_a = 0; | |
| 1393 | + int dtbc = 0, dtbc_m = 0, dtbc_a = 0; | |
| 1394 | + int djg = 0, djg_m = 0, djg_a = 0, djg_time = 0; | |
| 1395 | + Map<String, Object> map = new HashMap<String, Object>(); | |
| 1396 | + for (ScheduleRealInfo scheduleRealInfo : list) { | |
| 1397 | + if (scheduleRealInfo != null) { | |
| 1398 | + | |
| 1399 | + if (!(scheduleRealInfo.getBcType().equals("in") | |
| 1400 | + || scheduleRealInfo.getBcType().equals("out"))) { | |
| 1401 | + Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1402 | + //计算实际里程,少驶里程,计划里程=实际里程+少驶里程 | |
| 1403 | + if (childTaskPlans.isEmpty()) { | |
| 1404 | + tempJhlc = scheduleRealInfo.getJhlc() == null ? 0 : scheduleRealInfo.getJhlc(); | |
| 1405 | + //临加公里 | |
| 1406 | + if (scheduleRealInfo.isSflj()) { | |
| 1407 | + ljgl += tempJhlc; | |
| 1408 | + } else { | |
| 1409 | + jhlc += tempJhlc; | |
| 1410 | + } | |
| 1411 | + if (scheduleRealInfo.getStatus() == 2) { | |
| 1412 | + sjgl += tempJhlc; | |
| 1413 | + } else if (scheduleRealInfo.getStatus() == -1) { | |
| 1414 | + ssgl += tempJhlc; | |
| 1415 | + if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("路阻") != -1) { | |
| 1416 | + ssgl_lz += tempJhlc; | |
| 1417 | + } else if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("吊慢") != -1) { | |
| 1418 | + ssgl_dm += tempJhlc; | |
| 1419 | + } else if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("故障") != -1) { | |
| 1420 | + ssgl_gz += tempJhlc; | |
| 1421 | + } else if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("纠纷") != -1) { | |
| 1422 | + ssgl_jf += tempJhlc; | |
| 1423 | + } else if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("肇事") != -1) { | |
| 1424 | + ssgl_zs += tempJhlc; | |
| 1425 | + } else if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("缺人") != -1) { | |
| 1426 | + ssgl_qr += tempJhlc; | |
| 1427 | + } else if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("缺车") != -1) { | |
| 1428 | + ssgl_qc += tempJhlc; | |
| 1429 | + } else if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("客稀") != -1) { | |
| 1430 | + ssgl_kx += tempJhlc; | |
| 1431 | + } else if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("气候") != -1) { | |
| 1432 | + ssgl_qh += tempJhlc; | |
| 1433 | + } else if ((scheduleRealInfo.getRemarks() == null ? "" : scheduleRealInfo.getRemarks()).indexOf("援外") != -1) { | |
| 1434 | + ssgl_yw += tempJhlc; | |
| 1435 | + } else { | |
| 1436 | + ssgl_other += tempJhlc; | |
| 1437 | + } | |
| 1438 | + } | |
| 1439 | + } else { | |
| 1440 | + Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1441 | + while (it.hasNext()) { | |
| 1442 | + ChildTaskPlan childTaskPlan = it.next(); | |
| 1443 | + childMileage = childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1444 | + jhlc += childMileage; | |
| 1445 | + if (childTaskPlan.isDestroy()) { | |
| 1446 | + ssgl += childMileage; | |
| 1447 | + if (childTaskPlan.getDestroyReason().equals("路阻")) { | |
| 1448 | + ssgl_lz += childTaskPlan.getMileage(); | |
| 1449 | + } else if (childTaskPlan.getDestroyReason().equals("吊慢")) { | |
| 1450 | + ssgl_dm += childTaskPlan.getMileage(); | |
| 1451 | + } else if (childTaskPlan.getDestroyReason().equals("故障")) { | |
| 1452 | + ssgl_gz += childTaskPlan.getMileage(); | |
| 1453 | + } else if (childTaskPlan.getDestroyReason().equals("纠纷")) { | |
| 1454 | + ssgl_jf += childTaskPlan.getMileage(); | |
| 1455 | + } else if (childTaskPlan.getDestroyReason().equals("肇事")) { | |
| 1456 | + ssgl_zs += childTaskPlan.getMileage(); | |
| 1457 | + } else if (childTaskPlan.getDestroyReason().equals("缺人")) { | |
| 1458 | + ssgl_qr += childTaskPlan.getMileage(); | |
| 1459 | + } else if (childTaskPlan.getDestroyReason().equals("缺车")) { | |
| 1460 | + ssgl_qc += childTaskPlan.getMileage(); | |
| 1461 | + } else if (childTaskPlan.getDestroyReason().equals("客稀")) { | |
| 1462 | + ssgl_kx += childTaskPlan.getMileage(); | |
| 1463 | + } else if (childTaskPlan.getDestroyReason().equals("气候")) { | |
| 1464 | + ssgl_qh += childTaskPlan.getMileage(); | |
| 1465 | + } else if (childTaskPlan.getDestroyReason().equals("援外")) { | |
| 1466 | + ssgl_yw += childTaskPlan.getMileage(); | |
| 1467 | + } else { | |
| 1468 | + ssgl_other += childTaskPlan.getMileage(); | |
| 1469 | + } | |
| 1470 | + } else { | |
| 1471 | + sjgl += childMileage; | |
| 1472 | + } | |
| 1473 | + } | |
| 1474 | + } | |
| 1475 | + | |
| 1476 | + //班次 | |
| 1477 | + jhbc++; | |
| 1478 | + String[] fcsj = scheduleRealInfo.getFcsj().split(":"); | |
| 1479 | + String[] fcsjActual = (scheduleRealInfo.getFcsjActual() == null ? "0:00" : scheduleRealInfo.getFcsjActual()).split(":"); | |
| 1480 | + if ((Integer.parseInt(fcsj[0]) * 60 + Integer.parseInt(fcsj[1])) > sj_0 && (Integer.parseInt(fcsj[0]) * 60 + Integer.parseInt(fcsj[1])) < sj_1) { | |
| 1481 | + jhbc_m++; | |
| 1482 | + } else if ((Integer.parseInt(fcsj[0]) * 60 + Integer.parseInt(fcsj[1])) > sj_2 && (Integer.parseInt(fcsj[0]) * 60 + Integer.parseInt(fcsj[1])) < sj_3) { | |
| 1483 | + jhbc_a++; | |
| 1484 | + } | |
| 1485 | + if (scheduleRealInfo.getStatus() == 2) { | |
| 1486 | + sjbc++; | |
| 1487 | + if ((Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) > sj_0 && (Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) < sj_1) { | |
| 1488 | + sjbc_m++; | |
| 1489 | + } else if ((Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) > sj_2 && (Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) < sj_3) { | |
| 1490 | + sjbc_a++; | |
| 1491 | + } | |
| 1492 | + } | |
| 1493 | + if (scheduleRealInfo.isSflj()) { | |
| 1494 | + ljbc++; | |
| 1495 | + if ((Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) > sj_0 && (Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) < sj_1) { | |
| 1496 | + ljbc_m++; | |
| 1497 | + } else if ((Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) > sj_2 && (Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) < sj_3) { | |
| 1498 | + ljbc_a++; | |
| 1499 | + } | |
| 1500 | + } | |
| 1501 | + if (scheduleRealInfo.getBcType().equals("venting")) { | |
| 1502 | + fzbc++; | |
| 1503 | + if ((Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) > sj_0 && (Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) < sj_1) { | |
| 1504 | + fzbc_m++; | |
| 1505 | + } else if ((Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) > sj_2 && (Integer.parseInt(fcsjActual[0]) * 60 + Integer.parseInt(fcsjActual[1])) < sj_3) { | |
| 1506 | + fzbc_a++; | |
| 1507 | + } | |
| 1508 | + } | |
| 1509 | + } | |
| 1510 | + } | |
| 1511 | + } | |
| 1512 | + map.put("xlName", xlName); | |
| 1513 | + map.put("jhlc", format.format(jhlc)); | |
| 1514 | + map.put("sjgl", format.format(sjgl)); | |
| 1515 | + map.put("ssgl", format.format(ssgl)); | |
| 1516 | + map.put("ssgl_lz", ssgl_lz == 0 ? 0 : format.format(ssgl_lz)); | |
| 1517 | + map.put("ssgl_dm", ssgl_dm == 0 ? 0 : format.format(ssgl_dm)); | |
| 1518 | + map.put("ssgl_gz", ssgl_gz == 0 ? 0 : format.format(ssgl_gz)); | |
| 1519 | + map.put("ssgl_jf", ssgl_jf == 0 ? 0 : format.format(ssgl_jf)); | |
| 1520 | + map.put("ssgl_zs", ssgl_zs == 0 ? 0 : format.format(ssgl_zs)); | |
| 1521 | + map.put("ssgl_qr", ssgl_qr == 0 ? 0 : format.format(ssgl_qr)); | |
| 1522 | + map.put("ssgl_qc", ssgl_qc == 0 ? 0 : format.format(ssgl_qc)); | |
| 1523 | + map.put("ssgl_kx", ssgl_kx == 0 ? 0 : format.format(ssgl_kx)); | |
| 1524 | + map.put("ssgl_qh", ssgl_qh == 0 ? 0 : format.format(ssgl_qh)); | |
| 1525 | + map.put("ssgl_yw", ssgl_yw == 0 ? 0 : format.format(ssgl_yw)); | |
| 1526 | + map.put("ssgl_other", ssgl_other == 0 ? 0 : format.format(ssgl_other)); | |
| 1527 | + map.put("ljgl", ljgl == 0 ? 0 : format.format(ljgl)); | |
| 1528 | + map.put("jhbc", jhbc); | |
| 1529 | + map.put("jhbc_m", jhbc_m); | |
| 1530 | + map.put("jhbc_a", jhbc_a); | |
| 1531 | + map.put("sjbc", sjbc); | |
| 1532 | + map.put("sjbc_m", sjbc_m); | |
| 1533 | + map.put("sjbc_a", sjbc_a); | |
| 1534 | + map.put("ljbc", ljbc); | |
| 1535 | + map.put("ljbc_m", ljbc_m); | |
| 1536 | + map.put("ljbc_a", ljbc_a); | |
| 1537 | + map.put("fzbc", fzbc); | |
| 1538 | + map.put("fzbc_m", fzbc_m); | |
| 1539 | + map.put("fzbc_a", fzbc_a); | |
| 1540 | + map.put("dtbc", dtbc); | |
| 1541 | + map.put("dtbc_m", dtbc_m); | |
| 1542 | + map.put("dtbc_a", dtbc_a); | |
| 1543 | + map.put("djg", djg); | |
| 1544 | + map.put("djg_m", djg_m); | |
| 1545 | + map.put("djg_a", djg_a); | |
| 1546 | + map.put("djg_time", djg_time); | |
| 1547 | + lMap.add(map); | |
| 1548 | + return lMap; | |
| 1549 | + } | |
| 1550 | + | |
| 1551 | + @Override | |
| 1552 | + public Map<String, Object> scheduleDaily(String line, String date) { | |
| 1553 | + Map<String, String> tempMap = null; | |
| 1554 | + List<ScheduleRealInfo> scheduleRealInfos = scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1555 | + Map<String, Object> map = new HashMap<String, Object>(); | |
| 1556 | + Double jhlc = 0.00; | |
| 1557 | + Float sjgl = 0f, ssgl = 0f, ssgl_lz = 0f, ssgl_dm = 0f, ssgl_gz = 0f, ssgl_jf = 0f, ssgl_zs = 0f, ssgl_qr = 0f, ssgl_qc = 0f, ssgl_kx = 0f, ssgl_qh = 0f, ssgl_yw = 0f, ssgl_other = 0f, ljgl = 0f; | |
| 1558 | + int jhbc = 0; | |
| 1559 | + for (ScheduleRealInfo scheduleRealInfo : scheduleRealInfos) { | |
| 1560 | + if (scheduleRealInfo != null) { | |
| 1561 | + //计算里程(包括子任务) | |
| 1562 | + jhlc += scheduleRealInfo.getJhlc(); | |
| 1563 | + Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1564 | + if (!childTaskPlans.isEmpty()) { | |
| 1565 | + Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1566 | + while (it.hasNext()) { | |
| 1567 | + ChildTaskPlan childTaskPlan = it.next(); | |
| 1568 | + //是否烂班,烂班就是少驶 | |
| 1569 | + if (!childTaskPlan.isDestroy()) { | |
| 1570 | + sjgl += childTaskPlan.getMileage(); | |
| 1571 | + } else { | |
| 1572 | + ssgl += childTaskPlan.getMileage(); | |
| 1573 | + if (childTaskPlan.getDestroyReason().equals("路阻")) { | |
| 1574 | + ssgl_lz += childTaskPlan.getMileage(); | |
| 1575 | + } else if (childTaskPlan.getDestroyReason().equals("吊慢")) { | |
| 1576 | + ssgl_dm += childTaskPlan.getMileage(); | |
| 1577 | + } else if (childTaskPlan.getDestroyReason().equals("故障")) { | |
| 1578 | + ssgl_gz += childTaskPlan.getMileage(); | |
| 1579 | + } else if (childTaskPlan.getDestroyReason().equals("纠纷")) { | |
| 1580 | + ssgl_jf += childTaskPlan.getMileage(); | |
| 1581 | + } else if (childTaskPlan.getDestroyReason().equals("肇事")) { | |
| 1582 | + ssgl_zs += childTaskPlan.getMileage(); | |
| 1583 | + } else if (childTaskPlan.getDestroyReason().equals("缺人")) { | |
| 1584 | + ssgl_qr += childTaskPlan.getMileage(); | |
| 1585 | + } else if (childTaskPlan.getDestroyReason().equals("缺车")) { | |
| 1586 | + ssgl_qc += childTaskPlan.getMileage(); | |
| 1587 | + } else if (childTaskPlan.getDestroyReason().equals("客稀")) { | |
| 1588 | + ssgl_kx += childTaskPlan.getMileage(); | |
| 1589 | + } else if (childTaskPlan.getDestroyReason().equals("气候")) { | |
| 1590 | + ssgl_qh += childTaskPlan.getMileage(); | |
| 1591 | + } else if (childTaskPlan.getDestroyReason().equals("援外")) { | |
| 1592 | + ssgl_yw += childTaskPlan.getMileage(); | |
| 1593 | + } else { | |
| 1594 | + ssgl_other += childTaskPlan.getMileage(); | |
| 1595 | + } | |
| 1596 | + } | |
| 1597 | + //临加公里 | |
| 1598 | + if (childTaskPlan.getType1().equals("临加")) { | |
| 1599 | + ljgl += childTaskPlan.getMileage(); | |
| 1600 | + } | |
| 1601 | + } | |
| 1602 | + } | |
| 1603 | + //班次 | |
| 1604 | + scheduleRealInfo.getFcsjT(); | |
| 1605 | + scheduleRealInfo.getFcsjActualTime(); | |
| 1606 | + } | |
| 1607 | + } | |
| 1608 | + map.put("jhlc", jhlc); | |
| 1609 | + map.put("sjgl", sjgl); | |
| 1610 | + map.put("ssgl", ssgl); | |
| 1611 | + map.put("ssgl_lz", ssgl_lz); | |
| 1612 | + map.put("ssgl_dm", ssgl_dm); | |
| 1613 | + map.put("ssgl_gz", ssgl_gz); | |
| 1614 | + map.put("ssgl_jf", ssgl_jf); | |
| 1615 | + map.put("ssgl_zs", ssgl_zs); | |
| 1616 | + map.put("ssgl_qr", ssgl_qr); | |
| 1617 | + map.put("ssgl_qc", ssgl_qc); | |
| 1618 | + map.put("ssgl_kx", ssgl_kx); | |
| 1619 | + map.put("ssgl_qh", ssgl_qh); | |
| 1620 | + map.put("ssgl_yw", ssgl_yw); | |
| 1621 | + map.put("ssgl_other", ssgl_other); | |
| 1622 | + map.put("ljgl", ljgl); | |
| 1623 | + | |
| 1624 | + map.put("jhbc", scheduleRealInfos.size()); | |
| 1625 | + return null; | |
| 1626 | + } | |
| 1627 | + | |
| 1628 | + @Override | |
| 1629 | + public int countByLineCodeAndDate(String xlBm, String schDate) { | |
| 1630 | + return scheduleRealInfoRepository.countByLineCodeAndDate(xlBm + "", schDate); | |
| 1631 | + } | |
| 1632 | + | |
| 1633 | + @Override | |
| 1634 | + public List<ScheduleRealInfo> findByLineCodeAndDate(String xlBm, String schDate) { | |
| 1635 | + return scheduleRealInfoRepository.findByLineCodeAndDate(xlBm + "", schDate); | |
| 1636 | + } | |
| 1637 | + | |
| 1638 | + @Override | |
| 1639 | + public void deleteByLineCodeAndDate(String xlBm, String schDate) { | |
| 1640 | + scheduleRealInfoRepository.deleteByLineCodeAndDate(xlBm + "", schDate); | |
| 1641 | + } | |
| 1642 | + | |
| 1643 | + @Override | |
| 1644 | + public Long getMaxId() { | |
| 1645 | + return scheduleRealInfoRepository.getMaxId(); | |
| 1646 | + } | |
| 1647 | + | |
| 1648 | + @Override | |
| 1649 | + public List<ScheduleRealInfo> realScheduleList(String line, String date) { | |
| 1650 | + /*List<ScheduleRealInfo> listInfo = scheduleRealInfoRepository.queryUserInfo(line, date); | |
| 1651 | + List<ScheduleRealInfo> listTotal = scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1652 | + for(ScheduleRealInfo info:listInfo){ | |
| 1653 | + for(ScheduleRealInfo total:listTotal){ | |
| 1654 | + if(info.getjGh().equals(total.getjGh()) && info.getLpName().equals(total.getLpName()) && info.getClZbh().equals(total.getClZbh())){ | |
| 1655 | + | |
| 1656 | + } | |
| 708 | 1657 | } |
| 1658 | + }*/ | |
| 1659 | + return scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1660 | + } | |
| 709 | 1661 | |
| 710 | - sch.setFcsjActualAll(fcsjActual); | |
| 711 | - sch.addRemarks(remarks); | |
| 712 | - sch.calcStatus(); | |
| 713 | - | |
| 714 | - dayOfSchedule.save(sch); | |
| 715 | - //scheduleRealInfoRepository.save(sch); | |
| 716 | - | |
| 717 | - ts.add(sch); | |
| 718 | - | |
| 719 | - rs.put("status", ResponseCode.SUCCESS); | |
| 720 | - rs.put("ts", ts); | |
| 721 | - | |
| 722 | - //通知页面刷新 | |
| 723 | - sendUtils.refreshSch(ts); | |
| 724 | - } catch (Exception e) { | |
| 725 | - logger.error("", e); | |
| 726 | - rs.put("status", ResponseCode.ERROR); | |
| 727 | - } | |
| 728 | - | |
| 729 | - return rs; | |
| 730 | - } | |
| 731 | - | |
| 732 | - @Override | |
| 733 | - public Map<String, Object> revokeDestroy(Long id) { | |
| 734 | - Map<String, Object> rs = new HashMap<>(); | |
| 735 | - try { | |
| 736 | - ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 737 | - if (sch.getStatus() != -1) { | |
| 738 | - rs.put("status", ResponseCode.ERROR); | |
| 739 | - rs.put("msg", "未烂班,无法撤销!"); | |
| 740 | - } else { | |
| 741 | - sch.setStatus(0); | |
| 742 | - rs.put("status", ResponseCode.SUCCESS); | |
| 743 | - rs.put("t", sch); | |
| 744 | - | |
| 745 | - } | |
| 746 | - } catch (Exception e) { | |
| 747 | - logger.error("", e); | |
| 748 | - rs.put("status", ResponseCode.ERROR); | |
| 749 | - } | |
| 750 | - return rs; | |
| 751 | - } | |
| 752 | 1662 | |
| 753 | - @Override | |
| 754 | - public Map<String, Object> revokeRealOutgo(Long id) { | |
| 755 | - Map<String, Object> rs = new HashMap<>(); | |
| 756 | - List<ScheduleRealInfo> ts = new ArrayList<>(); | |
| 1663 | + public List<Map<String, Object>> yesterdayDataList(String line, String date) { | |
| 1664 | + //前一天日期 | |
| 1665 | +// String date = sdfMonth.format(org.apache.commons.lang.time.DateUtils.addDays(new Date(), -1)); | |
| 1666 | +// String date = "2016-09-20"; | |
| 1667 | + List<Map<String, Object>> yesterdayDataList = scheduleRealInfoRepository.yesterdayDataList(line, date); | |
| 1668 | +// List<ScheduleRealInfo> list = scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1669 | + for (int x = 0; x < yesterdayDataList.size(); x++) { | |
| 1670 | + String jName = yesterdayDataList.get(x).get("jGh").toString(); | |
| 1671 | + String clZbh = yesterdayDataList.get(x).get("clZbh").toString(); | |
| 1672 | + List<ScheduleRealInfo> lists = scheduleRealInfoRepository.queryListWaybill3(jName, clZbh, date); | |
| 1673 | + double jhlc = 0, yygl = 0, ksgl = 0, tempJhlc = 0, jcclc = 0; | |
| 1674 | + float addMileage = 0l, remMileage = 0l; | |
| 1675 | + Map<String, Object> map = new HashMap<String, Object>(); | |
| 1676 | + boolean fage = true; | |
| 1677 | + for (ScheduleRealInfo scheduleRealInfo : lists) { | |
| 1678 | + if (fage) { | |
| 1679 | + //根据线路代码获取公司 | |
| 1680 | + Line li = lineRepository.findByLineCode(scheduleRealInfo.getXlBm()); | |
| 1681 | + yesterdayDataList.get(x).put("company", li.getCompany()); | |
| 1682 | + yesterdayDataList.get(x).put("bCompany", li.getBrancheCompany()); | |
| 1683 | + fage = false; | |
| 1684 | + } | |
| 1685 | + if (scheduleRealInfo != null) { | |
| 1686 | + //计划里程(主任务过滤掉临加班次), | |
| 1687 | + //烂班里程(主任务烂班), | |
| 1688 | + //临加里程(主任务临加), | |
| 1689 | + //计划班次,烂班班次,增加班次 | |
| 1690 | + tempJhlc = scheduleRealInfo.getJhlc() == null ? 0 : scheduleRealInfo.getJhlc(); | |
| 1691 | + if (scheduleRealInfo.isSflj()) { | |
| 1692 | + addMileage += tempJhlc; | |
| 1693 | + } else { | |
| 1694 | + if (!(scheduleRealInfo.getBcType().equals("in") | |
| 1695 | + || scheduleRealInfo.getBcType().equals("out"))) { | |
| 1696 | + jhlc += tempJhlc; | |
| 1697 | + } | |
| 1698 | + | |
| 1699 | + if (scheduleRealInfo.getStatus() == -1) { | |
| 1700 | + remMileage += tempJhlc; | |
| 1701 | + } | |
| 1702 | + } | |
| 1703 | + Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1704 | + //计算营运里程,空驶里程 | |
| 1705 | + if (childTaskPlans.isEmpty()) { | |
| 1706 | + if (scheduleRealInfo.getBcType().equals("in") || | |
| 1707 | + scheduleRealInfo.getBcType().equals("out")) { | |
| 1708 | + jcclc += tempJhlc; | |
| 1709 | + } | |
| 1710 | + //主任务 放空班次属于营运 | |
| 1711 | +// else if(scheduleRealInfo.getBcType().equals("venting")){ | |
| 1712 | +// ksgl += tempJhlc; | |
| 1713 | +// } | |
| 1714 | + else { | |
| 1715 | + if (scheduleRealInfo.getStatus() != -1) { | |
| 1716 | + yygl += tempJhlc; | |
| 1717 | + } | |
| 1718 | + } | |
| 1719 | + } else { | |
| 1720 | + Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1721 | + while (it.hasNext()) { | |
| 1722 | + ChildTaskPlan childTaskPlan = it.next(); | |
| 1723 | + if (childTaskPlan.getMileageType().equals("empty")) { | |
| 1724 | + if (childTaskPlan.isDestroy()) { | |
| 1725 | + remMileage += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1726 | + } else { | |
| 1727 | + ksgl += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1728 | + } | |
| 1729 | + } else { | |
| 1730 | + if (childTaskPlan.isDestroy()) { | |
| 1731 | + remMileage += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1732 | + } else { | |
| 1733 | + yygl += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1734 | + } | |
| 1735 | + } | |
| 1736 | + } | |
| 1737 | + } | |
| 1738 | + } | |
| 1739 | + } | |
| 1740 | + | |
| 1741 | + yesterdayDataList.get(x).put("totalKilometers", yygl + ksgl + jcclc); | |
| 1742 | + | |
| 1743 | + } | |
| 757 | 1744 | |
| 758 | - try { | |
| 759 | - ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 760 | - if (sch.getFcsjActual() == null) { | |
| 761 | - rs.put("status", ResponseCode.ERROR); | |
| 762 | - rs.put("msg", "无实发时间,无法撤销!"); | |
| 763 | - } else { | |
| 764 | - //将对应的到离站数据标记为不可信 | |
| 765 | - List<ArrivalEntity> list = ArrivalData_GPS.findByNbbm(sch.getClZbh()); | |
| 766 | - for(ArrivalEntity arr : list){ | |
| 767 | - if(arr.getInOut() == 1 | |
| 768 | - && arr.getUpDown() == Integer.parseInt(sch.getXlDir()) | |
| 769 | - && arr.getStopNo().equals(sch.getQdzCode()) | |
| 770 | - && Math.abs(arr.getTs() - sch.getFcsjActualTime()) < 1000 * 60){ | |
| 771 | - arr.setEnable(false); | |
| 772 | - break; | |
| 773 | - } | |
| 1745 | + /* for(ScheduleRealInfo scheduleRealInfo:list){ | |
| 1746 | + if(scheduleRealInfo != null){ | |
| 1747 | + for(int i=0;i<yesterdayDataList.size();i++){ | |
| 1748 | + if(scheduleRealInfo.getXlBm().equals(yesterdayDataList.get(i).get("xlBm")) && scheduleRealInfo.getClZbh().equals(yesterdayDataList.get(i).get("clZbh")) | |
| 1749 | + && scheduleRealInfo.getjGh().equals(yesterdayDataList.get(i).get("jGh"))){ | |
| 1750 | + //根据线路代码获取公司 | |
| 1751 | + Line li = lineRepository.findByLineCode(scheduleRealInfo.getXlBm()); | |
| 1752 | + yesterdayDataList.get(i).put("company", li.getCompany()); | |
| 1753 | + yesterdayDataList.get(i).put("bCompany", li.getBrancheCompany()); | |
| 1754 | + //计算总公里 | |
| 1755 | + Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1756 | + //如果没有子任务,里程就是已执行(Status=2);有子任务的,忽略主任务,子任务的烂班 | |
| 1757 | + if(childTaskPlans.isEmpty()){ | |
| 1758 | + if(scheduleRealInfo.getStatus() == 2){ | |
| 1759 | + yesterdayDataList.get(i).put("totalKilometers", scheduleRealInfo.getJhlc()==null?0.0:scheduleRealInfo.getJhlc()+(double)(yesterdayDataList.get(i).get("totalKilometers")==null?0.0:yesterdayDataList.get(i).get("totalKilometers"))); | |
| 1760 | + } | |
| 1761 | + }else{ | |
| 1762 | + Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1763 | + while(it.hasNext()){ | |
| 1764 | + ChildTaskPlan childTaskPlan = it.next(); | |
| 1765 | + if(!childTaskPlan.isDestroy()){ | |
| 1766 | + yesterdayDataList.get(i).put("totalKilometers", childTaskPlan.getMileage()==null?0.0:childTaskPlan.getMileage()+(double)(yesterdayDataList.get(i).get("totalKilometers")==null?0.0:yesterdayDataList.get(i).get("totalKilometers"))); | |
| 1767 | + } | |
| 1768 | + } | |
| 1769 | + } | |
| 1770 | + } | |
| 774 | 1771 | } |
| 775 | - | |
| 776 | - sch.clearFcsjActual(); | |
| 777 | - rs.put("status", ResponseCode.SUCCESS); | |
| 778 | - | |
| 779 | - ts.add(sch); | |
| 780 | - rs.put("ts", ts); | |
| 781 | - | |
| 782 | - } | |
| 783 | - } catch (Exception e) { | |
| 784 | - logger.error("", e); | |
| 785 | - rs.put("status", ResponseCode.ERROR); | |
| 786 | - } | |
| 787 | - return rs; | |
| 788 | - } | |
| 789 | - | |
| 790 | - @Override | |
| 791 | - public Map<String, Object> spaceAdjust(Long[] ids, Integer space) { | |
| 792 | - | |
| 793 | - List<ScheduleRealInfo> list = new ArrayList<>() | |
| 794 | - ,updateList = new ArrayList<>(); | |
| 795 | - Map<String, Object> rs = new HashMap<>(); | |
| 796 | - try { | |
| 797 | - ScheduleRealInfo sch, next; | |
| 798 | - for (Long id : ids) { | |
| 799 | - sch = dayOfSchedule.get(id); | |
| 800 | - if (null != sch) | |
| 801 | - list.add(sch); | |
| 802 | 1772 | } |
| 1773 | + }*/ | |
| 1774 | + //增加顺序号 | |
| 1775 | + for (int i = 0; i < yesterdayDataList.size(); i++) { | |
| 1776 | + if (i == 0) { | |
| 1777 | + yesterdayDataList.get(i).put("seqNumber", 1); | |
| 1778 | + } else { | |
| 1779 | + if (yesterdayDataList.get(i - 1).get("clZbh").equals(yesterdayDataList.get(i).get("clZbh"))) { | |
| 1780 | + yesterdayDataList.get(i).put("seqNumber", 1 + (int) yesterdayDataList.get(i - 1).get("seqNumber")); | |
| 1781 | + } else { | |
| 1782 | + yesterdayDataList.get(i).put("seqNumber", 1); | |
| 1783 | + } | |
| 1784 | + } | |
| 1785 | + } | |
| 1786 | + return yesterdayDataList; | |
| 1787 | + } | |
| 1788 | + | |
| 1789 | + /** | |
| 1790 | + * 批量调整人车 | |
| 1791 | + */ | |
| 1792 | + @Override | |
| 1793 | + public Map<String, Object> multi_tzrc(List<ChangePersonCar> cpcs) { | |
| 1794 | + Map<String, Object> rs = new HashMap<>(); | |
| 1795 | + Set<ScheduleRealInfo> set = new HashSet<>(); | |
| 1796 | + | |
| 1797 | + ScheduleRealInfo sch; | |
| 1798 | + BiMap<String, String> map = BasicData.deviceId2NbbmMap.inverse(); | |
| 1799 | + | |
| 1800 | + for (ChangePersonCar cpc : cpcs) { | |
| 1801 | + | |
| 1802 | + if (map.get(cpc.getClZbh()) == null) { | |
| 1803 | + rs.put("msg", "车辆 " + cpc.getClZbh() + " <a href=\"/#/busInfoManage\" target=_blank>车辆基础信息</a> 里找不到!"); | |
| 1804 | + rs.put("status", ResponseCode.ERROR); | |
| 1805 | + return rs; | |
| 1806 | + } | |
| 1807 | + | |
| 1808 | + sch = dayOfSchedule.get(cpc.getSchId()); | |
| 1809 | + if (sch == null) | |
| 1810 | + continue; | |
| 1811 | + | |
| 1812 | + if (StringUtils.isNotEmpty(cpc.getJsy())) { | |
| 1813 | + //换驾驶员 | |
| 1814 | + persoChange(sch, cpc.getJsy().split("/")[0]); | |
| 1815 | + } | |
| 1816 | + | |
| 1817 | + //换售票员 | |
| 1818 | + if (StringUtils.isNotEmpty(cpc.getSpy())) { | |
| 1819 | + persoChangeSPY(sch, cpc.getSpy().split("/")[0]); | |
| 1820 | + } | |
| 1821 | + | |
| 1822 | + //换车 | |
| 1823 | + if (StringUtils.isNotEmpty(cpc.getClZbh())) { | |
| 1824 | + set.add(sch); | |
| 1825 | + set.addAll(dayOfSchedule.changeCar(sch, cpc.getClZbh())); | |
| 1826 | + } | |
| 1827 | + | |
| 1828 | + } | |
| 1829 | + rs.put("ts", set); | |
| 1830 | + rs.put("status", ResponseCode.SUCCESS); | |
| 1831 | + return rs; | |
| 1832 | + } | |
| 1833 | + | |
| 1834 | + /** | |
| 1835 | + * @Title: persoChange | |
| 1836 | + * @Description: TODO(班次换驾驶员) | |
| 1837 | + */ | |
| 1838 | + public void persoChange(ScheduleRealInfo sch, String jGh) { | |
| 1839 | + if (sch.getjGh().equals(jGh)) | |
| 1840 | + return; | |
| 1841 | + String jName = BasicData.allPerson.get(jGh); | |
| 1842 | + if (StringUtils.isNotEmpty(jName)) { | |
| 1843 | + sch.setjGh(jGh); | |
| 1844 | + sch.setjName(jName); | |
| 1845 | + } | |
| 1846 | + } | |
| 1847 | + | |
| 1848 | + /** | |
| 1849 | + * @Title: persoChange | |
| 1850 | + * @Description: TODO(班次换售票员) | |
| 1851 | + */ | |
| 1852 | + public void persoChangeSPY(ScheduleRealInfo sch, String sGh) { | |
| 1853 | + if (sch.getsGh().equals(sGh)) | |
| 1854 | + return; | |
| 1855 | + String sName = BasicData.allPerson.get(sGh); | |
| 1856 | + if (StringUtils.isNotEmpty(sName)) { | |
| 1857 | + sch.setsGh(sGh); | |
| 1858 | + sch.setsName(sName); | |
| 1859 | + } | |
| 1860 | + } | |
| 1861 | + | |
| 1862 | + /** | |
| 1863 | + * 批量待发调整 | |
| 1864 | + */ | |
| 1865 | + @Override | |
| 1866 | + public Map<String, Object> multi_dftz(List<DfsjChange> dfsjcs) { | |
| 1867 | + Map<String, Object> rs = new HashMap<>(), tempMap = new HashMap<>(); | |
| 1868 | + List<ScheduleRealInfo> list = new ArrayList<>(); | |
| 1869 | + | |
| 1870 | + ScheduleRealInfo sch, next; | |
| 1871 | + for (DfsjChange dc : dfsjcs) { | |
| 1872 | + if (StringUtils.isEmpty(dc.getOld_dfsj()) || StringUtils.isEmpty(dc.getNew_dfsj())) | |
| 1873 | + continue; | |
| 1874 | + | |
| 1875 | + /*sch = dayOfSchedule.get(dc.getSchId()); | |
| 1876 | + if(sch==null) | |
| 1877 | + continue; | |
| 1878 | + | |
| 1879 | + sch.setDfsjAll(dc.getNew_dfsj()); | |
| 1880 | + //重新计算终点时间 | |
| 1881 | + sch.calcEndTime(); | |
| 1882 | + list.add(sch);*/ | |
| 1883 | + tempMap = outgoAdjust(dc.getSchId(), "", dc.getNew_dfsj(), null); | |
| 803 | 1884 | |
| 804 | - int size = list.size(); | |
| 805 | - if(size == 0){ | |
| 806 | - rs.put("status", ResponseCode.ERROR); | |
| 807 | - } | |
| 808 | - else{ | |
| 809 | - // 按发车时间排序 | |
| 810 | - Collections.sort(list, new ScheduleComparator.FCSJ()); | |
| 811 | - | |
| 812 | - // 以第一个实际发车/待发时间为起点,调整间隔 | |
| 813 | - sch = list.get(0); | |
| 814 | - Long st = sch.getFcsjActualTime()==null?sch.getDfsjT():sch.getFcsjActualTime() | |
| 815 | - ,plus = space * 60 * 1000L; | |
| 816 | - | |
| 817 | - for(int i = 1; i < size; i ++){ | |
| 818 | - st += plus; | |
| 819 | - sch = list.get(i); | |
| 820 | - sch.setDfsjAll(st); | |
| 821 | - //重新计算终点时间 | |
| 822 | - sch.calcEndTime(); | |
| 823 | - | |
| 824 | - dayOfSchedule.save(sch); | |
| 825 | - | |
| 826 | - updateList.add(sch); | |
| 827 | - next=dayOfSchedule.next(sch); | |
| 828 | - if(next.getQdzName().equals(sch.getZdzName())){ | |
| 829 | - next.setQdzArrDateJH(sch.getZdsj()); | |
| 830 | - updateList.add(next); | |
| 831 | - } | |
| 832 | - } | |
| 1885 | + if (tempMap.get("status").equals(ResponseCode.SUCCESS)) { | |
| 1886 | + list.addAll((Collection<? extends ScheduleRealInfo>) tempMap.get("ts")); | |
| 1887 | + } | |
| 1888 | + //next=dayOfSchedule.next(sch); | |
| 1889 | + /*if(next.getQdzName().equals(sch.getZdzName())){ | |
| 1890 | + next.setQdzArrDateJH(sch.getZdsj()); | |
| 1891 | + list.add(next); | |
| 1892 | + }*/ | |
| 1893 | + } | |
| 833 | 1894 | |
| 1895 | + rs.put("status", ResponseCode.SUCCESS); | |
| 1896 | + rs.put("ts", list); | |
| 1897 | + return rs; | |
| 1898 | + } | |
| 834 | 1899 | |
| 835 | - rs.put("status", ResponseCode.SUCCESS); | |
| 836 | - rs.put("ts", updateList); | |
| 837 | - } | |
| 838 | - | |
| 839 | - } catch (Exception e) { | |
| 840 | - logger.error("", e); | |
| 841 | - rs.put("status", ResponseCode.ERROR); | |
| 842 | - } | |
| 843 | - return rs; | |
| 844 | - } | |
| 845 | 1900 | |
| 846 | - private static DateTimeFormatter fmtyyyyMMddHHmm = DateTimeFormat.forPattern("yyyy-MM-ddHH:mm"); | |
| 1901 | + @Override | |
| 1902 | + public Map<String, Object> findKMBC1(String jName, String clZbh, | |
| 1903 | + String date, String enddate) { | |
| 1904 | + List<ScheduleRealInfo> list = scheduleRealInfoRepository.queryListWaybill4(jName, clZbh, date, enddate); | |
| 1905 | + DecimalFormat format = new DecimalFormat("0.00"); | |
| 1906 | +// int cjbc = scheduleRealInfoRepository.findCjbc(jName, clZbh, lpName); | |
| 1907 | +// int ljbc = scheduleRealInfoRepository.findLjbc(jName, clZbh, lpName); | |
| 1908 | + int jhbc = 0, cjbc = 0, ljbc = 0; | |
| 1909 | + double jhlc = 0, yygl = 0, ksgl = 0, tempJhlc = 0; | |
| 1910 | + float addMileage = 0l, remMileage = 0l; | |
| 1911 | + Map<String, Object> map = new HashMap<String, Object>(); | |
| 1912 | + for (ScheduleRealInfo scheduleRealInfo : list) { | |
| 1913 | + if (scheduleRealInfo != null) { | |
| 1914 | + //计划里程(主任务过滤掉临加班次), | |
| 1915 | + //烂班里程(主任务烂班), | |
| 1916 | + //临加里程(主任务临加), | |
| 1917 | + //计划班次,烂班班次,增加班次 | |
| 1918 | + tempJhlc = scheduleRealInfo.getJhlc() == null ? 0 : scheduleRealInfo.getJhlc(); | |
| 1919 | + if (scheduleRealInfo.isSflj()) { | |
| 1920 | + addMileage += tempJhlc; | |
| 1921 | + ljbc++; | |
| 1922 | + } else { | |
| 1923 | + jhlc += tempJhlc; | |
| 1924 | + jhbc++; | |
| 1925 | + if (scheduleRealInfo.getStatus() == -1) { | |
| 1926 | + remMileage += tempJhlc; | |
| 1927 | + cjbc++; | |
| 1928 | + } | |
| 1929 | + } | |
| 1930 | + Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1931 | + //计算营运里程,空驶里程 | |
| 1932 | + if (childTaskPlans.isEmpty()) { | |
| 1933 | + if (scheduleRealInfo.getBcType().equals("in") || scheduleRealInfo.getBcType().equals("out") | |
| 1934 | + || scheduleRealInfo.getBcType().equals("venting")) { | |
| 1935 | + ksgl += tempJhlc; | |
| 1936 | + } else { | |
| 1937 | + yygl += tempJhlc; | |
| 1938 | + } | |
| 1939 | + } else { | |
| 1940 | + Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1941 | + while (it.hasNext()) { | |
| 1942 | + ChildTaskPlan childTaskPlan = it.next(); | |
| 1943 | + if (childTaskPlan.getMileageType().equals("empty")) { | |
| 1944 | + ksgl += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1945 | + } else { | |
| 1946 | + yygl += childTaskPlan.getMileage() == null ? 0 : childTaskPlan.getMileage(); | |
| 1947 | + } | |
| 1948 | + } | |
| 1949 | + } | |
| 1950 | + } | |
| 1951 | + } | |
| 1952 | + map.put("jhlc", format.format(jhlc)); | |
| 1953 | + map.put("remMileage", format.format(remMileage)); | |
| 1954 | + map.put("addMileage", format.format(addMileage)); | |
| 1955 | + map.put("yygl", format.format(yygl)); | |
| 1956 | + map.put("ksgl", format.format(ksgl)); | |
| 1957 | + map.put("realMileage", format.format(yygl + ksgl)); | |
| 1958 | + map.put("jhbc", jhbc); | |
| 1959 | + map.put("cjbc", cjbc); | |
| 1960 | + map.put("ljbc", ljbc); | |
| 1961 | + map.put("sjbc", jhbc - cjbc + ljbc); | |
| 1962 | + return map; | |
| 1963 | + } | |
| 1964 | + | |
| 1965 | + /** | |
| 1966 | + * 调整班次类型 | |
| 1967 | + * | |
| 1968 | + * @param id | |
| 1969 | + * @param bcType | |
| 1970 | + * @param remarks | |
| 1971 | + * @return | |
| 1972 | + */ | |
| 1973 | + @Override | |
| 1974 | + public Map<String, Object> changeBcType(Long id, String bcType, String remarks) { | |
| 1975 | + Map<String, Object> rs = new HashMap<>(); | |
| 1976 | + | |
| 1977 | + try { | |
| 1978 | + ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 1979 | + if (sch != null) { | |
| 1980 | + sch.setBcType(bcType); | |
| 1981 | + sch.addRemarks(remarks); | |
| 1982 | + //有时间记录一下相关变更数据 | |
| 1983 | + rs.put("status", ResponseCode.SUCCESS); | |
| 1984 | + rs.put("t", sch); | |
| 1985 | + } | |
| 1986 | + } catch (Exception e) { | |
| 1987 | + logger.error("", e); | |
| 1988 | + rs.put("status", ResponseCode.ERROR); | |
| 1989 | + } | |
| 1990 | + | |
| 1991 | + return rs; | |
| 1992 | + } | |
| 1993 | + | |
| 1994 | + @Override | |
| 1995 | + public Map<String, Object> historySave(ScheduleRealInfo sch) { | |
| 1996 | + Map<String, Object> rs = new HashMap<>(); | |
| 1997 | + rs.put("status", ResponseCode.ERROR); | |
| 1998 | + | |
| 1999 | + ScheduleRealInfo oldSch = super.findById(sch.getId()); | |
| 2000 | + //修改车辆 | |
| 2001 | + if (!oldSch.getClZbh().equals(sch.getClZbh())) { | |
| 2002 | + Set<String> allCar = BasicData.deviceId2NbbmMap.values(); | |
| 2003 | + if (!allCar.contains(sch.getClZbh())) { | |
| 2004 | + rs.put("msg", "无效的车辆自编号"); | |
| 2005 | + return rs; | |
| 2006 | + } else | |
| 2007 | + oldSch.setClZbh(sch.getClZbh()); | |
| 2008 | + } | |
| 2009 | + | |
| 2010 | + //修改驾驶员 | |
| 2011 | + if (!oldSch.getjGh().equals(sch.getjGh())) { | |
| 2012 | + Map<String, String> allPer = BasicData.allPerson; | |
| 2013 | + if (!allPer.containsKey(sch.getjGh())) { | |
| 2014 | + rs.put("msg", "无效的驾驶员"); | |
| 2015 | + return rs; | |
| 2016 | + } else { | |
| 2017 | + oldSch.setjGh(sch.getjGh()); | |
| 2018 | + oldSch.setjName(allPer.get(oldSch.getjGh())); | |
| 2019 | + } | |
| 2020 | + } | |
| 2021 | + | |
| 2022 | + //待发时间 | |
| 2023 | + oldSch.setDfsj(sch.getDfsj()); | |
| 2024 | + //实发时间 | |
| 2025 | + oldSch.setFcsjActual(sch.getFcsjActual()); | |
| 2026 | + //实际终点 | |
| 2027 | + oldSch.setZdsjActual(sch.getZdsjActual()); | |
| 2028 | + //备注 | |
| 2029 | + oldSch.setRemarks(sch.getRemarks()); | |
| 2030 | + | |
| 2031 | + scheduleRealInfoRepository.save(oldSch); | |
| 2032 | + rs.put("status", ResponseCode.SUCCESS); | |
| 2033 | + return rs; | |
| 2034 | + } | |
| 2035 | + | |
| 2036 | + @Autowired | |
| 2037 | + SvgAttributeRepository svgAttributeRepository; | |
| 2038 | + | |
| 2039 | + @Override | |
| 2040 | + public Map<String, Object> svgAttr(String jsonStr) { | |
| 2041 | + Map<String, Object> rs = new HashMap<>(); | |
| 2042 | + | |
| 2043 | + try { | |
| 2044 | + JSONObject jObj = JSONObject.parseObject(StringEscapeUtils.unescapeHtml4(jsonStr)); | |
| 2045 | + | |
| 2046 | + SvgAttribute svgAttribute = new SvgAttribute(); | |
| 2047 | + svgAttribute.setLineCode(jObj.getString("lineCode")); | |
| 2048 | + svgAttribute.setHideStations(jObj.getString("hideStations")); | |
| 2049 | + svgAttribute.setNicknames(jObj.getString("nicknames")); | |
| 2050 | + svgAttributeRepository.save(svgAttribute); | |
| 2051 | + | |
| 2052 | + rs.put("t", svgAttribute); | |
| 2053 | + rs.put("status", ResponseCode.SUCCESS); | |
| 2054 | + } catch (Exception e) { | |
| 2055 | + logger.error("", e); | |
| 2056 | + rs.put("status", ResponseCode.ERROR); | |
| 2057 | + } | |
| 2058 | + return rs; | |
| 2059 | + } | |
| 2060 | + | |
| 2061 | + @Override | |
| 2062 | + public Map<String, Object> findSvgAttr(String idx) { | |
| 2063 | + Map<String, Object> rs = new HashMap<>(); | |
| 2064 | + try { | |
| 2065 | + List<String> lineCodes = Splitter.on(",").splitToList(idx); | |
| 2066 | + List<SvgAttribute> list = svgAttributeRepository.findSvgAttr(lineCodes); | |
| 2067 | + | |
| 2068 | + rs.put("status", ResponseCode.SUCCESS); | |
| 2069 | + rs.put("list", list); | |
| 2070 | + } catch (Exception e) { | |
| 2071 | + logger.error("", e); | |
| 2072 | + rs.put("status", ResponseCode.ERROR); | |
| 2073 | + } | |
| 2074 | + return rs; | |
| 2075 | + } | |
| 2076 | + | |
| 2077 | + @Override | |
| 2078 | + public List<Map<String, Object>> yesterdayDataList(String line) { | |
| 2079 | + // TODO Auto-generated method stub | |
| 2080 | + return null; | |
| 2081 | + } | |
| 847 | 2082 | |
| 848 | 2083 | @Override |
| 849 | - public Map<String, Object> schInfoFineTune(Map<String, String> map) { | |
| 850 | - Map<String, Object> rs = new HashMap<>(); | |
| 851 | - List<ScheduleRealInfo> ts = new ArrayList<>(); | |
| 852 | - try { | |
| 853 | - Long id = Long.parseLong(map.get("id")); | |
| 854 | - //班次类型 | |
| 855 | - //String bcType = map.get("bcType"); | |
| 856 | - //车辆自编号 | |
| 857 | - //String clZbh = map.get("clZbh"); | |
| 858 | - //计划发车时间 | |
| 859 | - //String fcsj = map.get("fcsj"); | |
| 860 | - //实际发车时间 | |
| 861 | - String fcsjActual = map.get("fcsjActual"); | |
| 862 | - | |
| 863 | - //实际终点时间 | |
| 864 | - String zdsjActual = map.get("zdsjActual"); | |
| 865 | - //备注 | |
| 866 | - String remarks = map.get("remarks"); | |
| 867 | - | |
| 868 | - ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 869 | - if(null != sch){ | |
| 870 | -// //驾驶员 | |
| 871 | -// if(StringUtils.isNotBlank(map.get("jsy"))){ | |
| 872 | -// String[] jsy = map.get("jsy").split("/"); | |
| 873 | -// sch.setjGh(jsy[0]); | |
| 874 | -// sch.setjName(jsy[1]); | |
| 875 | -// } | |
| 876 | - | |
| 877 | - //售票员 | |
| 878 | -// if(StringUtils.isNotBlank(map.get("spy"))){ | |
| 879 | -// String[] spy = map.get("spy").split("/"); | |
| 880 | -// sch.setsGh(spy[0]); | |
| 881 | -// sch.setsName(spy[1]); | |
| 882 | -// } | |
| 883 | - | |
| 884 | - //sch.setBcType(bcType); | |
| 885 | - //sch.setClZbh(clZbh); | |
| 886 | - //sch.setFcsjAll(fcsj); | |
| 887 | - | |
| 888 | - if(StringUtils.isNotBlank(fcsjActual)){ | |
| 889 | - LineConfig config = lineConfigData.get(sch.getXlBm()); | |
| 890 | - long t=0L; | |
| 891 | - //小于线路开始运营时间,则默认跨过24点 | |
| 892 | - if(fcsjActual.compareTo(config.getStartOpt()) < 0) | |
| 893 | - t=fmtyyyyMMddHHmm.parseMillis(fmtyyyyMMdd.print(sch.getScheduleDate().getTime() + DAY_TIME)+fcsjActual); | |
| 894 | - else | |
| 895 | - t=fmtyyyyMMddHHmm.parseMillis(sch.getScheduleDateStr()+fcsjActual); | |
| 896 | - | |
| 897 | - //调整实发 | |
| 898 | - if(!fcsjActual.equals(sch.getFcsjActual())) | |
| 899 | - sch.setFcsjActualAll(t); | |
| 900 | - } | |
| 901 | - else{ | |
| 902 | - //撤销实发 | |
| 903 | - if(sch.getFcsjActual() != null) | |
| 904 | - revokeRealOutgo(sch.getId()); | |
| 905 | - } | |
| 906 | - | |
| 907 | - //实达时间 | |
| 908 | - if(StringUtils.isNotBlank(zdsjActual)){ | |
| 909 | - if(!zdsjActual.equals(sch.getZdsjActual())){ | |
| 910 | - //调整实达 | |
| 911 | - sch.setZdsjActualAll(zdsjActual); | |
| 912 | - //下一班次起点到达时间 | |
| 913 | - ScheduleRealInfo next = dayOfSchedule.next(sch); | |
| 914 | - if(null != next){ | |
| 915 | - next.setQdzArrDateSJ(zdsjActual); | |
| 916 | - ts.add(next); | |
| 917 | - } | |
| 918 | - | |
| 919 | - //重新计算车辆执行班次 | |
| 920 | - dayOfSchedule.reCalcExecPlan(sch.getClZbh()); | |
| 921 | - } | |
| 922 | - } | |
| 923 | - else { | |
| 924 | - /*if(sch.getZdsjActual() != null){ | |
| 925 | - //将对应的到离站数据标记为不可信 | |
| 926 | - List<ArrivalEntity> list = ArrivalData_GPS.findByNbbm(sch.getClZbh()); | |
| 927 | - for(ArrivalEntity arr : list){ | |
| 928 | - if(arr.getInOut() == 0 | |
| 929 | - && arr.getUpDown() == Integer.parseInt(sch.getXlDir()) | |
| 930 | - && arr.getStopNo().equals(sch.getZdzCode()) | |
| 931 | - && Math.abs(arr.getTs() - sch.getZdsjActualTime()) < 1000 * 60){ | |
| 932 | - arr.setEnable(false); | |
| 933 | - break; | |
| 934 | - } | |
| 935 | - } | |
| 936 | - }*/ | |
| 937 | - | |
| 938 | - //清除实达时间 | |
| 939 | - sch.clearZdsjActual(); | |
| 940 | - //清除下一班次起点到达时间 | |
| 941 | - ScheduleRealInfo next = dayOfSchedule.next(sch); | |
| 942 | - if(null != next){ | |
| 943 | - next.setQdzArrDateSJ(null); | |
| 944 | - ts.add(next); | |
| 945 | - } | |
| 946 | - } | |
| 947 | - | |
| 948 | - sch.setRemarks(remarks); | |
| 949 | - } | |
| 950 | - | |
| 951 | - //班次状态 | |
| 952 | - sch.calcStatus(); | |
| 953 | - dayOfSchedule.save(sch); | |
| 954 | - //页面需要更新的班次信息 | |
| 955 | - ts.add(sch); | |
| 956 | - | |
| 957 | - rs.put("status", ResponseCode.SUCCESS); | |
| 958 | - rs.put("ts", ts); | |
| 959 | - } catch (Exception e) { | |
| 960 | - logger.error("", e); | |
| 961 | - rs.put("status", ResponseCode.ERROR); | |
| 962 | - } | |
| 963 | - return rs; | |
| 964 | - } | |
| 965 | - | |
| 966 | - @Override | |
| 967 | - public Map<String, Object> outgoAdjustAll(String params) { | |
| 968 | - Map<String, Object> rs = new HashMap<>(); | |
| 969 | - try{ | |
| 970 | - JSONArray jsonArray = JSONArray.parseArray(params); | |
| 971 | - | |
| 972 | - ScheduleRealInfo schedule = null; | |
| 973 | - JSONObject jsonObj; | |
| 974 | - String dfsj; | |
| 975 | - for(int i = 0; i < jsonArray.size(); i ++){ | |
| 976 | - jsonObj = jsonArray.getJSONObject(i); | |
| 977 | - dfsj = jsonObj.getString("t"); | |
| 978 | - schedule = dayOfSchedule.get(jsonObj.getLong("id")); | |
| 979 | - //设置待发时间 | |
| 980 | - schedule.setDfsjAll(dfsj); | |
| 981 | - | |
| 982 | - dayOfSchedule.save(schedule); | |
| 983 | - } | |
| 984 | - | |
| 985 | - rs.put("status", ResponseCode.SUCCESS); | |
| 986 | - //将更新的最后一个班次返回 | |
| 987 | - rs.put("t", schedule); | |
| 988 | - }catch(Exception e){ | |
| 989 | - logger.error("", e); | |
| 990 | - rs.put("status", ResponseCode.ERROR); | |
| 991 | - } | |
| 992 | - return rs; | |
| 993 | - } | |
| 994 | - | |
| 995 | - @Override | |
| 996 | - public Map<String, Object> findRouteByLine(String lineCode) { | |
| 997 | - Map<String, Object> map = new HashMap<>(); | |
| 998 | - //上行 | |
| 999 | - Integer lineId = BasicData.lineId2CodeMap.inverse().get(lineCode); | |
| 1000 | - map.put("line.id_eq", lineId); | |
| 1001 | - map.put("directions_eq", 0); | |
| 1002 | - List<Map<String, Object>> upList = sectionRouteService.getSectionRoute(map); | |
| 1003 | - | |
| 1004 | - //下行 | |
| 1005 | - map.put("directions_eq", 1); | |
| 1006 | - List<Map<String, Object>> downList = sectionRouteService.getSectionRoute(map); | |
| 1007 | - | |
| 1008 | - Map<String, Object> rs = new HashMap<>(); | |
| 1009 | - | |
| 1010 | - String upVectors = "", vec; | |
| 1011 | - //拼接上行路段 | |
| 1012 | - for(Map<String, Object> temp : upList){ | |
| 1013 | - vec = temp.get("sectionBsectionVector").toString(); | |
| 1014 | - upVectors += vec.subSequence(11, vec.length() - 2) + " "; | |
| 1015 | - } | |
| 1016 | - | |
| 1017 | - //拼接下行路段 | |
| 1018 | - String downVectors = ""; | |
| 1019 | - for(Map<String, Object> temp : downList){//LINESTRING( | |
| 1020 | - vec = temp.get("sectionBsectionVector").toString(); | |
| 1021 | - downVectors += vec.subSequence(11, vec.length() - 2) + " "; | |
| 1022 | - } | |
| 1023 | - | |
| 1024 | - | |
| 1025 | - rs.put("up", upVectors); | |
| 1026 | - //上行gcj | |
| 1027 | - rs.put("up_gcj", BdToGcjString(upVectors)); | |
| 1028 | - rs.put("down", downVectors); | |
| 1029 | - //下行gcj | |
| 1030 | - rs.put("down_gcj", BdToGcjString(downVectors)); | |
| 1031 | - rs.put("lineId", lineId); | |
| 1032 | - | |
| 1033 | - return rs; | |
| 1034 | - } | |
| 1035 | - | |
| 1036 | - /** | |
| 1037 | - * | |
| 1038 | - * @Title: BdToGcjString | |
| 1039 | - * @Description: TODO(将百度路由字符串 转 成GCJ 字符串) | |
| 1040 | - * @param @param bdStr | |
| 1041 | - * @throws | |
| 1042 | - */ | |
| 1043 | - public String BdToGcjString(String bdStr){ | |
| 1044 | - String[] array = bdStr.split(",") | |
| 1045 | - ,subArray; | |
| 1046 | - if(array.length == 0 || bdStr.length() < 2) | |
| 1047 | - return ""; | |
| 1048 | - | |
| 1049 | - String gcjStr = ""; | |
| 1050 | - TransGPS.Location location; | |
| 1051 | - for(String crd : array){ | |
| 1052 | - subArray = crd.split(" "); | |
| 1053 | - if(subArray.length != 2) | |
| 1054 | - continue; | |
| 1055 | - location = TransGPS.bd_decrypt(TransGPS.LocationMake(Double.parseDouble(subArray[0]), Double.parseDouble(subArray[1]))); | |
| 1056 | - | |
| 1057 | - gcjStr += location.getLng() + " " + location.getLat() + ","; | |
| 1058 | - } | |
| 2084 | + public List<ScheduleRealInfo> exportWaybillQp(String clZbh, String date, String line) { | |
| 2085 | + // TODO Auto-generated method stub | |
| 2086 | + ReportUtils ee = new ReportUtils(); | |
| 2087 | + ReportRelatedUtils rru = new ReportRelatedUtils(); | |
| 2088 | + List<Iterator<?>> list = new ArrayList<Iterator<?>>(); | |
| 2089 | + List<ScheduleRealInfo> scheduleRealInfos = scheduleRealInfoRepository.queryListWaybill2( clZbh,date,line); | |
| 2090 | + List<Map<String,Object>> listMap = new ArrayList<Map<String,Object>>(); | |
| 1059 | 2091 | |
| 1060 | - return gcjStr.substring(0, gcjStr.length() - 1); | |
| 1061 | - } | |
| 1062 | - public List<Map<String, String>> findLine(String line) { | |
| 1063 | - List<Line> listLine = lineRepository.findLine("%"+line+"%"); | |
| 1064 | - List<Map<String,String>> list = new ArrayList<Map<String,String>>(); | |
| 1065 | - Map<String,String> map; | |
| 1066 | - for(Line temp:listLine){ | |
| 1067 | - if(temp != null){ | |
| 1068 | - String xlName = temp.getName(); | |
| 1069 | - if(xlName.indexOf(line) != -1){ | |
| 1070 | - map = new HashMap<String, String>(); | |
| 1071 | - map.put("id", temp.getLineCode()); | |
| 1072 | - map.put("text", xlName); | |
| 1073 | - list.add(map); | |
| 1074 | - } | |
| 1075 | - } | |
| 1076 | - } | |
| 1077 | - return list; | |
| 1078 | - } | |
| 1079 | - | |
| 1080 | - public List<Map<String, String>> findLpName(String lpName) { | |
| 1081 | - List<GuideboardInfo> listLpName = guideboardInfoRepository.findLpName("%"+lpName+"%"); | |
| 1082 | - List<Map<String,String>> list = new ArrayList<Map<String,String>>(); | |
| 1083 | - Map<String,String> map; | |
| 1084 | - for(GuideboardInfo temp:listLpName){ | |
| 1085 | - if(temp != null){ | |
| 1086 | - String lp = temp.getLpName(); | |
| 1087 | - if(lp.indexOf(lpName) != -1){ | |
| 1088 | - map = new HashMap<String, String>(); | |
| 1089 | - map.put("id", lp); | |
| 1090 | - map.put("text", lp); | |
| 1091 | - list.add(map); | |
| 1092 | - } | |
| 1093 | - } | |
| 1094 | - } | |
| 1095 | - return list; | |
| 1096 | - } | |
| 1097 | - | |
| 1098 | - @Override | |
| 1099 | - public Map<String, Object> findKMBC2(String jName, String clZbh,String date) { | |
| 1100 | - List<ScheduleRealInfo> list = scheduleRealInfoRepository.queryListWaybill3(jName, clZbh , date); | |
| 1101 | - | |
| 1102 | 2092 | DecimalFormat format = new DecimalFormat("0.00"); |
| 1103 | 2093 | // int cjbc = scheduleRealInfoRepository.findCjbc(jName, clZbh, lpName); |
| 1104 | 2094 | // int ljbc = scheduleRealInfoRepository.findLjbc(jName, clZbh, lpName); |
| 1105 | 2095 | int jhbc = 0,cjbc = 0,ljbc = 0; |
| 1106 | - double jhlc = 0, yygl = 0, ksgl = 0,tempJhlc = 0; | |
| 2096 | + double jhlc = 0, yygl = 0, ksgl = 0,tempJhlc = 0,jcclc=0; | |
| 1107 | 2097 | float addMileage = 0l,remMileage = 0l; |
| 1108 | - String j_Name=""; | |
| 1109 | - Map<String,Object> map = new HashMap<String, Object>(); | |
| 1110 | - for(ScheduleRealInfo scheduleRealInfo : list){ | |
| 2098 | + | |
| 2099 | + Map<String,Object> map; | |
| 2100 | + for(ScheduleRealInfo scheduleRealInfo : scheduleRealInfos){ | |
| 1111 | 2101 | if(scheduleRealInfo != null){ |
| 1112 | - j_Name=scheduleRealInfo.getjName(); | |
| 1113 | - //计划里程(主任务过滤掉临加班次), | |
| 1114 | - //烂班里程(主任务烂班), | |
| 1115 | - //临加里程(主任务临加), | |
| 1116 | - //计划班次,烂班班次,增加班次 | |
| 1117 | - tempJhlc = scheduleRealInfo.getJhlc()==null?0:scheduleRealInfo.getJhlc(); | |
| 1118 | - if(scheduleRealInfo.isSflj()){ | |
| 1119 | - addMileage += tempJhlc; | |
| 1120 | - ljbc++; | |
| 1121 | - }else{ | |
| 1122 | - jhlc += tempJhlc; | |
| 1123 | - jhbc++; | |
| 1124 | - if(scheduleRealInfo.getStatus() == -1){ | |
| 1125 | - remMileage += tempJhlc; | |
| 1126 | - cjbc++; | |
| 1127 | - } | |
| 1128 | - } | |
| 1129 | - Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1130 | - //计算营运里程,空驶里程 | |
| 1131 | - if(childTaskPlans.isEmpty()){ | |
| 1132 | - if(scheduleRealInfo.getBcType().equals("in") || scheduleRealInfo.getBcType().equals("out") | |
| 1133 | - || scheduleRealInfo.getBcType().equals("venting")){ | |
| 1134 | - ksgl += tempJhlc; | |
| 2102 | + //计算计划里程(主任务过滤掉临加班次),烂班里程,临加里程,计划班次,烂班班次,增加班次 | |
| 2103 | + //计划里程(主任务过滤掉临加班次), | |
| 2104 | + //烂班里程(主任务烂班), | |
| 2105 | + //临加里程(主任务临加), | |
| 2106 | + //计划班次,烂班班次,增加班次 | |
| 2107 | + tempJhlc = scheduleRealInfo.getJhlc()==null?0:scheduleRealInfo.getJhlc(); | |
| 2108 | + if(scheduleRealInfo.isSflj()){ | |
| 2109 | + ljbc++; | |
| 1135 | 2110 | }else{ |
| 1136 | - yygl += tempJhlc; | |
| 1137 | - } | |
| 1138 | - }else{ | |
| 1139 | - Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1140 | - while(it.hasNext()){ | |
| 1141 | - ChildTaskPlan childTaskPlan = it.next(); | |
| 1142 | - if(childTaskPlan.getMileageType().equals("empty")){ | |
| 1143 | - ksgl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 2111 | + jhlc += tempJhlc; | |
| 2112 | + jhbc++; | |
| 2113 | + if(scheduleRealInfo.getStatus() == -1){ | |
| 2114 | + remMileage += tempJhlc; | |
| 2115 | + cjbc++; | |
| 2116 | + } | |
| 2117 | + } | |
| 2118 | + Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 2119 | + //计算营运里程,空驶里程 | |
| 2120 | + if(childTaskPlans.isEmpty()){ | |
| 2121 | + if(scheduleRealInfo.getBcType().equals("in") || scheduleRealInfo.getBcType().equals("out") | |
| 2122 | + || scheduleRealInfo.getBcType().equals("venting")){ | |
| 2123 | + ksgl += tempJhlc; | |
| 1144 | 2124 | }else{ |
| 1145 | - yygl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 2125 | + yygl += tempJhlc; | |
| 2126 | + } | |
| 2127 | + }else{ | |
| 2128 | + Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 2129 | + while(it.hasNext()){ | |
| 2130 | + ChildTaskPlan childTaskPlan = it.next(); | |
| 2131 | + if(childTaskPlan.getMileageType().equals("empty")){ | |
| 2132 | + if(scheduleRealInfo.isSflj()){ | |
| 2133 | + addMileage += tempJhlc; | |
| 2134 | + } | |
| 2135 | + ksgl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 2136 | + }else{ | |
| 2137 | + if(scheduleRealInfo.isSflj()){ | |
| 2138 | + addMileage += tempJhlc; | |
| 2139 | + } | |
| 2140 | + yygl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 2141 | + } | |
| 1146 | 2142 | } |
| 1147 | 2143 | } |
| 1148 | - } | |
| 2144 | + | |
| 2145 | + if(!(scheduleRealInfo.getBcType().equals("in")||scheduleRealInfo.getBcType().equals("out"))){ | |
| 2146 | + map = new HashMap<String, Object>(); | |
| 2147 | + try { | |
| 2148 | + map = rru.getMapValue(scheduleRealInfo); | |
| 2149 | + String zdsj = scheduleRealInfo.getZdsj(); | |
| 2150 | + String zdsjActual = scheduleRealInfo.getZdsjActual(); | |
| 2151 | + if(zdsj != null && zdsjActual != null && | |
| 2152 | + !zdsj.equals(zdsjActual)){ | |
| 2153 | + if(zdsj.compareTo(zdsjActual) > 0){ | |
| 2154 | + map.put("fast", TimeUtils.getTimeDifference(zdsj, zdsjActual)); | |
| 2155 | + map.put("slow", ""); | |
| 2156 | + } else { | |
| 2157 | + map.put("fast", ""); | |
| 2158 | + map.put("slow", TimeUtils.getTimeDifference(zdsj, zdsjActual)); | |
| 2159 | + } | |
| 2160 | + } else { | |
| 2161 | + map.put("fast", ""); | |
| 2162 | + map.put("slow", ""); | |
| 2163 | + } | |
| 2164 | + listMap.add(map); | |
| 2165 | + } catch (Exception e) { | |
| 2166 | + e.printStackTrace(); | |
| 2167 | + } | |
| 2168 | + } | |
| 1149 | 2169 | } |
| 1150 | 2170 | } |
| 1151 | - map.put("j_name", j_Name); | |
| 1152 | - map.put("jhlc", format.format(jhlc)); | |
| 1153 | - map.put("remMileage", format.format(remMileage)); | |
| 1154 | - map.put("addMileage", format.format(addMileage)); | |
| 1155 | - map.put("yygl", format.format(yygl)); | |
| 2171 | + | |
| 2172 | + //计算里程和班次数,并放入Map里 | |
| 2173 | + map = new HashMap<String, Object>(); | |
| 2174 | + map.put("jhlc", format.format(jhlc+jcclc)); | |
| 2175 | + map.put("yygljh", format.format(jhlc)); | |
| 2176 | + map.put("ssgl", format.format(remMileage)); | |
| 1156 | 2177 | map.put("ksgl", format.format(ksgl)); |
| 1157 | - map.put("realMileage", format.format(yygl+ksgl)); | |
| 2178 | + map.put("yyglsj", format.format(yygl+remMileage)); | |
| 1158 | 2179 | map.put("jhbc", jhbc); |
| 1159 | - map.put("cjbc", cjbc); | |
| 1160 | - map.put("ljbc", ljbc); | |
| 2180 | + map.put("jcclc", jcclc); | |
| 2181 | + | |
| 2182 | + map.put("ljgl", format.format(addMileage)); | |
| 2183 | + map.put("ssbc", cjbc); | |
| 2184 | + map.put("ysgl", format.format(yygl)); | |
| 1161 | 2185 | map.put("sjbc", jhbc-cjbc+ljbc); |
| 1162 | - return map; | |
| 2186 | + map.put("zgl", format.format(yygl+remMileage+ksgl+jcclc)); | |
| 2187 | + map.put("ljbc", ljbc); | |
| 2188 | + | |
| 2189 | + String path = this.getClass().getResource("/").getPath()+"static\\pages\\forms\\"; | |
| 2190 | + | |
| 2191 | + list.add(listMap.iterator()); | |
| 2192 | + ee.excelReplace(list, new Object[] { scheduleRealInfos.get(0),map }, path+"mould\\waybill_qingpu.xls", | |
| 2193 | + path+"export\\" + date+"-"+clZbh+"-行车路单.xls"); | |
| 2194 | + return scheduleRealInfos; | |
| 1163 | 2195 | } |
| 1164 | - | |
| 1165 | - | |
| 2196 | + | |
| 1166 | 2197 | @Override |
| 1167 | - public Map<String, Object> findKMBC(String jName, String clZbh, | |
| 1168 | - String lpName,String date) { | |
| 1169 | - List<ScheduleRealInfo> list = scheduleRealInfoRepository.queryListWaybill(jName, clZbh, lpName, date); | |
| 2198 | + public Map<String, Object> findKMBCQp(String clZbh, String date, String line) { | |
| 2199 | + // TODO Auto-generated method stub | |
| 2200 | + List<ScheduleRealInfo> list = scheduleRealInfoRepository.queryListWaybill2( clZbh,date,line); | |
| 1170 | 2201 | DecimalFormat format = new DecimalFormat("0.00"); |
| 1171 | 2202 | // int cjbc = scheduleRealInfoRepository.findCjbc(jName, clZbh, lpName); |
| 1172 | 2203 | // int ljbc = scheduleRealInfoRepository.findLjbc(jName, clZbh, lpName); |
| ... | ... | @@ -1182,7 +2213,6 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 1182 | 2213 | //计划班次,烂班班次,增加班次 |
| 1183 | 2214 | tempJhlc = scheduleRealInfo.getJhlc()==null?0:scheduleRealInfo.getJhlc(); |
| 1184 | 2215 | if(scheduleRealInfo.isSflj()){ |
| 1185 | - addMileage += tempJhlc; | |
| 1186 | 2216 | ljbc++; |
| 1187 | 2217 | }else{ |
| 1188 | 2218 | if( !(scheduleRealInfo.getBcType().equals("in") |
| ... | ... | @@ -1203,12 +2233,16 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 1203 | 2233 | scheduleRealInfo.getBcType().equals("out")){ |
| 1204 | 2234 | jcclc +=tempJhlc; |
| 1205 | 2235 | } |
| 2236 | + | |
| 1206 | 2237 | //主任务 放空班次属于营运 |
| 1207 | 2238 | // else if(scheduleRealInfo.getBcType().equals("venting")){ |
| 1208 | 2239 | // ksgl += tempJhlc; |
| 1209 | 2240 | // } |
| 1210 | 2241 | else{ |
| 1211 | 2242 | if(scheduleRealInfo.getStatus() != -1){ |
| 2243 | + if(scheduleRealInfo.isSflj()){ | |
| 2244 | + addMileage += tempJhlc; | |
| 2245 | + } | |
| 1212 | 2246 | yygl += tempJhlc; |
| 1213 | 2247 | } |
| 1214 | 2248 | } |
| ... | ... | @@ -1220,6 +2254,9 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 1220 | 2254 | if(childTaskPlan.isDestroy()){ |
| 1221 | 2255 | remMileage += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); |
| 1222 | 2256 | }else{ |
| 2257 | + if(scheduleRealInfo.isSflj()){ | |
| 2258 | + addMileage += tempJhlc; | |
| 2259 | + } | |
| 1223 | 2260 | ksgl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); |
| 1224 | 2261 | } |
| 1225 | 2262 | }else{ |
| ... | ... | @@ -1227,6 +2264,9 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 1227 | 2264 | remMileage += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); |
| 1228 | 2265 | // cjbc++; |
| 1229 | 2266 | }else{ |
| 2267 | + if(scheduleRealInfo.isSflj()){ | |
| 2268 | + addMileage += tempJhlc; | |
| 2269 | + } | |
| 1230 | 2270 | yygl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); |
| 1231 | 2271 | } |
| 1232 | 2272 | } |
| ... | ... | @@ -1234,113 +2274,32 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 1234 | 2274 | } |
| 1235 | 2275 | } |
| 1236 | 2276 | } |
| 1237 | - map.put("jhlc", format.format(jhlc)); | |
| 1238 | - map.put("remMileage", format.format(remMileage)); | |
| 1239 | - map.put("addMileage", format.format(addMileage)); | |
| 1240 | - map.put("yygl", format.format(yygl)); | |
| 2277 | + map.put("jhlc", format.format(jhlc+jcclc)); | |
| 2278 | + map.put("yygljh", format.format(jhlc)); | |
| 2279 | + map.put("ssgl", format.format(remMileage)); | |
| 1241 | 2280 | map.put("ksgl", format.format(ksgl)); |
| 1242 | - map.put("realMileage", format.format(yygl+ksgl+jcclc)); | |
| 2281 | + map.put("yyglsj", format.format(yygl+remMileage)); | |
| 1243 | 2282 | map.put("jhbc", jhbc); |
| 1244 | - map.put("cjbc", cjbc); | |
| 1245 | - map.put("ljbc", ljbc); | |
| 1246 | - map.put("sjbc", jhbc-cjbc+ljbc); | |
| 1247 | 2283 | map.put("jcclc", jcclc); |
| 1248 | - map.put("zkslc", format.format(ksgl+jcclc)); | |
| 1249 | - return map; | |
| 1250 | - } | |
| 1251 | - | |
| 1252 | - @Override | |
| 1253 | - public List<Map<String, Object>> account(String line, String date, | |
| 1254 | - String code,String xlName, String type) { | |
| 1255 | - List<Object[]> lsitObj = scheduleRealInfoRepository.account(line,date,code); | |
| 1256 | - List<Map<String,Object>> listMap = new ArrayList<Map<String,Object>>(); | |
| 1257 | - Map<String,Object> map; | |
| 1258 | - int i = 1; | |
| 1259 | - for(Object[] obj : lsitObj){ | |
| 1260 | - if(obj != null){ | |
| 1261 | - map = new HashMap<String,Object>(); | |
| 1262 | - map.put("num", i++); | |
| 1263 | - map.put("xlName", xlName); | |
| 1264 | - map.put("clZbh", obj[3]); | |
| 1265 | - map.put("company", obj[0]); | |
| 1266 | - map.put("requestType", "0x" + Integer.toHexString(Integer.parseInt(obj[1]+"")).toUpperCase()); | |
| 1267 | - map.put("requestTime", obj[2]); | |
| 1268 | - listMap.add(map); | |
| 1269 | - } | |
| 1270 | - } | |
| 1271 | - | |
| 1272 | - if(type != null && type.length() != 0 && type.equals("export")){ | |
| 1273 | - SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 1274 | - sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 1275 | - List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 1276 | - Map<String,Object> m = new HashMap<String, Object>(); | |
| 1277 | - ReportUtils ee = new ReportUtils(); | |
| 1278 | - Map<String, Object> typeMap = new HashMap<String, Object>(); | |
| 1279 | - typeMap.put("0xA1", "请求恢复运营"); | |
| 1280 | - typeMap.put("0xA2", "申请调档"); | |
| 1281 | - typeMap.put("0xA3", "出场请求"); | |
| 1282 | - typeMap.put("0xA5", "进场请求"); | |
| 1283 | - typeMap.put("0xA7", "加油请求"); | |
| 1284 | - typeMap.put("0x50", "车辆故障"); | |
| 1285 | - typeMap.put("0x70", "路阻报告"); | |
| 1286 | - typeMap.put("0x60", "事故报告"); | |
| 1287 | - typeMap.put("0x11", "扣证纠纷"); | |
| 1288 | - typeMap.put("0x12", "报警"); | |
| 1289 | - for(Map<String, Object> map1 : listMap){ | |
| 1290 | - map1.put("requestText", typeMap.get(map1.get("requestType"))); | |
| 1291 | - } | |
| 1292 | - try { | |
| 1293 | - listI.add(listMap.iterator()); | |
| 1294 | - String path = this.getClass().getResource("/").getPath()+"static\\pages\\forms\\"; | |
| 1295 | - ee.excelReplace(listI, new Object[] { m }, path+"mould\\account.xls", | |
| 1296 | - path+"export\\驾驶员请求台账" + sdfSimple.format(sdfMonth.parse(date)) + ".xls"); | |
| 1297 | - } catch (Exception e) { | |
| 1298 | - // TODO: handle exception | |
| 1299 | - e.printStackTrace(); | |
| 1300 | - } | |
| 1301 | - } | |
| 1302 | - | |
| 1303 | - return listMap; | |
| 1304 | - } | |
| 1305 | - | |
| 1306 | - @Override | |
| 1307 | - public List<ScheduleRealInfo> correctForm(String line, String startDate, | |
| 1308 | - String endDate, String lpName, String code, String type) { | |
| 1309 | - List<ScheduleRealInfo> list = scheduleRealInfoRepository.correctForm(line,startDate,endDate,lpName,code); | |
| 1310 | - | |
| 1311 | - if(type != null && type.length() != 0 && type.equals("export")){ | |
| 1312 | - SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 1313 | - sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 1314 | - List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 1315 | - Map<String,Object> m = new HashMap<String, Object>(); | |
| 1316 | - ReportUtils ee = new ReportUtils(); | |
| 1317 | - m.put("startDate", startDate); | |
| 1318 | - m.put("endDate", endDate); | |
| 1319 | - try { | |
| 1320 | - listI.add(list.iterator()); | |
| 1321 | - String path = this.getClass().getResource("/").getPath()+"static\\pages\\forms\\"; | |
| 1322 | - ee.excelReplace(listI, new Object[] { m }, path+"mould\\correctForm.xls", | |
| 1323 | - path+"export\\" + URLEncoder.encode("修正报表", "UTF-8") + sdfSimple.format(sdfMonth.parse(startDate)) + "-" + sdfSimple.format(sdfMonth.parse(endDate)) + ".xls"); | |
| 1324 | - } catch (Exception e) { | |
| 1325 | - // TODO: handle exception | |
| 1326 | - e.printStackTrace(); | |
| 1327 | - } | |
| 1328 | - } | |
| 1329 | 2284 | |
| 1330 | - return list; | |
| 2285 | + map.put("ljgl", format.format(addMileage)); | |
| 2286 | + map.put("ssbc", cjbc); | |
| 2287 | + map.put("ysgl", format.format(yygl)); | |
| 2288 | + map.put("sjbc", jhbc-cjbc+ljbc); | |
| 2289 | + map.put("zgl", format.format(yygl+remMileage+ksgl+jcclc)); | |
| 2290 | + map.put("ljbc", ljbc); | |
| 2291 | + return map; | |
| 1331 | 2292 | } |
| 1332 | 2293 | |
| 1333 | 2294 | @Override |
| 1334 | - public List<ScheduleRealInfo> queryListWaybill(String jName, String clZbh, | |
| 1335 | - String lpName,String date,String type) { | |
| 2295 | + public List<ScheduleRealInfo> queryListWaybillQp(String clZbh, String date, String line) { | |
| 2296 | + // TODO Auto-generated method stub | |
| 1336 | 2297 | List <ScheduleRealInfo> list=null; |
| 1337 | - if(type.equals("qp")){ | |
| 1338 | - list= scheduleRealInfoRepository.queryListWaybill2(jName,clZbh,lpName,date); | |
| 1339 | - }else{ | |
| 1340 | - list= scheduleRealInfoRepository.queryListWaybill(jName,clZbh,lpName,date); | |
| 1341 | - } | |
| 1342 | - for (int i = 0; i < list.size(); i++) { | |
| 1343 | - ScheduleRealInfo s=list.get(i); | |
| 2298 | + list= scheduleRealInfoRepository.queryListWaybill2(clZbh,date,line); | |
| 2299 | + List<ScheduleRealInfo> newList=new ArrayList<ScheduleRealInfo>(); | |
| 2300 | + for (int i = 0; i < list.size(); i++) { | |
| 2301 | + ScheduleRealInfo s=list.get(i); | |
| 2302 | + if(!(s.getBcType().equals("in")||s.getBcType().equals("out"))){ | |
| 1344 | 2303 | String remarks=""; |
| 1345 | 2304 | if(s.getRemarks()!=null){ |
| 1346 | 2305 | remarks +=s.getRemarks(); |
| ... | ... | @@ -1357,703 +2316,61 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 1357 | 2316 | } |
| 1358 | 2317 | } |
| 1359 | 2318 | s.setRemarks(remarks); |
| 2319 | + newList.add(s); | |
| 1360 | 2320 | } |
| 1361 | 2321 | |
| 1362 | - return list; | |
| 1363 | - } | |
| 1364 | - | |
| 1365 | - @Override | |
| 1366 | - public Map<String, Object> removeChildTask(Long taskId) { | |
| 1367 | - Map<String, Object> rs = new HashMap<>(); | |
| 1368 | - ChildTaskPlan chTask = cTaskPlanRepository.findOne(taskId); | |
| 1369 | - | |
| 1370 | - ScheduleRealInfo sch = dayOfSchedule.get(chTask.getSchedule().getId()); | |
| 1371 | - try { | |
| 1372 | - | |
| 1373 | - sch.getcTasks().remove(chTask); | |
| 1374 | - scheduleRealInfoRepository.save(sch); | |
| 1375 | - rs.put("status", ResponseCode.SUCCESS); | |
| 1376 | - } catch (Exception e) { | |
| 1377 | - logger.error("", e); | |
| 1378 | - rs.put("status", ResponseCode.ERROR); | |
| 1379 | - } | |
| 1380 | - return rs; | |
| 1381 | - } | |
| 1382 | - | |
| 1383 | - @Override | |
| 1384 | - public List<Map<String, Object>> statisticsDaily(String line, String date, | |
| 1385 | - String xlName) { | |
| 1386 | - List<ScheduleRealInfo> list = scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1387 | - List<Map<String,Object>> lMap = new ArrayList<Map<String,Object>>(); | |
| 1388 | - DecimalFormat format = new DecimalFormat("0.00"); | |
| 1389 | - double jhlc = 0, tempJhlc = 0,childMileage = 0; | |
| 1390 | - float sjgl = 0f,ssgl = 0f,ssgl_lz = 0f,ssgl_dm = 0f,ssgl_gz = 0f,ssgl_jf = 0f,ssgl_zs = 0f,ssgl_qr = 0f | |
| 1391 | - ,ssgl_qc = 0f,ssgl_kx = 0f,ssgl_qh = 0f,ssgl_yw = 0f,ssgl_other = 0f,ljgl = 0f; | |
| 1392 | - //班次 | |
| 1393 | - int sj_0 = 6*60+31,sj_1 = 8*60+30,sj_2 = 16*60+1,sj_3 = 18*60; | |
| 1394 | - int jhbc = 0,jhbc_m = 0,jhbc_a = 0; | |
| 1395 | - int sjbc = 0,sjbc_m = 0,sjbc_a = 0; | |
| 1396 | - int ljbc = 0,ljbc_m = 0,ljbc_a = 0; | |
| 1397 | - int fzbc = 0,fzbc_m = 0,fzbc_a = 0; | |
| 1398 | - int dtbc = 0,dtbc_m = 0,dtbc_a = 0; | |
| 1399 | - int djg = 0,djg_m = 0,djg_a = 0,djg_time = 0; | |
| 1400 | - Map<String,Object> map = new HashMap<String, Object>(); | |
| 1401 | - for(ScheduleRealInfo scheduleRealInfo: list){ | |
| 1402 | - if(scheduleRealInfo != null){ | |
| 1403 | - | |
| 1404 | - if(!(scheduleRealInfo.getBcType().equals("in") | |
| 1405 | - ||scheduleRealInfo.getBcType().equals("out")) ){ | |
| 1406 | - Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1407 | - //计算实际里程,少驶里程,计划里程=实际里程+少驶里程 | |
| 1408 | - if(childTaskPlans.isEmpty()){ | |
| 1409 | - tempJhlc = scheduleRealInfo.getJhlc()==null?0:scheduleRealInfo.getJhlc(); | |
| 1410 | - //临加公里 | |
| 1411 | - if(scheduleRealInfo.isSflj()){ | |
| 1412 | - ljgl += tempJhlc; | |
| 1413 | - }else{ | |
| 1414 | - jhlc += tempJhlc; | |
| 1415 | - } | |
| 1416 | - if(scheduleRealInfo.getStatus() == 2){ | |
| 1417 | - sjgl += tempJhlc; | |
| 1418 | - }else if(scheduleRealInfo.getStatus() == -1){ | |
| 1419 | - ssgl += tempJhlc; | |
| 1420 | - if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("路阻") != -1){ | |
| 1421 | - ssgl_lz += tempJhlc; | |
| 1422 | - }else if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("吊慢") != -1){ | |
| 1423 | - ssgl_dm += tempJhlc; | |
| 1424 | - }else if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("故障") != -1){ | |
| 1425 | - ssgl_gz += tempJhlc; | |
| 1426 | - }else if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("纠纷") != -1){ | |
| 1427 | - ssgl_jf += tempJhlc; | |
| 1428 | - }else if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("肇事") != -1){ | |
| 1429 | - ssgl_zs += tempJhlc; | |
| 1430 | - }else if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("缺人") != -1){ | |
| 1431 | - ssgl_qr += tempJhlc; | |
| 1432 | - }else if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("缺车") != -1){ | |
| 1433 | - ssgl_qc += tempJhlc; | |
| 1434 | - }else if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("客稀") != -1){ | |
| 1435 | - ssgl_kx += tempJhlc; | |
| 1436 | - }else if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("气候") != -1){ | |
| 1437 | - ssgl_qh += tempJhlc; | |
| 1438 | - }else if((scheduleRealInfo.getRemarks()==null?"":scheduleRealInfo.getRemarks()).indexOf("援外") != -1){ | |
| 1439 | - ssgl_yw += tempJhlc; | |
| 1440 | - }else{ | |
| 1441 | - ssgl_other += tempJhlc; | |
| 1442 | - } | |
| 1443 | - } | |
| 1444 | - }else{ | |
| 1445 | - Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1446 | - while(it.hasNext()){ | |
| 1447 | - ChildTaskPlan childTaskPlan = it.next(); | |
| 1448 | - childMileage = childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 1449 | - jhlc += childMileage; | |
| 1450 | - if(childTaskPlan.isDestroy()){ | |
| 1451 | - ssgl += childMileage; | |
| 1452 | - if(childTaskPlan.getDestroyReason().equals("路阻")){ | |
| 1453 | - ssgl_lz += childTaskPlan.getMileage(); | |
| 1454 | - }else if(childTaskPlan.getDestroyReason().equals("吊慢")){ | |
| 1455 | - ssgl_dm += childTaskPlan.getMileage(); | |
| 1456 | - }else if(childTaskPlan.getDestroyReason().equals("故障")){ | |
| 1457 | - ssgl_gz += childTaskPlan.getMileage(); | |
| 1458 | - }else if(childTaskPlan.getDestroyReason().equals("纠纷")){ | |
| 1459 | - ssgl_jf += childTaskPlan.getMileage(); | |
| 1460 | - }else if(childTaskPlan.getDestroyReason().equals("肇事")){ | |
| 1461 | - ssgl_zs += childTaskPlan.getMileage(); | |
| 1462 | - }else if(childTaskPlan.getDestroyReason().equals("缺人")){ | |
| 1463 | - ssgl_qr += childTaskPlan.getMileage(); | |
| 1464 | - }else if(childTaskPlan.getDestroyReason().equals("缺车")){ | |
| 1465 | - ssgl_qc += childTaskPlan.getMileage(); | |
| 1466 | - }else if(childTaskPlan.getDestroyReason().equals("客稀")){ | |
| 1467 | - ssgl_kx += childTaskPlan.getMileage(); | |
| 1468 | - }else if(childTaskPlan.getDestroyReason().equals("气候")){ | |
| 1469 | - ssgl_qh += childTaskPlan.getMileage(); | |
| 1470 | - }else if(childTaskPlan.getDestroyReason().equals("援外")){ | |
| 1471 | - ssgl_yw += childTaskPlan.getMileage(); | |
| 1472 | - }else{ | |
| 1473 | - ssgl_other += childTaskPlan.getMileage(); | |
| 1474 | - } | |
| 1475 | - }else{ | |
| 1476 | - sjgl += childMileage; | |
| 1477 | - } | |
| 1478 | - } | |
| 1479 | - } | |
| 1480 | - | |
| 1481 | - //班次 | |
| 1482 | - jhbc++; | |
| 1483 | - String[] fcsj = scheduleRealInfo.getFcsj().split(":"); | |
| 1484 | - String[] fcsjActual = (scheduleRealInfo.getFcsjActual()==null?"0:00":scheduleRealInfo.getFcsjActual()).split(":"); | |
| 1485 | - if((Integer.parseInt(fcsj[0])*60+Integer.parseInt(fcsj[1])) > sj_0 && (Integer.parseInt(fcsj[0])*60+Integer.parseInt(fcsj[1])) < sj_1){ | |
| 1486 | - jhbc_m++; | |
| 1487 | - }else if((Integer.parseInt(fcsj[0])*60+Integer.parseInt(fcsj[1])) > sj_2 && (Integer.parseInt(fcsj[0])*60+Integer.parseInt(fcsj[1])) < sj_3){ | |
| 1488 | - jhbc_a++; | |
| 1489 | - } | |
| 1490 | - if(scheduleRealInfo.getStatus() == 2){ | |
| 1491 | - sjbc++; | |
| 1492 | - if((Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) > sj_0 && (Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) < sj_1){ | |
| 1493 | - sjbc_m++; | |
| 1494 | - }else if((Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) > sj_2 && (Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) < sj_3){ | |
| 1495 | - sjbc_a++; | |
| 1496 | - } | |
| 1497 | - } | |
| 1498 | - if(scheduleRealInfo.isSflj()){ | |
| 1499 | - ljbc++; | |
| 1500 | - if((Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) > sj_0 && (Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) < sj_1){ | |
| 1501 | - ljbc_m++; | |
| 1502 | - }else if((Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) > sj_2 && (Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) < sj_3){ | |
| 1503 | - ljbc_a++; | |
| 1504 | - } | |
| 1505 | - } | |
| 1506 | - if(scheduleRealInfo.getBcType().equals("venting")){ | |
| 1507 | - fzbc++; | |
| 1508 | - if((Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) > sj_0 && (Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) < sj_1){ | |
| 1509 | - fzbc_m++; | |
| 1510 | - }else if((Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) > sj_2 && (Integer.parseInt(fcsjActual[0])*60+Integer.parseInt(fcsjActual[1])) < sj_3){ | |
| 1511 | - fzbc_a++; | |
| 1512 | - } | |
| 1513 | - } | |
| 1514 | - } | |
| 1515 | - } | |
| 1516 | - } | |
| 1517 | - map.put("xlName", xlName); | |
| 1518 | - map.put("jhlc", format.format(jhlc)); | |
| 1519 | - map.put("sjgl", format.format(sjgl)); | |
| 1520 | - map.put("ssgl", format.format(ssgl)); | |
| 1521 | - map.put("ssgl_lz", ssgl_lz==0?0:format.format(ssgl_lz)); | |
| 1522 | - map.put("ssgl_dm", ssgl_dm==0?0:format.format(ssgl_dm)); | |
| 1523 | - map.put("ssgl_gz", ssgl_gz==0?0:format.format(ssgl_gz)); | |
| 1524 | - map.put("ssgl_jf", ssgl_jf==0?0:format.format(ssgl_jf)); | |
| 1525 | - map.put("ssgl_zs", ssgl_zs==0?0:format.format(ssgl_zs)); | |
| 1526 | - map.put("ssgl_qr", ssgl_qr==0?0:format.format(ssgl_qr)); | |
| 1527 | - map.put("ssgl_qc", ssgl_qc==0?0:format.format(ssgl_qc)); | |
| 1528 | - map.put("ssgl_kx", ssgl_kx==0?0:format.format(ssgl_kx)); | |
| 1529 | - map.put("ssgl_qh", ssgl_qh==0?0:format.format(ssgl_qh)); | |
| 1530 | - map.put("ssgl_yw", ssgl_yw==0?0:format.format(ssgl_yw)); | |
| 1531 | - map.put("ssgl_other", ssgl_other==0?0:format.format(ssgl_other)); | |
| 1532 | - map.put("ljgl", ljgl==0?0:format.format(ljgl)); | |
| 1533 | - map.put("jhbc", jhbc); | |
| 1534 | - map.put("jhbc_m", jhbc_m); | |
| 1535 | - map.put("jhbc_a", jhbc_a); | |
| 1536 | - map.put("sjbc", sjbc); | |
| 1537 | - map.put("sjbc_m", sjbc_m); | |
| 1538 | - map.put("sjbc_a", sjbc_a); | |
| 1539 | - map.put("ljbc", ljbc); | |
| 1540 | - map.put("ljbc_m", ljbc_m); | |
| 1541 | - map.put("ljbc_a", ljbc_a); | |
| 1542 | - map.put("fzbc", fzbc); | |
| 1543 | - map.put("fzbc_m", fzbc_m); | |
| 1544 | - map.put("fzbc_a", fzbc_a); | |
| 1545 | - map.put("dtbc", dtbc); | |
| 1546 | - map.put("dtbc_m", dtbc_m); | |
| 1547 | - map.put("dtbc_a", dtbc_a); | |
| 1548 | - map.put("djg", djg); | |
| 1549 | - map.put("djg_m", djg_m); | |
| 1550 | - map.put("djg_a", djg_a); | |
| 1551 | - map.put("djg_time", djg_time); | |
| 1552 | - lMap.add(map); | |
| 1553 | - return lMap; | |
| 1554 | 2322 | } |
| 1555 | 2323 | |
| 1556 | - @Override | |
| 1557 | - public Map<String,Object> scheduleDaily(String line, String date) { | |
| 1558 | - Map<String,String> tempMap = null; | |
| 1559 | - List<ScheduleRealInfo> scheduleRealInfos = scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1560 | - Map<String, Object> map = new HashMap<String, Object>(); | |
| 1561 | - Double jhlc = 0.00; | |
| 1562 | - Float sjgl = 0f,ssgl = 0f,ssgl_lz = 0f,ssgl_dm = 0f,ssgl_gz = 0f,ssgl_jf = 0f,ssgl_zs = 0f,ssgl_qr = 0f | |
| 1563 | - ,ssgl_qc = 0f,ssgl_kx = 0f,ssgl_qh = 0f,ssgl_yw = 0f,ssgl_other = 0f,ljgl = 0f; | |
| 1564 | - int jhbc = 0; | |
| 1565 | - for(ScheduleRealInfo scheduleRealInfo:scheduleRealInfos){ | |
| 1566 | - if(scheduleRealInfo != null){ | |
| 1567 | - //计算里程(包括子任务) | |
| 1568 | - jhlc += scheduleRealInfo.getJhlc(); | |
| 1569 | - Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1570 | - if(!childTaskPlans.isEmpty()){ | |
| 1571 | - Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1572 | - while(it.hasNext()){ | |
| 1573 | - ChildTaskPlan childTaskPlan = it.next(); | |
| 1574 | - //是否烂班,烂班就是少驶 | |
| 1575 | - if(!childTaskPlan.isDestroy()){ | |
| 1576 | - sjgl += childTaskPlan.getMileage(); | |
| 1577 | - }else{ | |
| 1578 | - ssgl += childTaskPlan.getMileage(); | |
| 1579 | - if(childTaskPlan.getDestroyReason().equals("路阻")){ | |
| 1580 | - ssgl_lz += childTaskPlan.getMileage(); | |
| 1581 | - }else if(childTaskPlan.getDestroyReason().equals("吊慢")){ | |
| 1582 | - ssgl_dm += childTaskPlan.getMileage(); | |
| 1583 | - }else if(childTaskPlan.getDestroyReason().equals("故障")){ | |
| 1584 | - ssgl_gz += childTaskPlan.getMileage(); | |
| 1585 | - }else if(childTaskPlan.getDestroyReason().equals("纠纷")){ | |
| 1586 | - ssgl_jf += childTaskPlan.getMileage(); | |
| 1587 | - }else if(childTaskPlan.getDestroyReason().equals("肇事")){ | |
| 1588 | - ssgl_zs += childTaskPlan.getMileage(); | |
| 1589 | - }else if(childTaskPlan.getDestroyReason().equals("缺人")){ | |
| 1590 | - ssgl_qr += childTaskPlan.getMileage(); | |
| 1591 | - }else if(childTaskPlan.getDestroyReason().equals("缺车")){ | |
| 1592 | - ssgl_qc += childTaskPlan.getMileage(); | |
| 1593 | - }else if(childTaskPlan.getDestroyReason().equals("客稀")){ | |
| 1594 | - ssgl_kx += childTaskPlan.getMileage(); | |
| 1595 | - }else if(childTaskPlan.getDestroyReason().equals("气候")){ | |
| 1596 | - ssgl_qh += childTaskPlan.getMileage(); | |
| 1597 | - }else if(childTaskPlan.getDestroyReason().equals("援外")){ | |
| 1598 | - ssgl_yw += childTaskPlan.getMileage(); | |
| 1599 | - }else{ | |
| 1600 | - ssgl_other += childTaskPlan.getMileage(); | |
| 1601 | - } | |
| 1602 | - } | |
| 1603 | - //临加公里 | |
| 1604 | - if(childTaskPlan.getType1().equals("临加")){ | |
| 1605 | - ljgl += childTaskPlan.getMileage(); | |
| 1606 | - } | |
| 1607 | - } | |
| 1608 | - } | |
| 1609 | - //班次 | |
| 1610 | - scheduleRealInfo.getFcsjT(); | |
| 1611 | - scheduleRealInfo.getFcsjActualTime(); | |
| 1612 | - } | |
| 1613 | - } | |
| 1614 | - map.put("jhlc", jhlc); | |
| 1615 | - map.put("sjgl", sjgl); | |
| 1616 | - map.put("ssgl", ssgl); | |
| 1617 | - map.put("ssgl_lz", ssgl_lz); | |
| 1618 | - map.put("ssgl_dm", ssgl_dm); | |
| 1619 | - map.put("ssgl_gz", ssgl_gz); | |
| 1620 | - map.put("ssgl_jf", ssgl_jf); | |
| 1621 | - map.put("ssgl_zs", ssgl_zs); | |
| 1622 | - map.put("ssgl_qr", ssgl_qr); | |
| 1623 | - map.put("ssgl_qc", ssgl_qc); | |
| 1624 | - map.put("ssgl_kx", ssgl_kx); | |
| 1625 | - map.put("ssgl_qh", ssgl_qh); | |
| 1626 | - map.put("ssgl_yw", ssgl_yw); | |
| 1627 | - map.put("ssgl_other", ssgl_other); | |
| 1628 | - map.put("ljgl", ljgl); | |
| 1629 | - | |
| 1630 | - map.put("jhbc", scheduleRealInfos.size()); | |
| 1631 | - return null; | |
| 1632 | - } | |
| 1633 | - | |
| 1634 | - @Override | |
| 1635 | - public int countByLineCodeAndDate(String xlBm, String schDate) { | |
| 1636 | - return scheduleRealInfoRepository.countByLineCodeAndDate(xlBm + "", schDate); | |
| 2324 | + return newList; | |
| 1637 | 2325 | } |
| 1638 | 2326 | |
| 1639 | 2327 | @Override |
| 1640 | - public List<ScheduleRealInfo> findByLineCodeAndDate(String xlBm, String schDate) { | |
| 1641 | - return scheduleRealInfoRepository.findByLineCodeAndDate(xlBm + "", schDate); | |
| 1642 | - } | |
| 1643 | - | |
| 1644 | - @Override | |
| 1645 | - public void deleteByLineCodeAndDate(String xlBm, String schDate) { | |
| 1646 | - scheduleRealInfoRepository.deleteByLineCodeAndDate(xlBm + "", schDate); | |
| 1647 | - } | |
| 1648 | - | |
| 1649 | - @Override | |
| 1650 | - public Long getMaxId() { | |
| 1651 | - return scheduleRealInfoRepository.getMaxId(); | |
| 1652 | - } | |
| 1653 | - | |
| 1654 | - @Override | |
| 1655 | - public List<ScheduleRealInfo> realScheduleList(String line, String date) { | |
| 1656 | - /*List<ScheduleRealInfo> listInfo = scheduleRealInfoRepository.queryUserInfo(line, date); | |
| 1657 | - List<ScheduleRealInfo> listTotal = scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1658 | - for(ScheduleRealInfo info:listInfo){ | |
| 1659 | - for(ScheduleRealInfo total:listTotal){ | |
| 1660 | - if(info.getjGh().equals(total.getjGh()) && info.getLpName().equals(total.getLpName()) && info.getClZbh().equals(total.getClZbh())){ | |
| 1661 | - | |
| 1662 | - } | |
| 1663 | - } | |
| 1664 | - }*/ | |
| 1665 | - return scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1666 | - } | |
| 1667 | - | |
| 1668 | - | |
| 1669 | - public List<Map<String,Object>> yesterdayDataList(String line,String date) { | |
| 1670 | - //前一天日期 | |
| 1671 | -// String date = sdfMonth.format(org.apache.commons.lang.time.DateUtils.addDays(new Date(), -1)); | |
| 1672 | -// String date = "2016-09-20"; | |
| 1673 | - List<Map<String,Object>> yesterdayDataList = scheduleRealInfoRepository.yesterdayDataList(line, date); | |
| 1674 | -// List<ScheduleRealInfo> list = scheduleRealInfoRepository.scheduleByDateAndLine(line, date); | |
| 1675 | - for(int x=0;x<yesterdayDataList.size();x++){ | |
| 1676 | - String jName=yesterdayDataList.get(x).get("jGh").toString(); | |
| 1677 | - String clZbh=yesterdayDataList.get(x).get("clZbh").toString(); | |
| 1678 | - List<ScheduleRealInfo> lists=scheduleRealInfoRepository.queryListWaybill3(jName, clZbh, date); | |
| 1679 | - double jhlc = 0, yygl = 0, ksgl = 0,tempJhlc = 0,jcclc=0; | |
| 1680 | - float addMileage = 0l,remMileage = 0l; | |
| 1681 | - Map<String,Object> map = new HashMap<String, Object>(); | |
| 1682 | - boolean fage=true; | |
| 1683 | - for(ScheduleRealInfo scheduleRealInfo : lists){ | |
| 1684 | - if(fage){ | |
| 1685 | - //根据线路代码获取公司 | |
| 1686 | - Line li = lineRepository.findByLineCode(scheduleRealInfo.getXlBm()); | |
| 1687 | - yesterdayDataList.get(x).put("company", li.getCompany()); | |
| 1688 | - yesterdayDataList.get(x).put("bCompany", li.getBrancheCompany()); | |
| 1689 | - fage=false; | |
| 1690 | - } | |
| 1691 | - if(scheduleRealInfo != null){ | |
| 1692 | - //计划里程(主任务过滤掉临加班次), | |
| 1693 | - //烂班里程(主任务烂班), | |
| 1694 | - //临加里程(主任务临加), | |
| 1695 | - //计划班次,烂班班次,增加班次 | |
| 1696 | - tempJhlc = scheduleRealInfo.getJhlc()==null?0:scheduleRealInfo.getJhlc(); | |
| 1697 | - if(scheduleRealInfo.isSflj()){ | |
| 1698 | - addMileage += tempJhlc; | |
| 1699 | - }else{ | |
| 1700 | - if( !(scheduleRealInfo.getBcType().equals("in") | |
| 1701 | - ||scheduleRealInfo.getBcType().equals("out")) ){ | |
| 1702 | - jhlc += tempJhlc; | |
| 1703 | - } | |
| 1704 | - | |
| 1705 | - if(scheduleRealInfo.getStatus() == -1){ | |
| 1706 | - remMileage += tempJhlc; | |
| 1707 | - } | |
| 1708 | - } | |
| 1709 | - Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1710 | - //计算营运里程,空驶里程 | |
| 1711 | - if(childTaskPlans.isEmpty()){ | |
| 1712 | - if(scheduleRealInfo.getBcType().equals("in") || | |
| 1713 | - scheduleRealInfo.getBcType().equals("out")){ | |
| 1714 | - jcclc +=tempJhlc; | |
| 1715 | - } | |
| 1716 | - //主任务 放空班次属于营运 | |
| 1717 | -// else if(scheduleRealInfo.getBcType().equals("venting")){ | |
| 1718 | -// ksgl += tempJhlc; | |
| 1719 | -// } | |
| 1720 | - else{ | |
| 1721 | - if(scheduleRealInfo.getStatus() != -1){ | |
| 1722 | - yygl += tempJhlc; | |
| 2328 | + public Map<String, Object> MapById(Long id) { | |
| 2329 | + // TODO Auto-generated method stub | |
| 2330 | + Map<String, Object> map=new HashMap<String, Object>(); | |
| 2331 | + SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM-dd HH:mm"); | |
| 2332 | + ScheduleRealInfo s=scheduleRealInfoRepository.findOne(id); | |
| 2333 | + String xlbm=s.getXlBm(); | |
| 2334 | + String fcrq=s.getScheduleDateStr(); | |
| 2335 | + | |
| 2336 | + | |
| 2337 | + map.put("xlName", s.getXlName()); | |
| 2338 | + map.put("clZbh", s.getClZbh()); | |
| 2339 | + map.put("fcsjActual", s.getFcsjActual()); | |
| 2340 | + map.put("zdzName", s.getZdzName()); | |
| 2341 | + map.put("scheduleDate", s.getScheduleDateStr()); | |
| 2342 | + String zdp="",zwdp="",wdp=""; | |
| 2343 | + | |
| 2344 | + List<DutyEmployee> list= dutyEmployeeService.getDutyEmployee(xlbm, fcrq+"00:00", fcrq+"23:59"); | |
| 2345 | + try { | |
| 2346 | + Long fcsj1=sdf.parse(fcrq+" 03:00").getTime(); | |
| 2347 | + Long fcsj2=sdf.parse(fcrq+" 11:00").getTime(); | |
| 2348 | + Long fcsj3=sdf.parse(fcrq+" 22:00").getTime(); | |
| 2349 | + for(int i=0;i<list.size();i++){ | |
| 2350 | + DutyEmployee t=list.get(i); | |
| 2351 | + Long ts=t.getTs(); | |
| 2352 | + if(ts>fcsj1&&ts<fcsj2){ | |
| 2353 | + if(zdp.indexOf(t.getuName())==-1){ | |
| 2354 | + zdp +=t.getuName()+","; | |
| 1723 | 2355 | } |
| 1724 | - } | |
| 1725 | - }else{ | |
| 1726 | - Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1727 | - while(it.hasNext()){ | |
| 1728 | - ChildTaskPlan childTaskPlan = it.next(); | |
| 1729 | - if(childTaskPlan.getMileageType().equals("empty")){ | |
| 1730 | - if(childTaskPlan.isDestroy()){ | |
| 1731 | - remMileage += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 1732 | - }else{ | |
| 1733 | - ksgl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 1734 | - } | |
| 1735 | - }else{ | |
| 1736 | - if(childTaskPlan.isDestroy()){ | |
| 1737 | - remMileage += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 1738 | - }else{ | |
| 1739 | - yygl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 1740 | - } | |
| 1741 | - } | |
| 1742 | - } | |
| 1743 | - } | |
| 1744 | - } | |
| 1745 | - } | |
| 1746 | - | |
| 1747 | - yesterdayDataList.get(x).put("totalKilometers", yygl+ksgl+jcclc); | |
| 1748 | - | |
| 1749 | - } | |
| 1750 | - | |
| 1751 | - /* for(ScheduleRealInfo scheduleRealInfo:list){ | |
| 1752 | - if(scheduleRealInfo != null){ | |
| 1753 | - for(int i=0;i<yesterdayDataList.size();i++){ | |
| 1754 | - if(scheduleRealInfo.getXlBm().equals(yesterdayDataList.get(i).get("xlBm")) && scheduleRealInfo.getClZbh().equals(yesterdayDataList.get(i).get("clZbh")) | |
| 1755 | - && scheduleRealInfo.getjGh().equals(yesterdayDataList.get(i).get("jGh"))){ | |
| 1756 | - //根据线路代码获取公司 | |
| 1757 | - Line li = lineRepository.findByLineCode(scheduleRealInfo.getXlBm()); | |
| 1758 | - yesterdayDataList.get(i).put("company", li.getCompany()); | |
| 1759 | - yesterdayDataList.get(i).put("bCompany", li.getBrancheCompany()); | |
| 1760 | - //计算总公里 | |
| 1761 | - Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1762 | - //如果没有子任务,里程就是已执行(Status=2);有子任务的,忽略主任务,子任务的烂班 | |
| 1763 | - if(childTaskPlans.isEmpty()){ | |
| 1764 | - if(scheduleRealInfo.getStatus() == 2){ | |
| 1765 | - yesterdayDataList.get(i).put("totalKilometers", scheduleRealInfo.getJhlc()==null?0.0:scheduleRealInfo.getJhlc()+(double)(yesterdayDataList.get(i).get("totalKilometers")==null?0.0:yesterdayDataList.get(i).get("totalKilometers"))); | |
| 2356 | + }else if(ts>fcsj2 && ts<fcsj3){ | |
| 2357 | + if(zwdp.indexOf(t.getuName())==-1){ | |
| 2358 | + zwdp +=t.getuName()+","; | |
| 1766 | 2359 | } |
| 1767 | 2360 | }else{ |
| 1768 | - Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1769 | - while(it.hasNext()){ | |
| 1770 | - ChildTaskPlan childTaskPlan = it.next(); | |
| 1771 | - if(!childTaskPlan.isDestroy()){ | |
| 1772 | - yesterdayDataList.get(i).put("totalKilometers", childTaskPlan.getMileage()==null?0.0:childTaskPlan.getMileage()+(double)(yesterdayDataList.get(i).get("totalKilometers")==null?0.0:yesterdayDataList.get(i).get("totalKilometers"))); | |
| 1773 | - } | |
| 2361 | + if(wdp.indexOf(t.getuName())==-1){ | |
| 2362 | + wdp +=t.getuName()+","; | |
| 1774 | 2363 | } |
| 1775 | 2364 | } |
| 1776 | - } | |
| 1777 | - } | |
| 1778 | - } | |
| 1779 | - }*/ | |
| 1780 | - //增加顺序号 | |
| 1781 | - for(int i=0;i<yesterdayDataList.size();i++){ | |
| 1782 | - if(i == 0){ | |
| 1783 | - yesterdayDataList.get(i).put("seqNumber", 1); | |
| 1784 | - }else{ | |
| 1785 | - if(yesterdayDataList.get(i-1).get("clZbh").equals(yesterdayDataList.get(i).get("clZbh"))){ | |
| 1786 | - yesterdayDataList.get(i).put("seqNumber", 1+(int)yesterdayDataList.get(i-1).get("seqNumber")); | |
| 1787 | - }else{ | |
| 1788 | - yesterdayDataList.get(i).put("seqNumber", 1); | |
| 1789 | - } | |
| 1790 | - } | |
| 1791 | - } | |
| 1792 | - return yesterdayDataList; | |
| 1793 | - } | |
| 1794 | - | |
| 1795 | - /** | |
| 1796 | - * 批量调整人车 | |
| 1797 | - */ | |
| 1798 | - @Override | |
| 1799 | - public Map<String, Object> multi_tzrc(List<ChangePersonCar> cpcs) { | |
| 1800 | - Map<String, Object> rs = new HashMap<>(); | |
| 1801 | - Set<ScheduleRealInfo> set = new HashSet<>(); | |
| 1802 | - | |
| 1803 | - ScheduleRealInfo sch; | |
| 1804 | - | |
| 1805 | - for(ChangePersonCar cpc : cpcs){ | |
| 1806 | - | |
| 1807 | - sch = dayOfSchedule.get(cpc.getSchId()); | |
| 1808 | - if(sch==null) | |
| 1809 | - continue; | |
| 1810 | - | |
| 1811 | - if(StringUtils.isNotEmpty(cpc.getJsy())){ | |
| 1812 | - //换驾驶员 | |
| 1813 | - persoChange(sch, cpc.getJsy().split("/")[0]); | |
| 1814 | - } | |
| 1815 | - | |
| 1816 | - //换售票员 | |
| 1817 | - if(StringUtils.isNotEmpty(cpc.getSpy())){ | |
| 1818 | - persoChangeSPY(sch, cpc.getSpy().split("/")[0]); | |
| 1819 | - } | |
| 1820 | - | |
| 1821 | - //换车 | |
| 1822 | - if(StringUtils.isNotEmpty(cpc.getClZbh())){ | |
| 1823 | - set.add(sch); | |
| 1824 | - set.addAll(dayOfSchedule.changeCar(sch, cpc.getClZbh())); | |
| 1825 | - } | |
| 1826 | - | |
| 1827 | - } | |
| 1828 | - rs.put("ts", set); | |
| 1829 | - rs.put("status", ResponseCode.SUCCESS); | |
| 1830 | - return rs; | |
| 1831 | - } | |
| 1832 | - | |
| 1833 | - /** | |
| 1834 | - * | |
| 1835 | - * @Title: persoChange | |
| 1836 | - * @Description: TODO(班次换驾驶员) | |
| 1837 | - */ | |
| 1838 | - public void persoChange(ScheduleRealInfo sch, String jGh){ | |
| 1839 | - if(sch.getjGh().equals(jGh)) | |
| 1840 | - return; | |
| 1841 | - String jName = BasicData.allPerson.get(jGh); | |
| 1842 | - if(StringUtils.isNotEmpty(jName)){ | |
| 1843 | - sch.setjGh(jGh); | |
| 1844 | - sch.setjName(jName); | |
| 1845 | - } | |
| 1846 | - } | |
| 1847 | - | |
| 1848 | - /** | |
| 1849 | - * | |
| 1850 | - * @Title: persoChange | |
| 1851 | - * @Description: TODO(班次换售票员) | |
| 1852 | - */ | |
| 1853 | - public void persoChangeSPY(ScheduleRealInfo sch, String sGh){ | |
| 1854 | - if(sch.getsGh().equals(sGh)) | |
| 1855 | - return; | |
| 1856 | - String sName = BasicData.allPerson.get(sGh); | |
| 1857 | - if(StringUtils.isNotEmpty(sName)){ | |
| 1858 | - sch.setsGh(sGh); | |
| 1859 | - sch.setsName(sName); | |
| 1860 | - } | |
| 1861 | - } | |
| 1862 | - | |
| 1863 | - /** | |
| 1864 | - * 批量待发调整 | |
| 1865 | - */ | |
| 1866 | - @Override | |
| 1867 | - public Map<String, Object> multi_dftz(List<DfsjChange> dfsjcs) { | |
| 1868 | - Map<String, Object> rs = new HashMap<>() | |
| 1869 | - ,tempMap = new HashMap<>(); | |
| 1870 | - List<ScheduleRealInfo> list = new ArrayList<>(); | |
| 1871 | - | |
| 1872 | - ScheduleRealInfo sch,next; | |
| 1873 | - for(DfsjChange dc : dfsjcs){ | |
| 1874 | - if(StringUtils.isEmpty(dc.getOld_dfsj()) || StringUtils.isEmpty(dc.getNew_dfsj())) | |
| 1875 | - continue; | |
| 1876 | - | |
| 1877 | - /*sch = dayOfSchedule.get(dc.getSchId()); | |
| 1878 | - if(sch==null) | |
| 1879 | - continue; | |
| 1880 | - | |
| 1881 | - sch.setDfsjAll(dc.getNew_dfsj()); | |
| 1882 | - //重新计算终点时间 | |
| 1883 | - sch.calcEndTime(); | |
| 1884 | - list.add(sch);*/ | |
| 1885 | - tempMap = outgoAdjust(dc.getSchId(),"", dc.getNew_dfsj()); | |
| 1886 | - | |
| 1887 | - if(tempMap.get("status").equals(ResponseCode.SUCCESS)){ | |
| 1888 | - list.addAll((Collection<? extends ScheduleRealInfo>) tempMap.get("ts")); | |
| 1889 | - } | |
| 1890 | - //next=dayOfSchedule.next(sch); | |
| 1891 | - /*if(next.getQdzName().equals(sch.getZdzName())){ | |
| 1892 | - next.setQdzArrDateJH(sch.getZdsj()); | |
| 1893 | - list.add(next); | |
| 1894 | - }*/ | |
| 1895 | - } | |
| 1896 | - | |
| 1897 | - rs.put("status", ResponseCode.SUCCESS); | |
| 1898 | - rs.put("ts", list); | |
| 1899 | - return rs; | |
| 1900 | - } | |
| 1901 | - | |
| 1902 | - | |
| 1903 | - @Override | |
| 1904 | - public Map<String, Object> findKMBC1(String jName, String clZbh, | |
| 1905 | - String date, String enddate) { | |
| 1906 | - List<ScheduleRealInfo> list = scheduleRealInfoRepository.queryListWaybill4(jName, clZbh, date, enddate); | |
| 1907 | - DecimalFormat format = new DecimalFormat("0.00"); | |
| 1908 | -// int cjbc = scheduleRealInfoRepository.findCjbc(jName, clZbh, lpName); | |
| 1909 | -// int ljbc = scheduleRealInfoRepository.findLjbc(jName, clZbh, lpName); | |
| 1910 | - int jhbc = 0,cjbc = 0,ljbc = 0; | |
| 1911 | - double jhlc = 0, yygl = 0, ksgl = 0,tempJhlc = 0; | |
| 1912 | - float addMileage = 0l,remMileage = 0l; | |
| 1913 | - Map<String,Object> map = new HashMap<String, Object>(); | |
| 1914 | - for(ScheduleRealInfo scheduleRealInfo : list){ | |
| 1915 | - if(scheduleRealInfo != null){ | |
| 1916 | - //计划里程(主任务过滤掉临加班次), | |
| 1917 | - //烂班里程(主任务烂班), | |
| 1918 | - //临加里程(主任务临加), | |
| 1919 | - //计划班次,烂班班次,增加班次 | |
| 1920 | - tempJhlc = scheduleRealInfo.getJhlc()==null?0:scheduleRealInfo.getJhlc(); | |
| 1921 | - if(scheduleRealInfo.isSflj()){ | |
| 1922 | - addMileage += tempJhlc; | |
| 1923 | - ljbc++; | |
| 1924 | - }else{ | |
| 1925 | - jhlc += tempJhlc; | |
| 1926 | - jhbc++; | |
| 1927 | - if(scheduleRealInfo.getStatus() == -1){ | |
| 1928 | - remMileage += tempJhlc; | |
| 1929 | - cjbc++; | |
| 1930 | - } | |
| 1931 | - } | |
| 1932 | - Set<ChildTaskPlan> childTaskPlans = scheduleRealInfo.getcTasks(); | |
| 1933 | - //计算营运里程,空驶里程 | |
| 1934 | - if(childTaskPlans.isEmpty()){ | |
| 1935 | - if(scheduleRealInfo.getBcType().equals("in") || scheduleRealInfo.getBcType().equals("out") | |
| 1936 | - || scheduleRealInfo.getBcType().equals("venting")){ | |
| 1937 | - ksgl += tempJhlc; | |
| 1938 | - }else{ | |
| 1939 | - yygl += tempJhlc; | |
| 1940 | - } | |
| 1941 | - }else{ | |
| 1942 | - Iterator<ChildTaskPlan> it = childTaskPlans.iterator(); | |
| 1943 | - while(it.hasNext()){ | |
| 1944 | - ChildTaskPlan childTaskPlan = it.next(); | |
| 1945 | - if(childTaskPlan.getMileageType().equals("empty")){ | |
| 1946 | - ksgl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 1947 | - }else{ | |
| 1948 | - yygl += childTaskPlan.getMileage()==null?0:childTaskPlan.getMileage(); | |
| 1949 | - } | |
| 1950 | 2365 | } |
| 2366 | + } catch (ParseException e) { | |
| 2367 | + // TODO Auto-generated catch block | |
| 2368 | + e.printStackTrace(); | |
| 1951 | 2369 | } |
| 1952 | - } | |
| 1953 | - } | |
| 1954 | - map.put("jhlc", format.format(jhlc)); | |
| 1955 | - map.put("remMileage", format.format(remMileage)); | |
| 1956 | - map.put("addMileage", format.format(addMileage)); | |
| 1957 | - map.put("yygl", format.format(yygl)); | |
| 1958 | - map.put("ksgl", format.format(ksgl)); | |
| 1959 | - map.put("realMileage", format.format(yygl+ksgl)); | |
| 1960 | - map.put("jhbc", jhbc); | |
| 1961 | - map.put("cjbc", cjbc); | |
| 1962 | - map.put("ljbc", ljbc); | |
| 1963 | - map.put("sjbc", jhbc-cjbc+ljbc); | |
| 1964 | - return map; | |
| 1965 | - } | |
| 1966 | - | |
| 1967 | - /** | |
| 1968 | - * 调整班次类型 | |
| 1969 | - * @param id | |
| 1970 | - * @param bcType | |
| 1971 | - * @param remarks | |
| 1972 | - * @return | |
| 1973 | - */ | |
| 1974 | - @Override | |
| 1975 | - public Map<String, Object> changeBcType(Long id, String bcType, String remarks) { | |
| 1976 | - Map<String, Object> rs = new HashMap<>(); | |
| 1977 | - | |
| 1978 | - try { | |
| 1979 | - ScheduleRealInfo sch = dayOfSchedule.get(id); | |
| 1980 | - if(sch != null){ | |
| 1981 | - sch.setBcType(bcType); | |
| 1982 | - sch.addRemarks(remarks); | |
| 1983 | - //有时间记录一下相关变更数据 | |
| 1984 | - rs.put("status", ResponseCode.SUCCESS); | |
| 1985 | - rs.put("t", sch); | |
| 1986 | - } | |
| 1987 | - } catch (Exception e) { | |
| 1988 | - logger.error("", e); | |
| 1989 | - rs.put("status", ResponseCode.ERROR); | |
| 1990 | - } | |
| 1991 | - | |
| 1992 | - return rs; | |
| 1993 | - } | |
| 1994 | - | |
| 1995 | - @Override | |
| 1996 | - public Map<String, Object> historySave(ScheduleRealInfo sch) { | |
| 1997 | - Map<String, Object> rs = new HashMap<>(); | |
| 1998 | - rs.put("status", ResponseCode.ERROR); | |
| 1999 | - | |
| 2000 | - ScheduleRealInfo oldSch = super.findById(sch.getId()); | |
| 2001 | - //修改车辆 | |
| 2002 | - if(!oldSch.getClZbh().equals(sch.getClZbh())){ | |
| 2003 | - Set<String> allCar=BasicData.deviceId2NbbmMap.values(); | |
| 2004 | - if(!allCar.contains(sch.getClZbh())){ | |
| 2005 | - rs.put("msg", "无效的车辆自编号"); | |
| 2006 | - return rs; | |
| 2007 | - } | |
| 2008 | - else | |
| 2009 | - oldSch.setClZbh(sch.getClZbh()); | |
| 2010 | - } | |
| 2011 | - | |
| 2012 | - //修改驾驶员 | |
| 2013 | - if(!oldSch.getjGh().equals(sch.getjGh())){ | |
| 2014 | - Map<String, String> allPer = BasicData.allPerson; | |
| 2015 | - if(!allPer.containsKey(sch.getjGh())){ | |
| 2016 | - rs.put("msg", "无效的驾驶员"); | |
| 2017 | - return rs; | |
| 2018 | - } | |
| 2019 | - else{ | |
| 2020 | - oldSch.setjGh(sch.getjGh()); | |
| 2021 | - oldSch.setjName(allPer.get(oldSch.getjGh())); | |
| 2022 | - } | |
| 2023 | - } | |
| 2024 | - | |
| 2025 | - //修改售票员 | |
| 2026 | -/* if(!oldSch.getsGh().equals(sch.getsGh())){ | |
| 2027 | - Map<String, String> allPer = BasicData.allPerson; | |
| 2028 | - | |
| 2029 | - if(StringUtils.isNotEmpty(sch.getsGh())){ | |
| 2030 | - if(!allPer.containsKey(sch.getsGh())){ | |
| 2031 | - rs.put("msg", "无效的售票员"); | |
| 2032 | - return rs; | |
| 2033 | - } | |
| 2034 | - } | |
| 2035 | - oldSch.setsGh(sch.getsGh()); | |
| 2036 | - oldSch.setsName(allPer.get(oldSch.getsGh())); | |
| 2037 | - }*/ | |
| 2038 | - | |
| 2039 | - //待发时间 | |
| 2040 | - oldSch.setDfsj(sch.getDfsj()); | |
| 2041 | - //实发时间 | |
| 2042 | - oldSch.setFcsjActual(sch.getFcsjActual()); | |
| 2043 | - //实际终点 | |
| 2044 | - oldSch.setZdsjActual(sch.getZdsjActual()); | |
| 2045 | - //备注 | |
| 2046 | - oldSch.setRemarks(sch.getRemarks()); | |
| 2047 | - | |
| 2048 | - scheduleRealInfoRepository.save(oldSch); | |
| 2049 | - rs.put("status", ResponseCode.SUCCESS); | |
| 2050 | - return rs; | |
| 2051 | - } | |
| 2052 | - | |
| 2053 | - @Override | |
| 2054 | - public List<Map<String, Object>> yesterdayDataList(String line) { | |
| 2055 | - // TODO Auto-generated method stub | |
| 2056 | - return null; | |
| 2370 | + map.put("zdp", zdp); | |
| 2371 | + map.put("zwdp", zwdp); | |
| 2372 | + map.put("wdp", wdp); | |
| 2373 | + return map; | |
| 2057 | 2374 | } |
| 2058 | 2375 | |
| 2059 | -} | |
| 2376 | +} | |
| 2060 | 2377 | \ No newline at end of file | ... | ... |
src/main/java/com/bsth/service/schedule/PeopleCarPlanServiceImpl.java
| ... | ... | @@ -17,6 +17,7 @@ import java.util.List; |
| 17 | 17 | import java.util.Map; |
| 18 | 18 | import java.util.Set; |
| 19 | 19 | |
| 20 | +import org.drools.compiler.lang.DRL5Expressions.type_return; | |
| 20 | 21 | import org.springframework.beans.factory.annotation.Autowired; |
| 21 | 22 | import org.springframework.jdbc.core.JdbcTemplate; |
| 22 | 23 | import org.springframework.jdbc.core.RowMapper; |
| ... | ... | @@ -1012,6 +1013,7 @@ public class PeopleCarPlanServiceImpl implements PeopleCarPlanService { |
| 1012 | 1013 | String line = map.get("line").toString(); |
| 1013 | 1014 | String date = map.get("date").toString(); |
| 1014 | 1015 | String code = map.get("code").toString(); |
| 1016 | + String type = map.get("type").toString(); | |
| 1015 | 1017 | |
| 1016 | 1018 | if(date.length() == 0) |
| 1017 | 1019 | date = new SimpleDateFormat("yyyy-MM-dd").format(new Date()); |
| ... | ... | @@ -1042,8 +1044,8 @@ public class PeopleCarPlanServiceImpl implements PeopleCarPlanService { |
| 1042 | 1044 | if(company.length() != 0){ |
| 1043 | 1045 | sql += " and gs_bm = '"+company+"' and fgs_bm = '"+subCompany+"'"; |
| 1044 | 1046 | } |
| 1045 | - sql += " order by fcsj"; | |
| 1046 | - | |
| 1047 | + sql += " order by xl_name, fcsj"; | |
| 1048 | + | |
| 1047 | 1049 | list = jdbcTemplate.query(sql, |
| 1048 | 1050 | new RowMapper<Map<String, Object>>(){ |
| 1049 | 1051 | @Override |
| ... | ... | @@ -1072,8 +1074,13 @@ public class PeopleCarPlanServiceImpl implements PeopleCarPlanService { |
| 1072 | 1074 | e.printStackTrace(); |
| 1073 | 1075 | } |
| 1074 | 1076 | |
| 1077 | + List<Map<String, Object>> tempList = new ArrayList<Map<String, Object>>(); | |
| 1078 | + List<String> keyList = new ArrayList<String>(); | |
| 1075 | 1079 | for(Map<String, Object> m : list){ |
| 1076 | 1080 | String key = m.get("line") + "/" + m.get("clZbh") + "/" + m.get("jGh") + "/" + m.get("jName"); |
| 1081 | + if(!keyList.contains(m.get("line").toString())){ | |
| 1082 | + keyList.add(m.get("line").toString()); | |
| 1083 | + } | |
| 1077 | 1084 | if(!keyMap.containsKey(key)) |
| 1078 | 1085 | keyMap.put(key, new ArrayList<Map<String, Object>>()); |
| 1079 | 1086 | keyMap.get(key).add(m); |
| ... | ... | @@ -1120,7 +1127,58 @@ public class PeopleCarPlanServiceImpl implements PeopleCarPlanService { |
| 1120 | 1127 | tempMap.put("sjf", sjf); |
| 1121 | 1128 | tempMap.put("wqr", wqr); |
| 1122 | 1129 | tempMap.put("workList", keyMap.get(key)); |
| 1123 | - resList.add(tempMap); | |
| 1130 | + tempList.add(tempMap); | |
| 1131 | + } | |
| 1132 | + | |
| 1133 | + for(String key : keyList){ | |
| 1134 | + for(Map<String, Object> m : tempList){ | |
| 1135 | + if(key.equals(m.get("line").toString())){ | |
| 1136 | + resList.add(m); | |
| 1137 | + } | |
| 1138 | + } | |
| 1139 | + } | |
| 1140 | + | |
| 1141 | + if(type.equals("export")){ | |
| 1142 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 1143 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 1144 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 1145 | + Map<String,Object> m = new HashMap<String, Object>(); | |
| 1146 | + ReportUtils ee = new ReportUtils(); | |
| 1147 | + try { | |
| 1148 | + listI.add(resList.iterator()); | |
| 1149 | + String path = this.getClass().getResource("/").getPath()+"static\\pages\\forms\\"; | |
| 1150 | + ee.excelReplace(listI, new Object[] { m }, path+"mould\\commandState.xls", | |
| 1151 | + path+"export\\指令状态分析" + sdfSimple.format(sdfMonth.parse(date)) + ".xls"); | |
| 1152 | + } catch (Exception e) { | |
| 1153 | + // TODO: handle exception | |
| 1154 | + e.printStackTrace(); | |
| 1155 | + } | |
| 1156 | + } | |
| 1157 | + | |
| 1158 | + if(type.equals("export1")){ | |
| 1159 | + SimpleDateFormat sdfMonth = new SimpleDateFormat("yyyy-MM-dd"), | |
| 1160 | + sdfSimple = new SimpleDateFormat("yyyyMMdd"); | |
| 1161 | + List<Iterator<?>> listI = new ArrayList<Iterator<?>>(); | |
| 1162 | + Map<String,Object> m = new HashMap<String, Object>(); | |
| 1163 | + ReportUtils ee = new ReportUtils(); | |
| 1164 | + String jsy = map.get("jsy").toString(); | |
| 1165 | + try { | |
| 1166 | + for(Map<String, Object> map1 : resList){ | |
| 1167 | + if(jsy.equals(map1.get("jsy").toString())){ | |
| 1168 | + List<Map<String, Object>> temp = (List<Map<String, Object>>)map1.get("workList"); | |
| 1169 | + listI.add(temp.iterator()); | |
| 1170 | + m.put("detail", "日期:" + map1.get("date") + " 公司:" + map1.get("company") | |
| 1171 | + + " 分公司:" + map1.get("subCompany") + " 线路:" + map1.get("line") | |
| 1172 | + + " 车辆:" + map1.get("clZbh") + " 人员:" + map1.get("jsy")); | |
| 1173 | + } | |
| 1174 | + } | |
| 1175 | + String path = this.getClass().getResource("/").getPath()+"static\\pages\\forms\\"; | |
| 1176 | + ee.excelReplace(listI, new Object[] { m }, path+"mould\\commandState1.xls", | |
| 1177 | + path+"export\\指令状态明细" + sdfSimple.format(sdfMonth.parse(date)) + ".xls"); | |
| 1178 | + } catch (Exception e) { | |
| 1179 | + // TODO: handle exception | |
| 1180 | + e.printStackTrace(); | |
| 1181 | + } | |
| 1124 | 1182 | } |
| 1125 | 1183 | |
| 1126 | 1184 | return resList; | ... | ... |
src/main/resources/datatools/ktrs/ttinfodetailDataInput.ktr
| 1 | -<?xml version="1.0" encoding="UTF-8"?> | |
| 2 | -<transformation> | |
| 3 | - <info> | |
| 4 | - <name>ttinfodetailDataInput</name> | |
| 5 | - <description>时刻表明细信息导入</description> | |
| 6 | - <extended_description>时刻表明细信息</extended_description> | |
| 7 | - <trans_version/> | |
| 8 | - <trans_type>Normal</trans_type> | |
| 9 | - <trans_status>0</trans_status> | |
| 10 | - <directory>/</directory> | |
| 11 | - <parameters> | |
| 12 | - </parameters> | |
| 13 | - <log> | |
| 14 | -<trans-log-table><connection/> | |
| 15 | -<schema/> | |
| 16 | -<table/> | |
| 17 | -<size_limit_lines/> | |
| 18 | -<interval/> | |
| 19 | -<timeout_days/> | |
| 20 | -<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>TRANSNAME</id><enabled>Y</enabled><name>TRANSNAME</name></field><field><id>STATUS</id><enabled>Y</enabled><name>STATUS</name></field><field><id>LINES_READ</id><enabled>Y</enabled><name>LINES_READ</name><subject/></field><field><id>LINES_WRITTEN</id><enabled>Y</enabled><name>LINES_WRITTEN</name><subject/></field><field><id>LINES_UPDATED</id><enabled>Y</enabled><name>LINES_UPDATED</name><subject/></field><field><id>LINES_INPUT</id><enabled>Y</enabled><name>LINES_INPUT</name><subject/></field><field><id>LINES_OUTPUT</id><enabled>Y</enabled><name>LINES_OUTPUT</name><subject/></field><field><id>LINES_REJECTED</id><enabled>Y</enabled><name>LINES_REJECTED</name><subject/></field><field><id>ERRORS</id><enabled>Y</enabled><name>ERRORS</name></field><field><id>STARTDATE</id><enabled>Y</enabled><name>STARTDATE</name></field><field><id>ENDDATE</id><enabled>Y</enabled><name>ENDDATE</name></field><field><id>LOGDATE</id><enabled>Y</enabled><name>LOGDATE</name></field><field><id>DEPDATE</id><enabled>Y</enabled><name>DEPDATE</name></field><field><id>REPLAYDATE</id><enabled>Y</enabled><name>REPLAYDATE</name></field><field><id>LOG_FIELD</id><enabled>Y</enabled><name>LOG_FIELD</name></field><field><id>EXECUTING_SERVER</id><enabled>N</enabled><name>EXECUTING_SERVER</name></field><field><id>EXECUTING_USER</id><enabled>N</enabled><name>EXECUTING_USER</name></field><field><id>CLIENT</id><enabled>N</enabled><name>CLIENT</name></field></trans-log-table> | |
| 21 | -<perf-log-table><connection/> | |
| 22 | -<schema/> | |
| 23 | -<table/> | |
| 24 | -<interval/> | |
| 25 | -<timeout_days/> | |
| 26 | -<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>SEQ_NR</id><enabled>Y</enabled><name>SEQ_NR</name></field><field><id>LOGDATE</id><enabled>Y</enabled><name>LOGDATE</name></field><field><id>TRANSNAME</id><enabled>Y</enabled><name>TRANSNAME</name></field><field><id>STEPNAME</id><enabled>Y</enabled><name>STEPNAME</name></field><field><id>STEP_COPY</id><enabled>Y</enabled><name>STEP_COPY</name></field><field><id>LINES_READ</id><enabled>Y</enabled><name>LINES_READ</name></field><field><id>LINES_WRITTEN</id><enabled>Y</enabled><name>LINES_WRITTEN</name></field><field><id>LINES_UPDATED</id><enabled>Y</enabled><name>LINES_UPDATED</name></field><field><id>LINES_INPUT</id><enabled>Y</enabled><name>LINES_INPUT</name></field><field><id>LINES_OUTPUT</id><enabled>Y</enabled><name>LINES_OUTPUT</name></field><field><id>LINES_REJECTED</id><enabled>Y</enabled><name>LINES_REJECTED</name></field><field><id>ERRORS</id><enabled>Y</enabled><name>ERRORS</name></field><field><id>INPUT_BUFFER_ROWS</id><enabled>Y</enabled><name>INPUT_BUFFER_ROWS</name></field><field><id>OUTPUT_BUFFER_ROWS</id><enabled>Y</enabled><name>OUTPUT_BUFFER_ROWS</name></field></perf-log-table> | |
| 27 | -<channel-log-table><connection/> | |
| 28 | -<schema/> | |
| 29 | -<table/> | |
| 30 | -<timeout_days/> | |
| 31 | -<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>LOG_DATE</id><enabled>Y</enabled><name>LOG_DATE</name></field><field><id>LOGGING_OBJECT_TYPE</id><enabled>Y</enabled><name>LOGGING_OBJECT_TYPE</name></field><field><id>OBJECT_NAME</id><enabled>Y</enabled><name>OBJECT_NAME</name></field><field><id>OBJECT_COPY</id><enabled>Y</enabled><name>OBJECT_COPY</name></field><field><id>REPOSITORY_DIRECTORY</id><enabled>Y</enabled><name>REPOSITORY_DIRECTORY</name></field><field><id>FILENAME</id><enabled>Y</enabled><name>FILENAME</name></field><field><id>OBJECT_ID</id><enabled>Y</enabled><name>OBJECT_ID</name></field><field><id>OBJECT_REVISION</id><enabled>Y</enabled><name>OBJECT_REVISION</name></field><field><id>PARENT_CHANNEL_ID</id><enabled>Y</enabled><name>PARENT_CHANNEL_ID</name></field><field><id>ROOT_CHANNEL_ID</id><enabled>Y</enabled><name>ROOT_CHANNEL_ID</name></field></channel-log-table> | |
| 32 | -<step-log-table><connection/> | |
| 33 | -<schema/> | |
| 34 | -<table/> | |
| 35 | -<timeout_days/> | |
| 36 | -<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>LOG_DATE</id><enabled>Y</enabled><name>LOG_DATE</name></field><field><id>TRANSNAME</id><enabled>Y</enabled><name>TRANSNAME</name></field><field><id>STEPNAME</id><enabled>Y</enabled><name>STEPNAME</name></field><field><id>STEP_COPY</id><enabled>Y</enabled><name>STEP_COPY</name></field><field><id>LINES_READ</id><enabled>Y</enabled><name>LINES_READ</name></field><field><id>LINES_WRITTEN</id><enabled>Y</enabled><name>LINES_WRITTEN</name></field><field><id>LINES_UPDATED</id><enabled>Y</enabled><name>LINES_UPDATED</name></field><field><id>LINES_INPUT</id><enabled>Y</enabled><name>LINES_INPUT</name></field><field><id>LINES_OUTPUT</id><enabled>Y</enabled><name>LINES_OUTPUT</name></field><field><id>LINES_REJECTED</id><enabled>Y</enabled><name>LINES_REJECTED</name></field><field><id>ERRORS</id><enabled>Y</enabled><name>ERRORS</name></field><field><id>LOG_FIELD</id><enabled>N</enabled><name>LOG_FIELD</name></field></step-log-table> | |
| 37 | -<metrics-log-table><connection/> | |
| 38 | -<schema/> | |
| 39 | -<table/> | |
| 40 | -<timeout_days/> | |
| 41 | -<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>LOG_DATE</id><enabled>Y</enabled><name>LOG_DATE</name></field><field><id>METRICS_DATE</id><enabled>Y</enabled><name>METRICS_DATE</name></field><field><id>METRICS_CODE</id><enabled>Y</enabled><name>METRICS_CODE</name></field><field><id>METRICS_DESCRIPTION</id><enabled>Y</enabled><name>METRICS_DESCRIPTION</name></field><field><id>METRICS_SUBJECT</id><enabled>Y</enabled><name>METRICS_SUBJECT</name></field><field><id>METRICS_TYPE</id><enabled>Y</enabled><name>METRICS_TYPE</name></field><field><id>METRICS_VALUE</id><enabled>Y</enabled><name>METRICS_VALUE</name></field></metrics-log-table> | |
| 42 | - </log> | |
| 43 | - <maxdate> | |
| 44 | - <connection/> | |
| 45 | - <table/> | |
| 46 | - <field/> | |
| 47 | - <offset>0.0</offset> | |
| 48 | - <maxdiff>0.0</maxdiff> | |
| 49 | - </maxdate> | |
| 50 | - <size_rowset>10000</size_rowset> | |
| 51 | - <sleep_time_empty>50</sleep_time_empty> | |
| 52 | - <sleep_time_full>50</sleep_time_full> | |
| 53 | - <unique_connections>N</unique_connections> | |
| 54 | - <feedback_shown>Y</feedback_shown> | |
| 55 | - <feedback_size>50000</feedback_size> | |
| 56 | - <using_thread_priorities>Y</using_thread_priorities> | |
| 57 | - <shared_objects_file/> | |
| 58 | - <capture_step_performance>N</capture_step_performance> | |
| 59 | - <step_performance_capturing_delay>1000</step_performance_capturing_delay> | |
| 60 | - <step_performance_capturing_size_limit>100</step_performance_capturing_size_limit> | |
| 61 | - <dependencies> | |
| 62 | - </dependencies> | |
| 63 | - <partitionschemas> | |
| 64 | - </partitionschemas> | |
| 65 | - <slaveservers> | |
| 66 | - </slaveservers> | |
| 67 | - <clusterschemas> | |
| 68 | - </clusterschemas> | |
| 69 | - <created_user>-</created_user> | |
| 70 | - <created_date>2016/06/30 12:21:57.536</created_date> | |
| 71 | - <modified_user>-</modified_user> | |
| 72 | - <modified_date>2016/06/30 12:21:57.536</modified_date> | |
| 73 | - <key_for_session_key>H4sIAAAAAAAAAAMAAAAAAAAAAAA=</key_for_session_key> | |
| 74 | - <is_key_private>N</is_key_private> | |
| 75 | - </info> | |
| 76 | - <notepads> | |
| 77 | - <notepad> | |
| 78 | - <note>字典表对应(以后直接查找表 bsth_c_sys_dictionary)
类型 代码 名称
LineTrend 0 上行
LineTrend 1 下行
ScheduleType normal 正常班次
ScheduleType out 出场
ScheduleType in 进场
ScheduleType temp 临加
ScheduleType region 区间
ScheduleType venting 放空
ScheduleType major 放大站</note> | |
| 79 | - <xloc>606</xloc> | |
| 80 | - <yloc>129</yloc> | |
| 81 | - <width>332</width> | |
| 82 | - <heigth>186</heigth> | |
| 83 | - <fontname>YaHei Consolas Hybrid</fontname> | |
| 84 | - <fontsize>12</fontsize> | |
| 85 | - <fontbold>N</fontbold> | |
| 86 | - <fontitalic>N</fontitalic> | |
| 87 | - <fontcolorred>0</fontcolorred> | |
| 88 | - <fontcolorgreen>0</fontcolorgreen> | |
| 89 | - <fontcolorblue>0</fontcolorblue> | |
| 90 | - <backgroundcolorred>255</backgroundcolorred> | |
| 91 | - <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 92 | - <backgroundcolorblue>112</backgroundcolorblue> | |
| 93 | - <bordercolorred>100</bordercolorred> | |
| 94 | - <bordercolorgreen>100</bordercolorgreen> | |
| 95 | - <bordercolorblue>100</bordercolorblue> | |
| 96 | - <drawshadow>Y</drawshadow> | |
| 97 | - </notepad> | |
| 98 | - <notepad> | |
| 99 | - <note>因为时刻表输入格式不确定性,主要因为表结构是反范式化的,
所以需要外部动态指定愿数据,头三个step动态指定愿数据

</note> | |
| 100 | - <xloc>79</xloc> | |
| 101 | - <yloc>206</yloc> | |
| 102 | - <width>346</width> | |
| 103 | - <heigth>74</heigth> | |
| 104 | - <fontname>YaHei Consolas Hybrid</fontname> | |
| 105 | - <fontsize>12</fontsize> | |
| 106 | - <fontbold>N</fontbold> | |
| 107 | - <fontitalic>N</fontitalic> | |
| 108 | - <fontcolorred>0</fontcolorred> | |
| 109 | - <fontcolorgreen>0</fontcolorgreen> | |
| 110 | - <fontcolorblue>0</fontcolorblue> | |
| 111 | - <backgroundcolorred>255</backgroundcolorred> | |
| 112 | - <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 113 | - <backgroundcolorblue>112</backgroundcolorblue> | |
| 114 | - <bordercolorred>100</bordercolorred> | |
| 115 | - <bordercolorgreen>100</bordercolorgreen> | |
| 116 | - <bordercolorblue>100</bordercolorblue> | |
| 117 | - <drawshadow>Y</drawshadow> | |
| 118 | - </notepad> | |
| 119 | - <notepad> | |
| 120 | - <note>这里有些问题
在window2012的环境下,
MySql数据库查询中如果返回中文内容的字段,这个内容乱码
解决办法,就是数据库查询全部缓存,就不乱码
linux环境下没问题</note> | |
| 121 | - <xloc>721</xloc> | |
| 122 | - <yloc>762</yloc> | |
| 123 | - <width>333</width> | |
| 124 | - <heigth>90</heigth> | |
| 125 | - <fontname>YaHei Consolas Hybrid</fontname> | |
| 126 | - <fontsize>12</fontsize> | |
| 127 | - <fontbold>N</fontbold> | |
| 128 | - <fontitalic>N</fontitalic> | |
| 129 | - <fontcolorred>0</fontcolorred> | |
| 130 | - <fontcolorgreen>0</fontcolorgreen> | |
| 131 | - <fontcolorblue>0</fontcolorblue> | |
| 132 | - <backgroundcolorred>255</backgroundcolorred> | |
| 133 | - <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 134 | - <backgroundcolorblue>112</backgroundcolorblue> | |
| 135 | - <bordercolorred>100</bordercolorred> | |
| 136 | - <bordercolorgreen>100</bordercolorgreen> | |
| 137 | - <bordercolorblue>100</bordercolorblue> | |
| 138 | - <drawshadow>Y</drawshadow> | |
| 139 | - </notepad> | |
| 140 | - <notepad> | |
| 141 | - <note>出场班次,方向有时确定不准,
空的情况下设定为0(上行)</note> | |
| 142 | - <xloc>120</xloc> | |
| 143 | - <yloc>1016</yloc> | |
| 144 | - <width>178</width> | |
| 145 | - <heigth>42</heigth> | |
| 146 | - <fontname>YaHei Consolas Hybrid</fontname> | |
| 147 | - <fontsize>12</fontsize> | |
| 148 | - <fontbold>N</fontbold> | |
| 149 | - <fontitalic>N</fontitalic> | |
| 150 | - <fontcolorred>0</fontcolorred> | |
| 151 | - <fontcolorgreen>0</fontcolorgreen> | |
| 152 | - <fontcolorblue>0</fontcolorblue> | |
| 153 | - <backgroundcolorred>255</backgroundcolorred> | |
| 154 | - <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 155 | - <backgroundcolorblue>112</backgroundcolorblue> | |
| 156 | - <bordercolorred>100</bordercolorred> | |
| 157 | - <bordercolorgreen>100</bordercolorgreen> | |
| 158 | - <bordercolorblue>100</bordercolorblue> | |
| 159 | - <drawshadow>Y</drawshadow> | |
| 160 | - </notepad> | |
| 161 | - <notepad> | |
| 162 | - <note>进场班次,方向有时确定不准,
空的情况下设定为0(上行)</note> | |
| 163 | - <xloc>578</xloc> | |
| 164 | - <yloc>1084</yloc> | |
| 165 | - <width>178</width> | |
| 166 | - <heigth>42</heigth> | |
| 167 | - <fontname>YaHei Consolas Hybrid</fontname> | |
| 168 | - <fontsize>12</fontsize> | |
| 169 | - <fontbold>N</fontbold> | |
| 170 | - <fontitalic>N</fontitalic> | |
| 171 | - <fontcolorred>0</fontcolorred> | |
| 172 | - <fontcolorgreen>0</fontcolorgreen> | |
| 173 | - <fontcolorblue>0</fontcolorblue> | |
| 174 | - <backgroundcolorred>255</backgroundcolorred> | |
| 175 | - <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 176 | - <backgroundcolorblue>112</backgroundcolorblue> | |
| 177 | - <bordercolorred>100</bordercolorred> | |
| 178 | - <bordercolorgreen>100</bordercolorgreen> | |
| 179 | - <bordercolorblue>100</bordercolorblue> | |
| 180 | - <drawshadow>Y</drawshadow> | |
| 181 | - </notepad> | |
| 182 | - </notepads> | |
| 183 | - <connection> | |
| 184 | - <name>bus_control_variable</name> | |
| 185 | - <server>${v_db_ip}</server> | |
| 186 | - <type>MYSQL</type> | |
| 187 | - <access>Native</access> | |
| 188 | - <database>${v_db_dname}</database> | |
| 189 | - <port>3306</port> | |
| 190 | - <username>${v_db_uname}</username> | |
| 191 | - <password>${v_db_pwd}</password> | |
| 192 | - <servername/> | |
| 193 | - <data_tablespace/> | |
| 194 | - <index_tablespace/> | |
| 195 | - <attributes> | |
| 196 | - <attribute><code>EXTRA_OPTION_MYSQL.characterEncoding</code><attribute>utf8</attribute></attribute> | |
| 197 | - <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 198 | - <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 199 | - <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 200 | - <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 201 | - <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 202 | - <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute> | |
| 203 | - <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 204 | - <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 205 | - <attribute><code>STREAM_RESULTS</code><attribute>N</attribute></attribute> | |
| 206 | - <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 207 | - <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 208 | - <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 209 | - </attributes> | |
| 210 | - </connection> | |
| 211 | - <connection> | |
| 212 | - <name>bus_control_公司_201</name> | |
| 213 | - <server>localhost</server> | |
| 214 | - <type>MYSQL</type> | |
| 215 | - <access>Native</access> | |
| 216 | - <database>control</database> | |
| 217 | - <port>3306</port> | |
| 218 | - <username>root</username> | |
| 219 | - <password>Encrypted </password> | |
| 220 | - <servername/> | |
| 221 | - <data_tablespace/> | |
| 222 | - <index_tablespace/> | |
| 223 | - <attributes> | |
| 224 | - <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 225 | - <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 226 | - <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 227 | - <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 228 | - <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 229 | - <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute> | |
| 230 | - <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 231 | - <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 232 | - <attribute><code>STREAM_RESULTS</code><attribute>N</attribute></attribute> | |
| 233 | - <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 234 | - <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 235 | - <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 236 | - </attributes> | |
| 237 | - </connection> | |
| 238 | - <connection> | |
| 239 | - <name>bus_control_本机</name> | |
| 240 | - <server>localhost</server> | |
| 241 | - <type>MYSQL</type> | |
| 242 | - <access>Native</access> | |
| 243 | - <database>control</database> | |
| 244 | - <port>3306</port> | |
| 245 | - <username>root</username> | |
| 246 | - <password>Encrypted </password> | |
| 247 | - <servername/> | |
| 248 | - <data_tablespace/> | |
| 249 | - <index_tablespace/> | |
| 250 | - <attributes> | |
| 251 | - <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 252 | - <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 253 | - <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 254 | - <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 255 | - <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 256 | - <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute> | |
| 257 | - <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 258 | - <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 259 | - <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute> | |
| 260 | - <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 261 | - <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 262 | - <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 263 | - </attributes> | |
| 264 | - </connection> | |
| 265 | - <connection> | |
| 266 | - <name>xlab_mysql_youle</name> | |
| 267 | - <server>101.231.124.8</server> | |
| 268 | - <type>MYSQL</type> | |
| 269 | - <access>Native</access> | |
| 270 | - <database>xlab_youle</database> | |
| 271 | - <port>45687</port> | |
| 272 | - <username>xlab-youle</username> | |
| 273 | - <password>Encrypted 2be98afc86aa78a88aa1be369d187a3df</password> | |
| 274 | - <servername/> | |
| 275 | - <data_tablespace/> | |
| 276 | - <index_tablespace/> | |
| 277 | - <attributes> | |
| 278 | - <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 279 | - <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 280 | - <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 281 | - <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 282 | - <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 283 | - <attribute><code>PORT_NUMBER</code><attribute>45687</attribute></attribute> | |
| 284 | - <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 285 | - <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 286 | - <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute> | |
| 287 | - <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>N</attribute></attribute> | |
| 288 | - <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>N</attribute></attribute> | |
| 289 | - <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 290 | - </attributes> | |
| 291 | - </connection> | |
| 292 | - <connection> | |
| 293 | - <name>xlab_mysql_youle(本机)</name> | |
| 294 | - <server>localhost</server> | |
| 295 | - <type>MYSQL</type> | |
| 296 | - <access>Native</access> | |
| 297 | - <database>xlab_youle</database> | |
| 298 | - <port>3306</port> | |
| 299 | - <username>root</username> | |
| 300 | - <password>Encrypted </password> | |
| 301 | - <servername/> | |
| 302 | - <data_tablespace/> | |
| 303 | - <index_tablespace/> | |
| 304 | - <attributes> | |
| 305 | - <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 306 | - <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 307 | - <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 308 | - <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 309 | - <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 310 | - <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute> | |
| 311 | - <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 312 | - <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 313 | - <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute> | |
| 314 | - <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>N</attribute></attribute> | |
| 315 | - <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>N</attribute></attribute> | |
| 316 | - <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 317 | - </attributes> | |
| 318 | - </connection> | |
| 319 | - <connection> | |
| 320 | - <name>xlab_youle</name> | |
| 321 | - <server/> | |
| 322 | - <type>MYSQL</type> | |
| 323 | - <access>JNDI</access> | |
| 324 | - <database>xlab_youle</database> | |
| 325 | - <port>1521</port> | |
| 326 | - <username/> | |
| 327 | - <password>Encrypted </password> | |
| 328 | - <servername/> | |
| 329 | - <data_tablespace/> | |
| 330 | - <index_tablespace/> | |
| 331 | - <attributes> | |
| 332 | - <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 333 | - <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 334 | - <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 335 | - <attribute><code>PORT_NUMBER</code><attribute>1521</attribute></attribute> | |
| 336 | - <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 337 | - <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 338 | - <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute> | |
| 339 | - <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 340 | - <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 341 | - <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 342 | - </attributes> | |
| 343 | - </connection> | |
| 344 | - <order> | |
| 345 | - <hop> <from>时刻表明细信息Excel输入</from><to>班次数据范式化</to><enabled>Y</enabled> </hop> | |
| 346 | - <hop> <from>添加发车顺序号</from><to>过滤记录(发车时间为空)</to><enabled>Y</enabled> </hop> | |
| 347 | - <hop> <from>过滤记录(发车时间为空)</from><to>添加对应班次数</to><enabled>Y</enabled> </hop> | |
| 348 | - <hop> <from>添加对应班次数</from><to>处理数据</to><enabled>Y</enabled> </hop> | |
| 349 | - <hop> <from>处理数据</from><to>分组各个路牌的站</to><enabled>Y</enabled> </hop> | |
| 350 | - <hop> <from>查找时刻表基础信息关联</from><to>查找路牌关联</to><enabled>Y</enabled> </hop> | |
| 351 | - <hop> <from>查找线路关联</from><to>查找时刻表基础信息关联</to><enabled>Y</enabled> </hop> | |
| 352 | - <hop> <from>上下行字典</from><to>班次类型字典</to><enabled>Y</enabled> </hop> | |
| 353 | - <hop> <from>上下行字典 2</from><to>班次类型字典 2</to><enabled>Y</enabled> </hop> | |
| 354 | - <hop> <from>上下行字典 3</from><to>班次类型字典 3</to><enabled>Y</enabled> </hop> | |
| 355 | - <hop> <from>匹配上下行正常班次里程时间</from><to>类型修正</to><enabled>Y</enabled> </hop> | |
| 356 | - <hop> <from>按照班次类型过滤数据1</from><to>按照班次类型过滤数据2</to><enabled>Y</enabled> </hop> | |
| 357 | - <hop> <from>按照班次类型过滤数据1</from><to>正常班次数据</to><enabled>Y</enabled> </hop> | |
| 358 | - <hop> <from>按照班次类型过滤数据2</from><to>出场班次数据</to><enabled>Y</enabled> </hop> | |
| 359 | - <hop> <from>按照班次类型过滤数据2</from><to>进场班次数据</to><enabled>Y</enabled> </hop> | |
| 360 | - <hop> <from>查找线路上下行里程时间</from><to>匹配上下行正常班次里程时间</to><enabled>Y</enabled> </hop> | |
| 361 | - <hop> <from>查找终点站关联</from><to>上下行字典</to><enabled>Y</enabled> </hop> | |
| 362 | - <hop> <from>查找起点站关联并确定上下行</from><to>查找终点站关联</to><enabled>Y</enabled> </hop> | |
| 363 | - <hop> <from>正常班次_处理数据</from><to>查找起点站关联并确定上下行</to><enabled>Y</enabled> </hop> | |
| 364 | - <hop> <from>正常班次数据</from><to>正常班次_处理数据</to><enabled>Y</enabled> </hop> | |
| 365 | - <hop> <from>班次类型字典</from><to>查找线路上下行里程时间</to><enabled>Y</enabled> </hop> | |
| 366 | - <hop> <from>班次类型字典 2</from><to>查找线路出场里程时间</to><enabled>Y</enabled> </hop> | |
| 367 | - <hop> <from>班次类型字典 3</from><to>查找线路进场里程时间</to><enabled>Y</enabled> </hop> | |
| 368 | - <hop> <from>查找路牌关联</from><to>计算班次类型</to><enabled>Y</enabled> </hop> | |
| 369 | - <hop> <from>计算班次类型</from><to>按照班次类型过滤数据1</to><enabled>Y</enabled> </hop> | |
| 370 | - <hop> <from>出场班次数据</from><to>查找停车场1</to><enabled>Y</enabled> </hop> | |
| 371 | - <hop> <from>查找停车场1</from><to>出场班次_确定终点站名字</to><enabled>Y</enabled> </hop> | |
| 372 | - <hop> <from>出场班次_确定终点站名字</from><to>查找出场终点站关联并确定上下行</to><enabled>Y</enabled> </hop> | |
| 373 | - <hop> <from>查找出场终点站关联并确定上下行</from><to>上下行字典 2</to><enabled>Y</enabled> </hop> | |
| 374 | - <hop> <from>进场班次数据</from><to>查找停车场2</to><enabled>Y</enabled> </hop> | |
| 375 | - <hop> <from>查找停车场2</from><to>进场班次_确定起点站名字</to><enabled>Y</enabled> </hop> | |
| 376 | - <hop> <from>进场班次_确定起点站名字</from><to>查找进场班次上一个班次的线路方向</to><enabled>Y</enabled> </hop> | |
| 377 | - <hop> <from>查找进场班次上一个班次的线路方向</from><to>查找进场班次上一个班次的终点站,并作为进场班次的起点站</to><enabled>Y</enabled> </hop> | |
| 378 | - <hop> <from>字段选择</from><to>添加发车顺序号</to><enabled>Y</enabled> </hop> | |
| 379 | - <hop> <from>分组各个路牌的站</from><to>查找线路关联</to><enabled>Y</enabled> </hop> | |
| 380 | - <hop> <from>增加时刻表名字,线路名字,停车场名字</from><to>记录关联 (笛卡尔输出)</to><enabled>Y</enabled> </hop> | |
| 381 | - <hop> <from>班次数据范式化</from><to>记录关联 (笛卡尔输出)</to><enabled>Y</enabled> </hop> | |
| 382 | - <hop> <from>记录关联 (笛卡尔输出)</from><to>字段选择</to><enabled>Y</enabled> </hop> | |
| 383 | - <hop> <from>类型修正</from><to>插入/更新bsth_c_s_ttinfo_detail</to><enabled>Y</enabled> </hop> | |
| 384 | - <hop> <from>查找进场班次上一个班次的终点站,并作为进场班次的起点站</from><to>查找进场起点站关联确定上下行</to><enabled>Y</enabled> </hop> | |
| 385 | - <hop> <from>查找进场起点站关联确定上下行</from><to>上下行字典 3</to><enabled>Y</enabled> </hop> | |
| 386 | - <hop> <from>查找线路出场里程时间</from><to>匹配出场班次里程时间</to><enabled>Y</enabled> </hop> | |
| 387 | - <hop> <from>查找线路进场里程时间</from><to>匹配进场班次里程时间</to><enabled>Y</enabled> </hop> | |
| 388 | - <hop> <from>匹配出场班次里程时间</from><to>上下行NULL判定</to><enabled>Y</enabled> </hop> | |
| 389 | - <hop> <from>上下行NULL判定</from><to>类型修正 2</to><enabled>Y</enabled> </hop> | |
| 390 | - <hop> <from>类型修正 2</from><to>插入/更新bsth_c_s_ttinfo_detail 2</to><enabled>Y</enabled> </hop> | |
| 391 | - <hop> <from>匹配进场班次里程时间</from><to>上下行判定 2</to><enabled>Y</enabled> </hop> | |
| 392 | - <hop> <from>上下行判定 2</from><to>类型修正 3</to><enabled>Y</enabled> </hop> | |
| 393 | - <hop> <from>类型修正 3</from><to>插入/更新bsth_c_s_ttinfo_detail 3</to><enabled>Y</enabled> </hop> | |
| 394 | - </order> | |
| 395 | - <step> | |
| 396 | - <name>上下行字典</name> | |
| 397 | - <type>ValueMapper</type> | |
| 398 | - <description/> | |
| 399 | - <distribute>Y</distribute> | |
| 400 | - <custom_distribution/> | |
| 401 | - <copies>1</copies> | |
| 402 | - <partitioning> | |
| 403 | - <method>none</method> | |
| 404 | - <schema_name/> | |
| 405 | - </partitioning> | |
| 406 | - <field_to_use>sxx</field_to_use> | |
| 407 | - <target_field>sxx_desc</target_field> | |
| 408 | - <non_match_default/> | |
| 409 | - <fields> | |
| 410 | - <field> | |
| 411 | - <source_value>0</source_value> | |
| 412 | - <target_value>上行</target_value> | |
| 413 | - </field> | |
| 414 | - <field> | |
| 415 | - <source_value>1</source_value> | |
| 416 | - <target_value>下行</target_value> | |
| 417 | - </field> | |
| 418 | - </fields> | |
| 419 | - <cluster_schema/> | |
| 420 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 421 | - <xloc>147</xloc> | |
| 422 | - <yloc>403</yloc> | |
| 423 | - <draw>Y</draw> | |
| 424 | - </GUI> | |
| 425 | - </step> | |
| 426 | - | |
| 427 | - <step> | |
| 428 | - <name>上下行字典 2</name> | |
| 429 | - <type>ValueMapper</type> | |
| 430 | - <description/> | |
| 431 | - <distribute>Y</distribute> | |
| 432 | - <custom_distribution/> | |
| 433 | - <copies>1</copies> | |
| 434 | - <partitioning> | |
| 435 | - <method>none</method> | |
| 436 | - <schema_name/> | |
| 437 | - </partitioning> | |
| 438 | - <field_to_use>sxx</field_to_use> | |
| 439 | - <target_field>sxx_desc</target_field> | |
| 440 | - <non_match_default/> | |
| 441 | - <fields> | |
| 442 | - <field> | |
| 443 | - <source_value>0</source_value> | |
| 444 | - <target_value>上行</target_value> | |
| 445 | - </field> | |
| 446 | - <field> | |
| 447 | - <source_value>1</source_value> | |
| 448 | - <target_value>下行</target_value> | |
| 449 | - </field> | |
| 450 | - </fields> | |
| 451 | - <cluster_schema/> | |
| 452 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 453 | - <xloc>331</xloc> | |
| 454 | - <yloc>598</yloc> | |
| 455 | - <draw>Y</draw> | |
| 456 | - </GUI> | |
| 457 | - </step> | |
| 458 | - | |
| 459 | - <step> | |
| 460 | - <name>上下行字典 3</name> | |
| 461 | - <type>ValueMapper</type> | |
| 462 | - <description/> | |
| 463 | - <distribute>Y</distribute> | |
| 464 | - <custom_distribution/> | |
| 465 | - <copies>1</copies> | |
| 466 | - <partitioning> | |
| 467 | - <method>none</method> | |
| 468 | - <schema_name/> | |
| 469 | - </partitioning> | |
| 470 | - <field_to_use>sxx</field_to_use> | |
| 471 | - <target_field>sxx_desc</target_field> | |
| 472 | - <non_match_default/> | |
| 473 | - <fields> | |
| 474 | - <field> | |
| 475 | - <source_value>0</source_value> | |
| 476 | - <target_value>上行</target_value> | |
| 477 | - </field> | |
| 478 | - <field> | |
| 479 | - <source_value>1</source_value> | |
| 480 | - <target_value>下行</target_value> | |
| 481 | - </field> | |
| 482 | - </fields> | |
| 483 | - <cluster_schema/> | |
| 484 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 485 | - <xloc>553</xloc> | |
| 486 | - <yloc>859</yloc> | |
| 487 | - <draw>Y</draw> | |
| 488 | - </GUI> | |
| 489 | - </step> | |
| 490 | - | |
| 491 | - <step> | |
| 492 | - <name>出场班次_确定终点站名字</name> | |
| 493 | - <type>ScriptValueMod</type> | |
| 494 | - <description/> | |
| 495 | - <distribute>Y</distribute> | |
| 496 | - <custom_distribution/> | |
| 497 | - <copies>1</copies> | |
| 498 | - <partitioning> | |
| 499 | - <method>none</method> | |
| 500 | - <schema_name/> | |
| 501 | - </partitioning> | |
| 502 | - <compatible>N</compatible> | |
| 503 | - <optimizationLevel>9</optimizationLevel> | |
| 504 | - <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 505 | - <jsScript_name>Script 1</jsScript_name> | |
| 506 | - <jsScript_script>//Script here

// 添加站点标识
var cc_groups = qdzgroups.split(","); // 所有班次起点站数组
var zdzname = cc_groups[gno]; // 出场班次的终点站是下个班次的起始站
var endZdtype = 'E';

var destory = 0; // 未撤销flag</jsScript_script> | |
| 507 | - </jsScript> </jsScripts> <fields> <field> <name>zdzname</name> | |
| 508 | - <rename>zdzname</rename> | |
| 509 | - <type>String</type> | |
| 510 | - <length>-1</length> | |
| 511 | - <precision>-1</precision> | |
| 512 | - <replace>N</replace> | |
| 513 | - </field> <field> <name>endZdtype</name> | |
| 514 | - <rename>endZdtype</rename> | |
| 515 | - <type>String</type> | |
| 516 | - <length>-1</length> | |
| 517 | - <precision>-1</precision> | |
| 518 | - <replace>N</replace> | |
| 519 | - </field> <field> <name>destory</name> | |
| 520 | - <rename>destory</rename> | |
| 521 | - <type>Integer</type> | |
| 522 | - <length>-1</length> | |
| 523 | - <precision>-1</precision> | |
| 524 | - <replace>N</replace> | |
| 525 | - </field> </fields> <cluster_schema/> | |
| 526 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 527 | - <xloc>575</xloc> | |
| 528 | - <yloc>502</yloc> | |
| 529 | - <draw>Y</draw> | |
| 530 | - </GUI> | |
| 531 | - </step> | |
| 532 | - | |
| 533 | - <step> | |
| 534 | - <name>出场班次数据</name> | |
| 535 | - <type>Dummy</type> | |
| 536 | - <description/> | |
| 537 | - <distribute>Y</distribute> | |
| 538 | - <custom_distribution/> | |
| 539 | - <copies>1</copies> | |
| 540 | - <partitioning> | |
| 541 | - <method>none</method> | |
| 542 | - <schema_name/> | |
| 543 | - </partitioning> | |
| 544 | - <cluster_schema/> | |
| 545 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 546 | - <xloc>869</xloc> | |
| 547 | - <yloc>504</yloc> | |
| 548 | - <draw>Y</draw> | |
| 549 | - </GUI> | |
| 550 | - </step> | |
| 551 | - | |
| 552 | - <step> | |
| 553 | - <name>分组各个路牌的站</name> | |
| 554 | - <type>GroupBy</type> | |
| 555 | - <description/> | |
| 556 | - <distribute>Y</distribute> | |
| 557 | - <custom_distribution/> | |
| 558 | - <copies>1</copies> | |
| 559 | - <partitioning> | |
| 560 | - <method>none</method> | |
| 561 | - <schema_name/> | |
| 562 | - </partitioning> | |
| 563 | - <all_rows>Y</all_rows> | |
| 564 | - <ignore_aggregate>N</ignore_aggregate> | |
| 565 | - <field_ignore/> | |
| 566 | - <directory>%%java.io.tmpdir%%</directory> | |
| 567 | - <prefix>grp</prefix> | |
| 568 | - <add_linenr>Y</add_linenr> | |
| 569 | - <linenr_fieldname>gno</linenr_fieldname> | |
| 570 | - <give_back_row>N</give_back_row> | |
| 571 | - <group> | |
| 572 | - <field> | |
| 573 | - <name>lp</name> | |
| 574 | - </field> | |
| 575 | - </group> | |
| 576 | - <fields> | |
| 577 | - <field> | |
| 578 | - <aggregate>qdzgroups</aggregate> | |
| 579 | - <subject>qdzname</subject> | |
| 580 | - <type>CONCAT_STRING</type> | |
| 581 | - <valuefield>,</valuefield> | |
| 582 | - </field> | |
| 583 | - </fields> | |
| 584 | - <cluster_schema/> | |
| 585 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 586 | - <xloc>892</xloc> | |
| 587 | - <yloc>44</yloc> | |
| 588 | - <draw>Y</draw> | |
| 589 | - </GUI> | |
| 590 | - </step> | |
| 591 | - | |
| 592 | - <step> | |
| 593 | - <name>匹配上下行正常班次里程时间</name> | |
| 594 | - <type>ScriptValueMod</type> | |
| 595 | - <description/> | |
| 596 | - <distribute>Y</distribute> | |
| 597 | - <custom_distribution/> | |
| 598 | - <copies>1</copies> | |
| 599 | - <partitioning> | |
| 600 | - <method>none</method> | |
| 601 | - <schema_name/> | |
| 602 | - </partitioning> | |
| 603 | - <compatible>N</compatible> | |
| 604 | - <optimizationLevel>9</optimizationLevel> | |
| 605 | - <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 606 | - <jsScript_name>Script 1</jsScript_name> | |
| 607 | - <jsScript_script>//Script here

var jhlc; // 计划里程
var bcsj; // 班次时间

if (sxx == 0) { // 上行
 jhlc = up_mileage;
 bcsj = up_travel_time;
} else { // sxx == 1 下行
 jhlc = down_mileage;
 bcsj = down_travel_time;
}</jsScript_script> | |
| 608 | - </jsScript> </jsScripts> <fields> <field> <name>jhlc</name> | |
| 609 | - <rename>jhlc</rename> | |
| 610 | - <type>String</type> | |
| 611 | - <length>-1</length> | |
| 612 | - <precision>-1</precision> | |
| 613 | - <replace>N</replace> | |
| 614 | - </field> <field> <name>bcsj</name> | |
| 615 | - <rename>bcsj</rename> | |
| 616 | - <type>String</type> | |
| 617 | - <length>-1</length> | |
| 618 | - <precision>-1</precision> | |
| 619 | - <replace>N</replace> | |
| 620 | - </field> </fields> <cluster_schema/> | |
| 621 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 622 | - <xloc>148</xloc> | |
| 623 | - <yloc>674</yloc> | |
| 624 | - <draw>Y</draw> | |
| 625 | - </GUI> | |
| 626 | - </step> | |
| 627 | - | |
| 628 | - <step> | |
| 629 | - <name>匹配出场班次里程时间</name> | |
| 630 | - <type>ScriptValueMod</type> | |
| 631 | - <description/> | |
| 632 | - <distribute>Y</distribute> | |
| 633 | - <custom_distribution/> | |
| 634 | - <copies>1</copies> | |
| 635 | - <partitioning> | |
| 636 | - <method>none</method> | |
| 637 | - <schema_name/> | |
| 638 | - </partitioning> | |
| 639 | - <compatible>N</compatible> | |
| 640 | - <optimizationLevel>9</optimizationLevel> | |
| 641 | - <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 642 | - <jsScript_name>Script 1</jsScript_name> | |
| 643 | - <jsScript_script>//Script here

var out_mileage; // 出场计划里程
var out_time; // 出场计划时间

if (sxx == 0) { // 上行
 out_mileage = up_out_mileage;
 out_time = up_out_timer;
} else { // sxx == 1 下行
 out_mileage = down_out_mileage;
 out_time = down_out_timer;
}



</jsScript_script> | |
| 644 | - </jsScript> </jsScripts> <fields> <field> <name>out_mileage</name> | |
| 645 | - <rename>out_mileage</rename> | |
| 646 | - <type>String</type> | |
| 647 | - <length>-1</length> | |
| 648 | - <precision>-1</precision> | |
| 649 | - <replace>N</replace> | |
| 650 | - </field> <field> <name>out_time</name> | |
| 651 | - <rename>out_time</rename> | |
| 652 | - <type>String</type> | |
| 653 | - <length>-1</length> | |
| 654 | - <precision>-1</precision> | |
| 655 | - <replace>N</replace> | |
| 656 | - </field> </fields> <cluster_schema/> | |
| 657 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 658 | - <xloc>336</xloc> | |
| 659 | - <yloc>862</yloc> | |
| 660 | - <draw>Y</draw> | |
| 661 | - </GUI> | |
| 662 | - </step> | |
| 663 | - | |
| 664 | - <step> | |
| 665 | - <name>匹配进场班次里程时间</name> | |
| 666 | - <type>ScriptValueMod</type> | |
| 667 | - <description/> | |
| 668 | - <distribute>Y</distribute> | |
| 669 | - <custom_distribution/> | |
| 670 | - <copies>1</copies> | |
| 671 | - <partitioning> | |
| 672 | - <method>none</method> | |
| 673 | - <schema_name/> | |
| 674 | - </partitioning> | |
| 675 | - <compatible>N</compatible> | |
| 676 | - <optimizationLevel>9</optimizationLevel> | |
| 677 | - <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 678 | - <jsScript_name>Script 1</jsScript_name> | |
| 679 | - <jsScript_script>//Script here

var parade_mileage; // 进场计划里程
var parade_time; // 进场计划时间

if (sxx2 == 0) { // 上行
 parade_mileage = up_in_mileage;
 parade_time = up_in_timer;
} else { // sxx == 1 下行
 parade_mileage = down_in_mileage;
 parade_time = down_in_timer;
}



</jsScript_script> | |
| 680 | - </jsScript> </jsScripts> <fields> <field> <name>parade_mileage</name> | |
| 681 | - <rename>parade_mileage</rename> | |
| 682 | - <type>String</type> | |
| 683 | - <length>-1</length> | |
| 684 | - <precision>-1</precision> | |
| 685 | - <replace>N</replace> | |
| 686 | - </field> <field> <name>parade_time</name> | |
| 687 | - <rename>parade_time</rename> | |
| 688 | - <type>String</type> | |
| 689 | - <length>-1</length> | |
| 690 | - <precision>-1</precision> | |
| 691 | - <replace>N</replace> | |
| 692 | - </field> </fields> <cluster_schema/> | |
| 693 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 694 | - <xloc>726</xloc> | |
| 695 | - <yloc>1005</yloc> | |
| 696 | - <draw>Y</draw> | |
| 697 | - </GUI> | |
| 698 | - </step> | |
| 699 | - | |
| 700 | - <step> | |
| 701 | - <name>增加时刻表名字,线路名字,停车场名字</name> | |
| 702 | - <type>DataGrid</type> | |
| 703 | - <description/> | |
| 704 | - <distribute>Y</distribute> | |
| 705 | - <custom_distribution/> | |
| 706 | - <copies>1</copies> | |
| 707 | - <partitioning> | |
| 708 | - <method>none</method> | |
| 709 | - <schema_name/> | |
| 710 | - </partitioning> | |
| 711 | - <fields> | |
| 712 | - </fields> | |
| 713 | - <data> | |
| 714 | - <line> </line> | |
| 715 | - </data> | |
| 716 | - <cluster_schema/> | |
| 717 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 718 | - <xloc>110</xloc> | |
| 719 | - <yloc>133</yloc> | |
| 720 | - <draw>Y</draw> | |
| 721 | - </GUI> | |
| 722 | - </step> | |
| 723 | - | |
| 724 | - <step> | |
| 725 | - <name>处理数据</name> | |
| 726 | - <type>ScriptValueMod</type> | |
| 727 | - <description/> | |
| 728 | - <distribute>Y</distribute> | |
| 729 | - <custom_distribution/> | |
| 730 | - <copies>1</copies> | |
| 731 | - <partitioning> | |
| 732 | - <method>none</method> | |
| 733 | - <schema_name/> | |
| 734 | - </partitioning> | |
| 735 | - <compatible>N</compatible> | |
| 736 | - <optimizationLevel>9</optimizationLevel> | |
| 737 | - <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 738 | - <jsScript_name>Script 1</jsScript_name> | |
| 739 | - <jsScript_script>//Script here

// 使用正则表达式去除站点名称中的数字
qdzname = qdzname.replace(/\d+/g,'');

// sendtime处理
var sendtime_calcu;
if (sendtime.length != 5) 
 sendtime_calcu = sendtime.substr(0, 2) + ":" + sendtime.substr(2, 2);
else 
 sendtime_calcu = sendtime;

// 设置分班
var isfb = 0;

// 设置isCanceled
var iscanceled = 0;</jsScript_script> | |
| 740 | - </jsScript> </jsScripts> <fields> <field> <name>qdzname</name> | |
| 741 | - <rename>qdzname</rename> | |
| 742 | - <type>String</type> | |
| 743 | - <length>-1</length> | |
| 744 | - <precision>-1</precision> | |
| 745 | - <replace>Y</replace> | |
| 746 | - </field> <field> <name>isfb</name> | |
| 747 | - <rename>isfb</rename> | |
| 748 | - <type>Integer</type> | |
| 749 | - <length>-1</length> | |
| 750 | - <precision>-1</precision> | |
| 751 | - <replace>N</replace> | |
| 752 | - </field> <field> <name>iscanceled</name> | |
| 753 | - <rename>iscanceled</rename> | |
| 754 | - <type>Integer</type> | |
| 755 | - <length>-1</length> | |
| 756 | - <precision>-1</precision> | |
| 757 | - <replace>N</replace> | |
| 758 | - </field> <field> <name>sendtime_calcu</name> | |
| 759 | - <rename>sendtime_calcu</rename> | |
| 760 | - <type>String</type> | |
| 761 | - <length>-1</length> | |
| 762 | - <precision>-1</precision> | |
| 763 | - <replace>N</replace> | |
| 764 | - </field> </fields> <cluster_schema/> | |
| 765 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 766 | - <xloc>788</xloc> | |
| 767 | - <yloc>44</yloc> | |
| 768 | - <draw>Y</draw> | |
| 769 | - </GUI> | |
| 770 | - </step> | |
| 771 | - | |
| 772 | - <step> | |
| 773 | - <name>字段选择</name> | |
| 774 | - <type>SelectValues</type> | |
| 775 | - <description/> | |
| 776 | - <distribute>Y</distribute> | |
| 777 | - <custom_distribution/> | |
| 778 | - <copies>1</copies> | |
| 779 | - <partitioning> | |
| 780 | - <method>none</method> | |
| 781 | - <schema_name/> | |
| 782 | - </partitioning> | |
| 783 | - <fields> <field> <name>路牌</name> | |
| 784 | - <rename>lp</rename> | |
| 785 | - <length>-2</length> | |
| 786 | - <precision>-2</precision> | |
| 787 | - </field> <field> <name>站点名称</name> | |
| 788 | - <rename>qdzname</rename> | |
| 789 | - <length>-2</length> | |
| 790 | - <precision>-2</precision> | |
| 791 | - </field> <field> <name>发车时间</name> | |
| 792 | - <rename>sendtime</rename> | |
| 793 | - <length>-2</length> | |
| 794 | - <precision>-2</precision> | |
| 795 | - </field> <select_unspecified>Y</select_unspecified> | |
| 796 | - </fields> <cluster_schema/> | |
| 797 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 798 | - <xloc>444</xloc> | |
| 799 | - <yloc>131</yloc> | |
| 800 | - <draw>Y</draw> | |
| 801 | - </GUI> | |
| 802 | - </step> | |
| 803 | - | |
| 804 | - <step> | |
| 805 | - <name>按照班次类型过滤数据1</name> | |
| 806 | - <type>FilterRows</type> | |
| 807 | - <description/> | |
| 808 | - <distribute>Y</distribute> | |
| 809 | - <custom_distribution/> | |
| 810 | - <copies>1</copies> | |
| 811 | - <partitioning> | |
| 812 | - <method>none</method> | |
| 813 | - <schema_name/> | |
| 814 | - </partitioning> | |
| 815 | -<send_true_to>正常班次数据</send_true_to> | |
| 816 | -<send_false_to>按照班次类型过滤数据2</send_false_to> | |
| 817 | - <compare> | |
| 818 | -<condition> | |
| 819 | - <negated>N</negated> | |
| 820 | - <leftvalue>bctype</leftvalue> | |
| 821 | - <function>=</function> | |
| 822 | - <rightvalue/> | |
| 823 | - <value><name>constant</name><type>String</type><text>正常班次</text><length>-1</length><precision>-1</precision><isnull>N</isnull><mask/></value> </condition> | |
| 824 | - </compare> | |
| 825 | - <cluster_schema/> | |
| 826 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 827 | - <xloc>860</xloc> | |
| 828 | - <yloc>401</yloc> | |
| 829 | - <draw>Y</draw> | |
| 830 | - </GUI> | |
| 831 | - </step> | |
| 832 | - | |
| 833 | - <step> | |
| 834 | - <name>按照班次类型过滤数据2</name> | |
| 835 | - <type>FilterRows</type> | |
| 836 | - <description/> | |
| 837 | - <distribute>Y</distribute> | |
| 838 | - <custom_distribution/> | |
| 839 | - <copies>1</copies> | |
| 840 | - <partitioning> | |
| 841 | - <method>none</method> | |
| 842 | - <schema_name/> | |
| 843 | - </partitioning> | |
| 844 | -<send_true_to>出场班次数据</send_true_to> | |
| 845 | -<send_false_to>进场班次数据</send_false_to> | |
| 846 | - <compare> | |
| 847 | -<condition> | |
| 848 | - <negated>N</negated> | |
| 849 | - <leftvalue>bctype</leftvalue> | |
| 850 | - <function>=</function> | |
| 851 | - <rightvalue/> | |
| 852 | - <value><name>constant</name><type>String</type><text>出场</text><length>-1</length><precision>-1</precision><isnull>N</isnull><mask/></value> </condition> | |
| 853 | - </compare> | |
| 854 | - <cluster_schema/> | |
| 855 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 856 | - <xloc>995</xloc> | |
| 857 | - <yloc>503</yloc> | |
| 858 | - <draw>Y</draw> | |
| 859 | - </GUI> | |
| 860 | - </step> | |
| 861 | - | |
| 862 | - <step> | |
| 863 | - <name>插入/更新bsth_c_s_ttinfo_detail</name> | |
| 864 | - <type>InsertUpdate</type> | |
| 865 | - <description/> | |
| 866 | - <distribute>Y</distribute> | |
| 867 | - <custom_distribution/> | |
| 868 | - <copies>1</copies> | |
| 869 | - <partitioning> | |
| 870 | - <method>none</method> | |
| 871 | - <schema_name/> | |
| 872 | - </partitioning> | |
| 873 | - <connection>bus_control_variable</connection> | |
| 874 | - <commit>100</commit> | |
| 875 | - <update_bypassed>N</update_bypassed> | |
| 876 | - <lookup> | |
| 877 | - <schema/> | |
| 878 | - <table>bsth_c_s_ttinfo_detail</table> | |
| 879 | - <key> | |
| 880 | - <name>xlid</name> | |
| 881 | - <field>xl</field> | |
| 882 | - <condition>=</condition> | |
| 883 | - <name2/> | |
| 884 | - </key> | |
| 885 | - <key> | |
| 886 | - <name>ttid</name> | |
| 887 | - <field>ttinfo</field> | |
| 888 | - <condition>=</condition> | |
| 889 | - <name2/> | |
| 890 | - </key> | |
| 891 | - <key> | |
| 892 | - <name>lpid</name> | |
| 893 | - <field>lp</field> | |
| 894 | - <condition>=</condition> | |
| 895 | - <name2/> | |
| 896 | - </key> | |
| 897 | - <key> | |
| 898 | - <name>fcno</name> | |
| 899 | - <field>fcno</field> | |
| 900 | - <condition>=</condition> | |
| 901 | - <name2/> | |
| 902 | - </key> | |
| 903 | - <key> | |
| 904 | - <name>bcs</name> | |
| 905 | - <field>bcs</field> | |
| 906 | - <condition>=</condition> | |
| 907 | - <name2/> | |
| 908 | - </key> | |
| 909 | - <value> | |
| 910 | - <name>lp</name> | |
| 911 | - <rename>lpid</rename> | |
| 912 | - <update>Y</update> | |
| 913 | - </value> | |
| 914 | - <value> | |
| 915 | - <name>bc_type</name> | |
| 916 | - <rename>bctype_code</rename> | |
| 917 | - <update>Y</update> | |
| 918 | - </value> | |
| 919 | - <value> | |
| 920 | - <name>bcs</name> | |
| 921 | - <rename>bcs</rename> | |
| 922 | - <update>Y</update> | |
| 923 | - </value> | |
| 924 | - <value> | |
| 925 | - <name>bcsj</name> | |
| 926 | - <rename>bcsj</rename> | |
| 927 | - <update>Y</update> | |
| 928 | - </value> | |
| 929 | - <value> | |
| 930 | - <name>fcno</name> | |
| 931 | - <rename>fcno</rename> | |
| 932 | - <update>Y</update> | |
| 933 | - </value> | |
| 934 | - <value> | |
| 935 | - <name>jhlc</name> | |
| 936 | - <rename>jhlc</rename> | |
| 937 | - <update>Y</update> | |
| 938 | - </value> | |
| 939 | - <value> | |
| 940 | - <name>fcsj</name> | |
| 941 | - <rename>sendtime_calcu</rename> | |
| 942 | - <update>Y</update> | |
| 943 | - </value> | |
| 944 | - <value> | |
| 945 | - <name>ttinfo</name> | |
| 946 | - <rename>ttid</rename> | |
| 947 | - <update>Y</update> | |
| 948 | - </value> | |
| 949 | - <value> | |
| 950 | - <name>xl</name> | |
| 951 | - <rename>xlid</rename> | |
| 952 | - <update>Y</update> | |
| 953 | - </value> | |
| 954 | - <value> | |
| 955 | - <name>qdz</name> | |
| 956 | - <rename>qdzid</rename> | |
| 957 | - <update>Y</update> | |
| 958 | - </value> | |
| 959 | - <value> | |
| 960 | - <name>zdz</name> | |
| 961 | - <rename>zdzid</rename> | |
| 962 | - <update>Y</update> | |
| 963 | - </value> | |
| 964 | - <value> | |
| 965 | - <name>xl_dir</name> | |
| 966 | - <rename>sxx</rename> | |
| 967 | - <update>Y</update> | |
| 968 | - </value> | |
| 969 | - <value> | |
| 970 | - <name>isfb</name> | |
| 971 | - <rename>isfb</rename> | |
| 972 | - <update>Y</update> | |
| 973 | - </value> | |
| 974 | - </lookup> | |
| 975 | - <cluster_schema/> | |
| 976 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 977 | - <xloc>143</xloc> | |
| 978 | - <yloc>860</yloc> | |
| 979 | - <draw>Y</draw> | |
| 980 | - </GUI> | |
| 981 | - </step> | |
| 982 | - | |
| 983 | - <step> | |
| 984 | - <name>插入/更新bsth_c_s_ttinfo_detail 2</name> | |
| 985 | - <type>InsertUpdate</type> | |
| 986 | - <description/> | |
| 987 | - <distribute>Y</distribute> | |
| 988 | - <custom_distribution/> | |
| 989 | - <copies>1</copies> | |
| 990 | - <partitioning> | |
| 991 | - <method>none</method> | |
| 992 | - <schema_name/> | |
| 993 | - </partitioning> | |
| 994 | - <connection>bus_control_variable</connection> | |
| 995 | - <commit>100</commit> | |
| 996 | - <update_bypassed>N</update_bypassed> | |
| 997 | - <lookup> | |
| 998 | - <schema/> | |
| 999 | - <table>bsth_c_s_ttinfo_detail</table> | |
| 1000 | - <key> | |
| 1001 | - <name>xlid</name> | |
| 1002 | - <field>xl</field> | |
| 1003 | - <condition>=</condition> | |
| 1004 | - <name2/> | |
| 1005 | - </key> | |
| 1006 | - <key> | |
| 1007 | - <name>ttid</name> | |
| 1008 | - <field>ttinfo</field> | |
| 1009 | - <condition>=</condition> | |
| 1010 | - <name2/> | |
| 1011 | - </key> | |
| 1012 | - <key> | |
| 1013 | - <name>lpid</name> | |
| 1014 | - <field>lp</field> | |
| 1015 | - <condition>=</condition> | |
| 1016 | - <name2/> | |
| 1017 | - </key> | |
| 1018 | - <key> | |
| 1019 | - <name>fcno</name> | |
| 1020 | - <field>fcno</field> | |
| 1021 | - <condition>=</condition> | |
| 1022 | - <name2/> | |
| 1023 | - </key> | |
| 1024 | - <key> | |
| 1025 | - <name>bcs</name> | |
| 1026 | - <field>bcs</field> | |
| 1027 | - <condition>=</condition> | |
| 1028 | - <name2/> | |
| 1029 | - </key> | |
| 1030 | - <value> | |
| 1031 | - <name>tcc</name> | |
| 1032 | - <rename>qdzid</rename> | |
| 1033 | - <update>Y</update> | |
| 1034 | - </value> | |
| 1035 | - <value> | |
| 1036 | - <name>zdz</name> | |
| 1037 | - <rename>zdzid</rename> | |
| 1038 | - <update>Y</update> | |
| 1039 | - </value> | |
| 1040 | - <value> | |
| 1041 | - <name>xl</name> | |
| 1042 | - <rename>xlid</rename> | |
| 1043 | - <update>Y</update> | |
| 1044 | - </value> | |
| 1045 | - <value> | |
| 1046 | - <name>ttinfo</name> | |
| 1047 | - <rename>ttid</rename> | |
| 1048 | - <update>Y</update> | |
| 1049 | - </value> | |
| 1050 | - <value> | |
| 1051 | - <name>xl_dir</name> | |
| 1052 | - <rename>sxx</rename> | |
| 1053 | - <update>Y</update> | |
| 1054 | - </value> | |
| 1055 | - <value> | |
| 1056 | - <name>lp</name> | |
| 1057 | - <rename>lpid</rename> | |
| 1058 | - <update>Y</update> | |
| 1059 | - </value> | |
| 1060 | - <value> | |
| 1061 | - <name>jhlc</name> | |
| 1062 | - <rename>out_mileage</rename> | |
| 1063 | - <update>Y</update> | |
| 1064 | - </value> | |
| 1065 | - <value> | |
| 1066 | - <name>fcsj</name> | |
| 1067 | - <rename>sendtime_calcu</rename> | |
| 1068 | - <update>Y</update> | |
| 1069 | - </value> | |
| 1070 | - <value> | |
| 1071 | - <name>bcsj</name> | |
| 1072 | - <rename>out_time</rename> | |
| 1073 | - <update>Y</update> | |
| 1074 | - </value> | |
| 1075 | - <value> | |
| 1076 | - <name>bcs</name> | |
| 1077 | - <rename>bcs</rename> | |
| 1078 | - <update>Y</update> | |
| 1079 | - </value> | |
| 1080 | - <value> | |
| 1081 | - <name>fcno</name> | |
| 1082 | - <rename>fcno</rename> | |
| 1083 | - <update>Y</update> | |
| 1084 | - </value> | |
| 1085 | - <value> | |
| 1086 | - <name>bc_type</name> | |
| 1087 | - <rename>bctype_code</rename> | |
| 1088 | - <update>Y</update> | |
| 1089 | - </value> | |
| 1090 | - <value> | |
| 1091 | - <name>isfb</name> | |
| 1092 | - <rename>isfb</rename> | |
| 1093 | - <update>Y</update> | |
| 1094 | - </value> | |
| 1095 | - </lookup> | |
| 1096 | - <cluster_schema/> | |
| 1097 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1098 | - <xloc>340</xloc> | |
| 1099 | - <yloc>1087</yloc> | |
| 1100 | - <draw>Y</draw> | |
| 1101 | - </GUI> | |
| 1102 | - </step> | |
| 1103 | - | |
| 1104 | - <step> | |
| 1105 | - <name>插入/更新bsth_c_s_ttinfo_detail 3</name> | |
| 1106 | - <type>InsertUpdate</type> | |
| 1107 | - <description/> | |
| 1108 | - <distribute>Y</distribute> | |
| 1109 | - <custom_distribution/> | |
| 1110 | - <copies>1</copies> | |
| 1111 | - <partitioning> | |
| 1112 | - <method>none</method> | |
| 1113 | - <schema_name/> | |
| 1114 | - </partitioning> | |
| 1115 | - <connection>bus_control_variable</connection> | |
| 1116 | - <commit>100</commit> | |
| 1117 | - <update_bypassed>N</update_bypassed> | |
| 1118 | - <lookup> | |
| 1119 | - <schema/> | |
| 1120 | - <table>bsth_c_s_ttinfo_detail</table> | |
| 1121 | - <key> | |
| 1122 | - <name>xlid</name> | |
| 1123 | - <field>xl</field> | |
| 1124 | - <condition>=</condition> | |
| 1125 | - <name2/> | |
| 1126 | - </key> | |
| 1127 | - <key> | |
| 1128 | - <name>ttid</name> | |
| 1129 | - <field>ttinfo</field> | |
| 1130 | - <condition>=</condition> | |
| 1131 | - <name2/> | |
| 1132 | - </key> | |
| 1133 | - <key> | |
| 1134 | - <name>lpid</name> | |
| 1135 | - <field>lp</field> | |
| 1136 | - <condition>=</condition> | |
| 1137 | - <name2/> | |
| 1138 | - </key> | |
| 1139 | - <key> | |
| 1140 | - <name>fcno</name> | |
| 1141 | - <field>fcno</field> | |
| 1142 | - <condition>=</condition> | |
| 1143 | - <name2/> | |
| 1144 | - </key> | |
| 1145 | - <key> | |
| 1146 | - <name>bcs</name> | |
| 1147 | - <field>bcs</field> | |
| 1148 | - <condition>=</condition> | |
| 1149 | - <name2/> | |
| 1150 | - </key> | |
| 1151 | - <value> | |
| 1152 | - <name>fcno</name> | |
| 1153 | - <rename>fcno</rename> | |
| 1154 | - <update>Y</update> | |
| 1155 | - </value> | |
| 1156 | - <value> | |
| 1157 | - <name>bcs</name> | |
| 1158 | - <rename>bcs</rename> | |
| 1159 | - <update>Y</update> | |
| 1160 | - </value> | |
| 1161 | - <value> | |
| 1162 | - <name>xl</name> | |
| 1163 | - <rename>xlid</rename> | |
| 1164 | - <update>Y</update> | |
| 1165 | - </value> | |
| 1166 | - <value> | |
| 1167 | - <name>ttinfo</name> | |
| 1168 | - <rename>ttid</rename> | |
| 1169 | - <update>Y</update> | |
| 1170 | - </value> | |
| 1171 | - <value> | |
| 1172 | - <name>lp</name> | |
| 1173 | - <rename>lpid</rename> | |
| 1174 | - <update>Y</update> | |
| 1175 | - </value> | |
| 1176 | - <value> | |
| 1177 | - <name>bc_type</name> | |
| 1178 | - <rename>bctype_code</rename> | |
| 1179 | - <update>Y</update> | |
| 1180 | - </value> | |
| 1181 | - <value> | |
| 1182 | - <name>bcsj</name> | |
| 1183 | - <rename>parade_time</rename> | |
| 1184 | - <update>Y</update> | |
| 1185 | - </value> | |
| 1186 | - <value> | |
| 1187 | - <name>jhlc</name> | |
| 1188 | - <rename>parade_mileage</rename> | |
| 1189 | - <update>Y</update> | |
| 1190 | - </value> | |
| 1191 | - <value> | |
| 1192 | - <name>fcsj</name> | |
| 1193 | - <rename>sendtime_calcu</rename> | |
| 1194 | - <update>Y</update> | |
| 1195 | - </value> | |
| 1196 | - <value> | |
| 1197 | - <name>xl_dir</name> | |
| 1198 | - <rename>sxx2</rename> | |
| 1199 | - <update>Y</update> | |
| 1200 | - </value> | |
| 1201 | - <value> | |
| 1202 | - <name>qdz</name> | |
| 1203 | - <rename>qdzid</rename> | |
| 1204 | - <update>Y</update> | |
| 1205 | - </value> | |
| 1206 | - <value> | |
| 1207 | - <name>tcc</name> | |
| 1208 | - <rename>zdzid</rename> | |
| 1209 | - <update>Y</update> | |
| 1210 | - </value> | |
| 1211 | - <value> | |
| 1212 | - <name>isfb</name> | |
| 1213 | - <rename>isfb</rename> | |
| 1214 | - <update>Y</update> | |
| 1215 | - </value> | |
| 1216 | - </lookup> | |
| 1217 | - <cluster_schema/> | |
| 1218 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1219 | - <xloc>845</xloc> | |
| 1220 | - <yloc>899</yloc> | |
| 1221 | - <draw>Y</draw> | |
| 1222 | - </GUI> | |
| 1223 | - </step> | |
| 1224 | - | |
| 1225 | - <step> | |
| 1226 | - <name>时刻表明细信息Excel输入</name> | |
| 1227 | - <type>ExcelInput</type> | |
| 1228 | - <description/> | |
| 1229 | - <distribute>N</distribute> | |
| 1230 | - <custom_distribution/> | |
| 1231 | - <copies>1</copies> | |
| 1232 | - <partitioning> | |
| 1233 | - <method>none</method> | |
| 1234 | - <schema_name/> | |
| 1235 | - </partitioning> | |
| 1236 | - <header>Y</header> | |
| 1237 | - <noempty>Y</noempty> | |
| 1238 | - <stoponempty>N</stoponempty> | |
| 1239 | - <filefield/> | |
| 1240 | - <sheetfield/> | |
| 1241 | - <sheetrownumfield/> | |
| 1242 | - <rownumfield/> | |
| 1243 | - <sheetfield/> | |
| 1244 | - <filefield/> | |
| 1245 | - <limit>0</limit> | |
| 1246 | - <encoding/> | |
| 1247 | - <add_to_result_filenames>Y</add_to_result_filenames> | |
| 1248 | - <accept_filenames>N</accept_filenames> | |
| 1249 | - <accept_field/> | |
| 1250 | - <accept_stepname/> | |
| 1251 | - <file> | |
| 1252 | - <name/> | |
| 1253 | - <filemask/> | |
| 1254 | - <exclude_filemask/> | |
| 1255 | - <file_required>N</file_required> | |
| 1256 | - <include_subfolders>N</include_subfolders> | |
| 1257 | - </file> | |
| 1258 | - <fields> | |
| 1259 | - </fields> | |
| 1260 | - <sheets> | |
| 1261 | - <sheet> | |
| 1262 | - <name/> | |
| 1263 | - <startrow>0</startrow> | |
| 1264 | - <startcol>0</startcol> | |
| 1265 | - </sheet> | |
| 1266 | - </sheets> | |
| 1267 | - <strict_types>N</strict_types> | |
| 1268 | - <error_ignored>N</error_ignored> | |
| 1269 | - <error_line_skipped>N</error_line_skipped> | |
| 1270 | - <bad_line_files_destination_directory/> | |
| 1271 | - <bad_line_files_extension>warning</bad_line_files_extension> | |
| 1272 | - <error_line_files_destination_directory/> | |
| 1273 | - <error_line_files_extension>error</error_line_files_extension> | |
| 1274 | - <line_number_files_destination_directory/> | |
| 1275 | - <line_number_files_extension>line</line_number_files_extension> | |
| 1276 | - <shortFileFieldName/> | |
| 1277 | - <pathFieldName/> | |
| 1278 | - <hiddenFieldName/> | |
| 1279 | - <lastModificationTimeFieldName/> | |
| 1280 | - <uriNameFieldName/> | |
| 1281 | - <rootUriNameFieldName/> | |
| 1282 | - <extensionFieldName/> | |
| 1283 | - <sizeFieldName/> | |
| 1284 | - <spreadsheet_type>JXL</spreadsheet_type> | |
| 1285 | - <cluster_schema/> | |
| 1286 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1287 | - <xloc>112</xloc> | |
| 1288 | - <yloc>44</yloc> | |
| 1289 | - <draw>Y</draw> | |
| 1290 | - </GUI> | |
| 1291 | - </step> | |
| 1292 | - | |
| 1293 | - <step> | |
| 1294 | - <name>查找停车场1</name> | |
| 1295 | - <type>DBLookup</type> | |
| 1296 | - <description/> | |
| 1297 | - <distribute>Y</distribute> | |
| 1298 | - <custom_distribution/> | |
| 1299 | - <copies>1</copies> | |
| 1300 | - <partitioning> | |
| 1301 | - <method>none</method> | |
| 1302 | - <schema_name/> | |
| 1303 | - </partitioning> | |
| 1304 | - <connection>bus_control_variable</connection> | |
| 1305 | - <cache>N</cache> | |
| 1306 | - <cache_load_all>N</cache_load_all> | |
| 1307 | - <cache_size>0</cache_size> | |
| 1308 | - <lookup> | |
| 1309 | - <schema/> | |
| 1310 | - <table>bsth_c_car_park</table> | |
| 1311 | - <orderby/> | |
| 1312 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1313 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1314 | - <key> | |
| 1315 | - <name>tccname_</name> | |
| 1316 | - <field>park_name</field> | |
| 1317 | - <condition>=</condition> | |
| 1318 | - <name2/> | |
| 1319 | - </key> | |
| 1320 | - <value> | |
| 1321 | - <name>id</name> | |
| 1322 | - <rename>qdzid</rename> | |
| 1323 | - <default/> | |
| 1324 | - <type>Integer</type> | |
| 1325 | - </value> | |
| 1326 | - </lookup> | |
| 1327 | - <cluster_schema/> | |
| 1328 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1329 | - <xloc>755</xloc> | |
| 1330 | - <yloc>504</yloc> | |
| 1331 | - <draw>Y</draw> | |
| 1332 | - </GUI> | |
| 1333 | - </step> | |
| 1334 | - | |
| 1335 | - <step> | |
| 1336 | - <name>查找停车场2</name> | |
| 1337 | - <type>DBLookup</type> | |
| 1338 | - <description/> | |
| 1339 | - <distribute>Y</distribute> | |
| 1340 | - <custom_distribution/> | |
| 1341 | - <copies>1</copies> | |
| 1342 | - <partitioning> | |
| 1343 | - <method>none</method> | |
| 1344 | - <schema_name/> | |
| 1345 | - </partitioning> | |
| 1346 | - <connection>bus_control_variable</connection> | |
| 1347 | - <cache>N</cache> | |
| 1348 | - <cache_load_all>N</cache_load_all> | |
| 1349 | - <cache_size>0</cache_size> | |
| 1350 | - <lookup> | |
| 1351 | - <schema/> | |
| 1352 | - <table>bsth_c_car_park</table> | |
| 1353 | - <orderby/> | |
| 1354 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1355 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1356 | - <key> | |
| 1357 | - <name>tccname_</name> | |
| 1358 | - <field>park_name</field> | |
| 1359 | - <condition>=</condition> | |
| 1360 | - <name2/> | |
| 1361 | - </key> | |
| 1362 | - <value> | |
| 1363 | - <name>id</name> | |
| 1364 | - <rename>zdzid</rename> | |
| 1365 | - <default/> | |
| 1366 | - <type>Integer</type> | |
| 1367 | - </value> | |
| 1368 | - </lookup> | |
| 1369 | - <cluster_schema/> | |
| 1370 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1371 | - <xloc>887</xloc> | |
| 1372 | - <yloc>608</yloc> | |
| 1373 | - <draw>Y</draw> | |
| 1374 | - </GUI> | |
| 1375 | - </step> | |
| 1376 | - | |
| 1377 | - <step> | |
| 1378 | - <name>查找出场终点站关联并确定上下行</name> | |
| 1379 | - <type>DBLookup</type> | |
| 1380 | - <description/> | |
| 1381 | - <distribute>Y</distribute> | |
| 1382 | - <custom_distribution/> | |
| 1383 | - <copies>1</copies> | |
| 1384 | - <partitioning> | |
| 1385 | - <method>none</method> | |
| 1386 | - <schema_name/> | |
| 1387 | - </partitioning> | |
| 1388 | - <connection>bus_control_variable</connection> | |
| 1389 | - <cache>N</cache> | |
| 1390 | - <cache_load_all>N</cache_load_all> | |
| 1391 | - <cache_size>0</cache_size> | |
| 1392 | - <lookup> | |
| 1393 | - <schema/> | |
| 1394 | - <table>bsth_c_stationroute</table> | |
| 1395 | - <orderby/> | |
| 1396 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1397 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1398 | - <key> | |
| 1399 | - <name>xlid</name> | |
| 1400 | - <field>line</field> | |
| 1401 | - <condition>=</condition> | |
| 1402 | - <name2/> | |
| 1403 | - </key> | |
| 1404 | - <key> | |
| 1405 | - <name>zdzname</name> | |
| 1406 | - <field>station_name</field> | |
| 1407 | - <condition>=</condition> | |
| 1408 | - <name2/> | |
| 1409 | - </key> | |
| 1410 | - <key> | |
| 1411 | - <name>endZdtype</name> | |
| 1412 | - <field>station_mark</field> | |
| 1413 | - <condition>=</condition> | |
| 1414 | - <name2/> | |
| 1415 | - </key> | |
| 1416 | - <key> | |
| 1417 | - <name>destory</name> | |
| 1418 | - <field>destroy</field> | |
| 1419 | - <condition>=</condition> | |
| 1420 | - <name2/> | |
| 1421 | - </key> | |
| 1422 | - <value> | |
| 1423 | - <name>station</name> | |
| 1424 | - <rename>zdzid</rename> | |
| 1425 | - <default/> | |
| 1426 | - <type>Integer</type> | |
| 1427 | - </value> | |
| 1428 | - <value> | |
| 1429 | - <name>directions</name> | |
| 1430 | - <rename>sxx</rename> | |
| 1431 | - <default/> | |
| 1432 | - <type>Integer</type> | |
| 1433 | - </value> | |
| 1434 | - </lookup> | |
| 1435 | - <cluster_schema/> | |
| 1436 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1437 | - <xloc>329</xloc> | |
| 1438 | - <yloc>505</yloc> | |
| 1439 | - <draw>Y</draw> | |
| 1440 | - </GUI> | |
| 1441 | - </step> | |
| 1442 | - | |
| 1443 | - <step> | |
| 1444 | - <name>查找时刻表基础信息关联</name> | |
| 1445 | - <type>DBLookup</type> | |
| 1446 | - <description/> | |
| 1447 | - <distribute>Y</distribute> | |
| 1448 | - <custom_distribution/> | |
| 1449 | - <copies>1</copies> | |
| 1450 | - <partitioning> | |
| 1451 | - <method>none</method> | |
| 1452 | - <schema_name/> | |
| 1453 | - </partitioning> | |
| 1454 | - <connection>bus_control_variable</connection> | |
| 1455 | - <cache>N</cache> | |
| 1456 | - <cache_load_all>N</cache_load_all> | |
| 1457 | - <cache_size>0</cache_size> | |
| 1458 | - <lookup> | |
| 1459 | - <schema/> | |
| 1460 | - <table>bsth_c_s_ttinfo</table> | |
| 1461 | - <orderby/> | |
| 1462 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1463 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1464 | - <key> | |
| 1465 | - <name>xlid</name> | |
| 1466 | - <field>xl</field> | |
| 1467 | - <condition>=</condition> | |
| 1468 | - <name2/> | |
| 1469 | - </key> | |
| 1470 | - <key> | |
| 1471 | - <name>ttinfoname_</name> | |
| 1472 | - <field>name</field> | |
| 1473 | - <condition>=</condition> | |
| 1474 | - <name2/> | |
| 1475 | - </key> | |
| 1476 | - <key> | |
| 1477 | - <name>iscanceled</name> | |
| 1478 | - <field>is_cancel</field> | |
| 1479 | - <condition>=</condition> | |
| 1480 | - <name2/> | |
| 1481 | - </key> | |
| 1482 | - <value> | |
| 1483 | - <name>id</name> | |
| 1484 | - <rename>ttid</rename> | |
| 1485 | - <default/> | |
| 1486 | - <type>Integer</type> | |
| 1487 | - </value> | |
| 1488 | - </lookup> | |
| 1489 | - <cluster_schema/> | |
| 1490 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1491 | - <xloc>1011</xloc> | |
| 1492 | - <yloc>134</yloc> | |
| 1493 | - <draw>Y</draw> | |
| 1494 | - </GUI> | |
| 1495 | - </step> | |
| 1496 | - | |
| 1497 | - <step> | |
| 1498 | - <name>查找线路上下行里程时间</name> | |
| 1499 | - <type>DBLookup</type> | |
| 1500 | - <description/> | |
| 1501 | - <distribute>Y</distribute> | |
| 1502 | - <custom_distribution/> | |
| 1503 | - <copies>1</copies> | |
| 1504 | - <partitioning> | |
| 1505 | - <method>none</method> | |
| 1506 | - <schema_name/> | |
| 1507 | - </partitioning> | |
| 1508 | - <connection>bus_control_variable</connection> | |
| 1509 | - <cache>N</cache> | |
| 1510 | - <cache_load_all>N</cache_load_all> | |
| 1511 | - <cache_size>0</cache_size> | |
| 1512 | - <lookup> | |
| 1513 | - <schema/> | |
| 1514 | - <table>bsth_c_line_information</table> | |
| 1515 | - <orderby/> | |
| 1516 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1517 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1518 | - <key> | |
| 1519 | - <name>xlid</name> | |
| 1520 | - <field>line</field> | |
| 1521 | - <condition>=</condition> | |
| 1522 | - <name2/> | |
| 1523 | - </key> | |
| 1524 | - <value> | |
| 1525 | - <name>up_mileage</name> | |
| 1526 | - <rename>up_mileage</rename> | |
| 1527 | - <default/> | |
| 1528 | - <type>Number</type> | |
| 1529 | - </value> | |
| 1530 | - <value> | |
| 1531 | - <name>down_mileage</name> | |
| 1532 | - <rename>down_mileage</rename> | |
| 1533 | - <default/> | |
| 1534 | - <type>Number</type> | |
| 1535 | - </value> | |
| 1536 | - <value> | |
| 1537 | - <name>up_travel_time</name> | |
| 1538 | - <rename>up_travel_time</rename> | |
| 1539 | - <default/> | |
| 1540 | - <type>Number</type> | |
| 1541 | - </value> | |
| 1542 | - <value> | |
| 1543 | - <name>down_travel_time</name> | |
| 1544 | - <rename>down_travel_time</rename> | |
| 1545 | - <default/> | |
| 1546 | - <type>Number</type> | |
| 1547 | - </value> | |
| 1548 | - </lookup> | |
| 1549 | - <cluster_schema/> | |
| 1550 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1551 | - <xloc>149</xloc> | |
| 1552 | - <yloc>581</yloc> | |
| 1553 | - <draw>Y</draw> | |
| 1554 | - </GUI> | |
| 1555 | - </step> | |
| 1556 | - | |
| 1557 | - <step> | |
| 1558 | - <name>查找线路关联</name> | |
| 1559 | - <type>DBLookup</type> | |
| 1560 | - <description/> | |
| 1561 | - <distribute>Y</distribute> | |
| 1562 | - <custom_distribution/> | |
| 1563 | - <copies>1</copies> | |
| 1564 | - <partitioning> | |
| 1565 | - <method>none</method> | |
| 1566 | - <schema_name/> | |
| 1567 | - </partitioning> | |
| 1568 | - <connection>bus_control_variable</connection> | |
| 1569 | - <cache>N</cache> | |
| 1570 | - <cache_load_all>N</cache_load_all> | |
| 1571 | - <cache_size>0</cache_size> | |
| 1572 | - <lookup> | |
| 1573 | - <schema/> | |
| 1574 | - <table>bsth_c_line</table> | |
| 1575 | - <orderby/> | |
| 1576 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1577 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1578 | - <key> | |
| 1579 | - <name>xlname_</name> | |
| 1580 | - <field>name</field> | |
| 1581 | - <condition>=</condition> | |
| 1582 | - <name2/> | |
| 1583 | - </key> | |
| 1584 | - <value> | |
| 1585 | - <name>id</name> | |
| 1586 | - <rename>xlid</rename> | |
| 1587 | - <default/> | |
| 1588 | - <type>Integer</type> | |
| 1589 | - </value> | |
| 1590 | - </lookup> | |
| 1591 | - <cluster_schema/> | |
| 1592 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1593 | - <xloc>1007</xloc> | |
| 1594 | - <yloc>43</yloc> | |
| 1595 | - <draw>Y</draw> | |
| 1596 | - </GUI> | |
| 1597 | - </step> | |
| 1598 | - | |
| 1599 | - <step> | |
| 1600 | - <name>查找线路出场里程时间</name> | |
| 1601 | - <type>DBLookup</type> | |
| 1602 | - <description/> | |
| 1603 | - <distribute>Y</distribute> | |
| 1604 | - <custom_distribution/> | |
| 1605 | - <copies>1</copies> | |
| 1606 | - <partitioning> | |
| 1607 | - <method>none</method> | |
| 1608 | - <schema_name/> | |
| 1609 | - </partitioning> | |
| 1610 | - <connection>bus_control_variable</connection> | |
| 1611 | - <cache>N</cache> | |
| 1612 | - <cache_load_all>N</cache_load_all> | |
| 1613 | - <cache_size>0</cache_size> | |
| 1614 | - <lookup> | |
| 1615 | - <schema/> | |
| 1616 | - <table>bsth_c_line_information</table> | |
| 1617 | - <orderby/> | |
| 1618 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1619 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1620 | - <key> | |
| 1621 | - <name>xlid</name> | |
| 1622 | - <field>line</field> | |
| 1623 | - <condition>=</condition> | |
| 1624 | - <name2/> | |
| 1625 | - </key> | |
| 1626 | - <value> | |
| 1627 | - <name>up_out_timer</name> | |
| 1628 | - <rename>up_out_timer</rename> | |
| 1629 | - <default/> | |
| 1630 | - <type>Number</type> | |
| 1631 | - </value> | |
| 1632 | - <value> | |
| 1633 | - <name>up_out_mileage</name> | |
| 1634 | - <rename>up_out_mileage</rename> | |
| 1635 | - <default/> | |
| 1636 | - <type>Number</type> | |
| 1637 | - </value> | |
| 1638 | - <value> | |
| 1639 | - <name>down_out_timer</name> | |
| 1640 | - <rename>down_out_timer</rename> | |
| 1641 | - <default/> | |
| 1642 | - <type>Number</type> | |
| 1643 | - </value> | |
| 1644 | - <value> | |
| 1645 | - <name>down_out_mileage</name> | |
| 1646 | - <rename>down_out_mileage</rename> | |
| 1647 | - <default/> | |
| 1648 | - <type>Number</type> | |
| 1649 | - </value> | |
| 1650 | - </lookup> | |
| 1651 | - <cluster_schema/> | |
| 1652 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1653 | - <xloc>335</xloc> | |
| 1654 | - <yloc>763</yloc> | |
| 1655 | - <draw>Y</draw> | |
| 1656 | - </GUI> | |
| 1657 | - </step> | |
| 1658 | - | |
| 1659 | - <step> | |
| 1660 | - <name>查找线路进场里程时间</name> | |
| 1661 | - <type>DBLookup</type> | |
| 1662 | - <description/> | |
| 1663 | - <distribute>Y</distribute> | |
| 1664 | - <custom_distribution/> | |
| 1665 | - <copies>1</copies> | |
| 1666 | - <partitioning> | |
| 1667 | - <method>none</method> | |
| 1668 | - <schema_name/> | |
| 1669 | - </partitioning> | |
| 1670 | - <connection>bus_control_variable</connection> | |
| 1671 | - <cache>N</cache> | |
| 1672 | - <cache_load_all>N</cache_load_all> | |
| 1673 | - <cache_size>0</cache_size> | |
| 1674 | - <lookup> | |
| 1675 | - <schema/> | |
| 1676 | - <table>bsth_c_line_information</table> | |
| 1677 | - <orderby/> | |
| 1678 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1679 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1680 | - <key> | |
| 1681 | - <name>xlid</name> | |
| 1682 | - <field>line</field> | |
| 1683 | - <condition>=</condition> | |
| 1684 | - <name2/> | |
| 1685 | - </key> | |
| 1686 | - <value> | |
| 1687 | - <name>up_in_mileage</name> | |
| 1688 | - <rename>up_in_mileage</rename> | |
| 1689 | - <default/> | |
| 1690 | - <type>Number</type> | |
| 1691 | - </value> | |
| 1692 | - <value> | |
| 1693 | - <name>up_in_timer</name> | |
| 1694 | - <rename>up_in_timer</rename> | |
| 1695 | - <default/> | |
| 1696 | - <type>Number</type> | |
| 1697 | - </value> | |
| 1698 | - <value> | |
| 1699 | - <name>down_in_mileage</name> | |
| 1700 | - <rename>down_in_mileage</rename> | |
| 1701 | - <default/> | |
| 1702 | - <type>Number</type> | |
| 1703 | - </value> | |
| 1704 | - <value> | |
| 1705 | - <name>down_in_timer</name> | |
| 1706 | - <rename>down_in_timer</rename> | |
| 1707 | - <default/> | |
| 1708 | - <type>Number</type> | |
| 1709 | - </value> | |
| 1710 | - </lookup> | |
| 1711 | - <cluster_schema/> | |
| 1712 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1713 | - <xloc>553</xloc> | |
| 1714 | - <yloc>1004</yloc> | |
| 1715 | - <draw>Y</draw> | |
| 1716 | - </GUI> | |
| 1717 | - </step> | |
| 1718 | - | |
| 1719 | - <step> | |
| 1720 | - <name>查找终点站关联</name> | |
| 1721 | - <type>DBLookup</type> | |
| 1722 | - <description/> | |
| 1723 | - <distribute>Y</distribute> | |
| 1724 | - <custom_distribution/> | |
| 1725 | - <copies>1</copies> | |
| 1726 | - <partitioning> | |
| 1727 | - <method>none</method> | |
| 1728 | - <schema_name/> | |
| 1729 | - </partitioning> | |
| 1730 | - <connection>bus_control_variable</connection> | |
| 1731 | - <cache>N</cache> | |
| 1732 | - <cache_load_all>N</cache_load_all> | |
| 1733 | - <cache_size>0</cache_size> | |
| 1734 | - <lookup> | |
| 1735 | - <schema/> | |
| 1736 | - <table>bsth_c_stationroute</table> | |
| 1737 | - <orderby/> | |
| 1738 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1739 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1740 | - <key> | |
| 1741 | - <name>xlid</name> | |
| 1742 | - <field>line</field> | |
| 1743 | - <condition>=</condition> | |
| 1744 | - <name2/> | |
| 1745 | - </key> | |
| 1746 | - <key> | |
| 1747 | - <name>sxx</name> | |
| 1748 | - <field>directions</field> | |
| 1749 | - <condition>=</condition> | |
| 1750 | - <name2/> | |
| 1751 | - </key> | |
| 1752 | - <key> | |
| 1753 | - <name>endZdtype</name> | |
| 1754 | - <field>station_mark</field> | |
| 1755 | - <condition>=</condition> | |
| 1756 | - <name2/> | |
| 1757 | - </key> | |
| 1758 | - <key> | |
| 1759 | - <name>destory</name> | |
| 1760 | - <field>destroy</field> | |
| 1761 | - <condition>=</condition> | |
| 1762 | - <name2/> | |
| 1763 | - </key> | |
| 1764 | - <value> | |
| 1765 | - <name>station_name</name> | |
| 1766 | - <rename>zdzname</rename> | |
| 1767 | - <default/> | |
| 1768 | - <type>String</type> | |
| 1769 | - </value> | |
| 1770 | - <value> | |
| 1771 | - <name>station</name> | |
| 1772 | - <rename>zdzid</rename> | |
| 1773 | - <default/> | |
| 1774 | - <type>Integer</type> | |
| 1775 | - </value> | |
| 1776 | - </lookup> | |
| 1777 | - <cluster_schema/> | |
| 1778 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1779 | - <xloc>280</xloc> | |
| 1780 | - <yloc>404</yloc> | |
| 1781 | - <draw>Y</draw> | |
| 1782 | - </GUI> | |
| 1783 | - </step> | |
| 1784 | - | |
| 1785 | - <step> | |
| 1786 | - <name>查找起点站关联并确定上下行</name> | |
| 1787 | - <type>DBLookup</type> | |
| 1788 | - <description/> | |
| 1789 | - <distribute>Y</distribute> | |
| 1790 | - <custom_distribution/> | |
| 1791 | - <copies>1</copies> | |
| 1792 | - <partitioning> | |
| 1793 | - <method>none</method> | |
| 1794 | - <schema_name/> | |
| 1795 | - </partitioning> | |
| 1796 | - <connection>bus_control_variable</connection> | |
| 1797 | - <cache>N</cache> | |
| 1798 | - <cache_load_all>N</cache_load_all> | |
| 1799 | - <cache_size>0</cache_size> | |
| 1800 | - <lookup> | |
| 1801 | - <schema/> | |
| 1802 | - <table>bsth_c_stationroute</table> | |
| 1803 | - <orderby/> | |
| 1804 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1805 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1806 | - <key> | |
| 1807 | - <name>xlid</name> | |
| 1808 | - <field>line</field> | |
| 1809 | - <condition>=</condition> | |
| 1810 | - <name2/> | |
| 1811 | - </key> | |
| 1812 | - <key> | |
| 1813 | - <name>qdzname</name> | |
| 1814 | - <field>station_name</field> | |
| 1815 | - <condition>=</condition> | |
| 1816 | - <name2/> | |
| 1817 | - </key> | |
| 1818 | - <key> | |
| 1819 | - <name>sendZdtype</name> | |
| 1820 | - <field>station_mark</field> | |
| 1821 | - <condition>=</condition> | |
| 1822 | - <name2/> | |
| 1823 | - </key> | |
| 1824 | - <key> | |
| 1825 | - <name>destory</name> | |
| 1826 | - <field>destroy</field> | |
| 1827 | - <condition>=</condition> | |
| 1828 | - <name2/> | |
| 1829 | - </key> | |
| 1830 | - <value> | |
| 1831 | - <name>station</name> | |
| 1832 | - <rename>qdzid</rename> | |
| 1833 | - <default/> | |
| 1834 | - <type>Integer</type> | |
| 1835 | - </value> | |
| 1836 | - <value> | |
| 1837 | - <name>directions</name> | |
| 1838 | - <rename>sxx</rename> | |
| 1839 | - <default/> | |
| 1840 | - <type>Integer</type> | |
| 1841 | - </value> | |
| 1842 | - </lookup> | |
| 1843 | - <cluster_schema/> | |
| 1844 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1845 | - <xloc>430</xloc> | |
| 1846 | - <yloc>403</yloc> | |
| 1847 | - <draw>Y</draw> | |
| 1848 | - </GUI> | |
| 1849 | - </step> | |
| 1850 | - | |
| 1851 | - <step> | |
| 1852 | - <name>查找路牌关联</name> | |
| 1853 | - <type>DBLookup</type> | |
| 1854 | - <description/> | |
| 1855 | - <distribute>Y</distribute> | |
| 1856 | - <custom_distribution/> | |
| 1857 | - <copies>1</copies> | |
| 1858 | - <partitioning> | |
| 1859 | - <method>none</method> | |
| 1860 | - <schema_name/> | |
| 1861 | - </partitioning> | |
| 1862 | - <connection>bus_control_variable</connection> | |
| 1863 | - <cache>N</cache> | |
| 1864 | - <cache_load_all>N</cache_load_all> | |
| 1865 | - <cache_size>0</cache_size> | |
| 1866 | - <lookup> | |
| 1867 | - <schema/> | |
| 1868 | - <table>bsth_c_s_gbi</table> | |
| 1869 | - <orderby/> | |
| 1870 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1871 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1872 | - <key> | |
| 1873 | - <name>xlid</name> | |
| 1874 | - <field>xl</field> | |
| 1875 | - <condition>=</condition> | |
| 1876 | - <name2/> | |
| 1877 | - </key> | |
| 1878 | - <key> | |
| 1879 | - <name>lp</name> | |
| 1880 | - <field>lp_name</field> | |
| 1881 | - <condition>=</condition> | |
| 1882 | - <name2/> | |
| 1883 | - </key> | |
| 1884 | - <key> | |
| 1885 | - <name>iscanceled</name> | |
| 1886 | - <field>is_cancel</field> | |
| 1887 | - <condition>=</condition> | |
| 1888 | - <name2/> | |
| 1889 | - </key> | |
| 1890 | - <value> | |
| 1891 | - <name>id</name> | |
| 1892 | - <rename>lpid</rename> | |
| 1893 | - <default/> | |
| 1894 | - <type>Integer</type> | |
| 1895 | - </value> | |
| 1896 | - </lookup> | |
| 1897 | - <cluster_schema/> | |
| 1898 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1899 | - <xloc>1013</xloc> | |
| 1900 | - <yloc>265</yloc> | |
| 1901 | - <draw>Y</draw> | |
| 1902 | - </GUI> | |
| 1903 | - </step> | |
| 1904 | - | |
| 1905 | - <step> | |
| 1906 | - <name>查找进场班次上一个班次的线路方向</name> | |
| 1907 | - <type>DBLookup</type> | |
| 1908 | - <description/> | |
| 1909 | - <distribute>Y</distribute> | |
| 1910 | - <custom_distribution/> | |
| 1911 | - <copies>1</copies> | |
| 1912 | - <partitioning> | |
| 1913 | - <method>none</method> | |
| 1914 | - <schema_name/> | |
| 1915 | - </partitioning> | |
| 1916 | - <connection>bus_control_variable</connection> | |
| 1917 | - <cache>N</cache> | |
| 1918 | - <cache_load_all>N</cache_load_all> | |
| 1919 | - <cache_size>0</cache_size> | |
| 1920 | - <lookup> | |
| 1921 | - <schema/> | |
| 1922 | - <table>bsth_c_stationroute</table> | |
| 1923 | - <orderby/> | |
| 1924 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1925 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1926 | - <key> | |
| 1927 | - <name>xlid</name> | |
| 1928 | - <field>line</field> | |
| 1929 | - <condition>=</condition> | |
| 1930 | - <name2/> | |
| 1931 | - </key> | |
| 1932 | - <key> | |
| 1933 | - <name>startZdtype_calcu</name> | |
| 1934 | - <field>station_mark</field> | |
| 1935 | - <condition>=</condition> | |
| 1936 | - <name2/> | |
| 1937 | - </key> | |
| 1938 | - <key> | |
| 1939 | - <name>qdzname_calcu</name> | |
| 1940 | - <field>station_name</field> | |
| 1941 | - <condition>=</condition> | |
| 1942 | - <name2/> | |
| 1943 | - </key> | |
| 1944 | - <key> | |
| 1945 | - <name>destory</name> | |
| 1946 | - <field>destroy</field> | |
| 1947 | - <condition>=</condition> | |
| 1948 | - <name2/> | |
| 1949 | - </key> | |
| 1950 | - <value> | |
| 1951 | - <name>directions</name> | |
| 1952 | - <rename>sxx</rename> | |
| 1953 | - <default/> | |
| 1954 | - <type>String</type> | |
| 1955 | - </value> | |
| 1956 | - </lookup> | |
| 1957 | - <cluster_schema/> | |
| 1958 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1959 | - <xloc>548</xloc> | |
| 1960 | - <yloc>610</yloc> | |
| 1961 | - <draw>Y</draw> | |
| 1962 | - </GUI> | |
| 1963 | - </step> | |
| 1964 | - | |
| 1965 | - <step> | |
| 1966 | - <name>查找进场班次上一个班次的终点站,并作为进场班次的起点站</name> | |
| 1967 | - <type>DBLookup</type> | |
| 1968 | - <description/> | |
| 1969 | - <distribute>Y</distribute> | |
| 1970 | - <custom_distribution/> | |
| 1971 | - <copies>1</copies> | |
| 1972 | - <partitioning> | |
| 1973 | - <method>none</method> | |
| 1974 | - <schema_name/> | |
| 1975 | - </partitioning> | |
| 1976 | - <connection>bus_control_variable</connection> | |
| 1977 | - <cache>Y</cache> | |
| 1978 | - <cache_load_all>Y</cache_load_all> | |
| 1979 | - <cache_size>0</cache_size> | |
| 1980 | - <lookup> | |
| 1981 | - <schema/> | |
| 1982 | - <table>bsth_c_stationroute</table> | |
| 1983 | - <orderby/> | |
| 1984 | - <fail_on_multiple>N</fail_on_multiple> | |
| 1985 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 1986 | - <key> | |
| 1987 | - <name>xlid</name> | |
| 1988 | - <field>line</field> | |
| 1989 | - <condition>=</condition> | |
| 1990 | - <name2/> | |
| 1991 | - </key> | |
| 1992 | - <key> | |
| 1993 | - <name>endZdtype_calcu</name> | |
| 1994 | - <field>station_mark</field> | |
| 1995 | - <condition>=</condition> | |
| 1996 | - <name2/> | |
| 1997 | - </key> | |
| 1998 | - <key> | |
| 1999 | - <name>sxx</name> | |
| 2000 | - <field>directions</field> | |
| 2001 | - <condition>=</condition> | |
| 2002 | - <name2/> | |
| 2003 | - </key> | |
| 2004 | - <key> | |
| 2005 | - <name>destory</name> | |
| 2006 | - <field>destroy</field> | |
| 2007 | - <condition>=</condition> | |
| 2008 | - <name2/> | |
| 2009 | - </key> | |
| 2010 | - <value> | |
| 2011 | - <name>station_name</name> | |
| 2012 | - <rename>zdzname_calcu</rename> | |
| 2013 | - <default/> | |
| 2014 | - <type>Integer</type> | |
| 2015 | - </value> | |
| 2016 | - </lookup> | |
| 2017 | - <cluster_schema/> | |
| 2018 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2019 | - <xloc>550</xloc> | |
| 2020 | - <yloc>701</yloc> | |
| 2021 | - <draw>Y</draw> | |
| 2022 | - </GUI> | |
| 2023 | - </step> | |
| 2024 | - | |
| 2025 | - <step> | |
| 2026 | - <name>查找进场起点站关联确定上下行</name> | |
| 2027 | - <type>DBLookup</type> | |
| 2028 | - <description/> | |
| 2029 | - <distribute>Y</distribute> | |
| 2030 | - <custom_distribution/> | |
| 2031 | - <copies>1</copies> | |
| 2032 | - <partitioning> | |
| 2033 | - <method>none</method> | |
| 2034 | - <schema_name/> | |
| 2035 | - </partitioning> | |
| 2036 | - <connection>bus_control_variable</connection> | |
| 2037 | - <cache>N</cache> | |
| 2038 | - <cache_load_all>N</cache_load_all> | |
| 2039 | - <cache_size>0</cache_size> | |
| 2040 | - <lookup> | |
| 2041 | - <schema/> | |
| 2042 | - <table>bsth_c_stationroute</table> | |
| 2043 | - <orderby/> | |
| 2044 | - <fail_on_multiple>N</fail_on_multiple> | |
| 2045 | - <eat_row_on_failure>N</eat_row_on_failure> | |
| 2046 | - <key> | |
| 2047 | - <name>xlid</name> | |
| 2048 | - <field>line</field> | |
| 2049 | - <condition>=</condition> | |
| 2050 | - <name2/> | |
| 2051 | - </key> | |
| 2052 | - <key> | |
| 2053 | - <name>zdzname_calcu</name> | |
| 2054 | - <field>station_name</field> | |
| 2055 | - <condition>=</condition> | |
| 2056 | - <name2/> | |
| 2057 | - </key> | |
| 2058 | - <key> | |
| 2059 | - <name>startZdtype_calcu</name> | |
| 2060 | - <field>station_mark</field> | |
| 2061 | - <condition>=</condition> | |
| 2062 | - <name2/> | |
| 2063 | - </key> | |
| 2064 | - <key> | |
| 2065 | - <name>destory</name> | |
| 2066 | - <field>destroy</field> | |
| 2067 | - <condition>=</condition> | |
| 2068 | - <name2/> | |
| 2069 | - </key> | |
| 2070 | - <value> | |
| 2071 | - <name>directions</name> | |
| 2072 | - <rename>sxx2</rename> | |
| 2073 | - <default/> | |
| 2074 | - <type>Integer</type> | |
| 2075 | - </value> | |
| 2076 | - <value> | |
| 2077 | - <name>station</name> | |
| 2078 | - <rename>qdzid</rename> | |
| 2079 | - <default/> | |
| 2080 | - <type>Integer</type> | |
| 2081 | - </value> | |
| 2082 | - </lookup> | |
| 2083 | - <cluster_schema/> | |
| 2084 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2085 | - <xloc>551</xloc> | |
| 2086 | - <yloc>782</yloc> | |
| 2087 | - <draw>Y</draw> | |
| 2088 | - </GUI> | |
| 2089 | - </step> | |
| 2090 | - | |
| 2091 | - <step> | |
| 2092 | - <name>正常班次_处理数据</name> | |
| 2093 | - <type>ScriptValueMod</type> | |
| 2094 | - <description/> | |
| 2095 | - <distribute>Y</distribute> | |
| 2096 | - <custom_distribution/> | |
| 2097 | - <copies>1</copies> | |
| 2098 | - <partitioning> | |
| 2099 | - <method>none</method> | |
| 2100 | - <schema_name/> | |
| 2101 | - </partitioning> | |
| 2102 | - <compatible>N</compatible> | |
| 2103 | - <optimizationLevel>9</optimizationLevel> | |
| 2104 | - <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 2105 | - <jsScript_name>Script 1</jsScript_name> | |
| 2106 | - <jsScript_script>//Script here

// 添加站点标识
var sendZdtype = 'B';
var endZdtype = 'E';

var destory = 0; // 未撤销flag</jsScript_script> | |
| 2107 | - </jsScript> </jsScripts> <fields> <field> <name>sendZdtype</name> | |
| 2108 | - <rename>sendZdtype</rename> | |
| 2109 | - <type>String</type> | |
| 2110 | - <length>-1</length> | |
| 2111 | - <precision>-1</precision> | |
| 2112 | - <replace>N</replace> | |
| 2113 | - </field> <field> <name>endZdtype</name> | |
| 2114 | - <rename>endZdtype</rename> | |
| 2115 | - <type>String</type> | |
| 2116 | - <length>-1</length> | |
| 2117 | - <precision>-1</precision> | |
| 2118 | - <replace>N</replace> | |
| 2119 | - </field> <field> <name>destory</name> | |
| 2120 | - <rename>destory</rename> | |
| 2121 | - <type>Integer</type> | |
| 2122 | - <length>-1</length> | |
| 2123 | - <precision>-1</precision> | |
| 2124 | - <replace>N</replace> | |
| 2125 | - </field> </fields> <cluster_schema/> | |
| 2126 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2127 | - <xloc>588</xloc> | |
| 2128 | - <yloc>403</yloc> | |
| 2129 | - <draw>Y</draw> | |
| 2130 | - </GUI> | |
| 2131 | - </step> | |
| 2132 | - | |
| 2133 | - <step> | |
| 2134 | - <name>正常班次数据</name> | |
| 2135 | - <type>Dummy</type> | |
| 2136 | - <description/> | |
| 2137 | - <distribute>Y</distribute> | |
| 2138 | - <custom_distribution/> | |
| 2139 | - <copies>1</copies> | |
| 2140 | - <partitioning> | |
| 2141 | - <method>none</method> | |
| 2142 | - <schema_name/> | |
| 2143 | - </partitioning> | |
| 2144 | - <cluster_schema/> | |
| 2145 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2146 | - <xloc>725</xloc> | |
| 2147 | - <yloc>404</yloc> | |
| 2148 | - <draw>Y</draw> | |
| 2149 | - </GUI> | |
| 2150 | - </step> | |
| 2151 | - | |
| 2152 | - <step> | |
| 2153 | - <name>添加发车顺序号</name> | |
| 2154 | - <type>GroupBy</type> | |
| 2155 | - <description/> | |
| 2156 | - <distribute>Y</distribute> | |
| 2157 | - <custom_distribution/> | |
| 2158 | - <copies>1</copies> | |
| 2159 | - <partitioning> | |
| 2160 | - <method>none</method> | |
| 2161 | - <schema_name/> | |
| 2162 | - </partitioning> | |
| 2163 | - <all_rows>Y</all_rows> | |
| 2164 | - <ignore_aggregate>N</ignore_aggregate> | |
| 2165 | - <field_ignore/> | |
| 2166 | - <directory>%%java.io.tmpdir%%</directory> | |
| 2167 | - <prefix>grp</prefix> | |
| 2168 | - <add_linenr>Y</add_linenr> | |
| 2169 | - <linenr_fieldname>fcno</linenr_fieldname> | |
| 2170 | - <give_back_row>N</give_back_row> | |
| 2171 | - <group> | |
| 2172 | - <field> | |
| 2173 | - <name>lp</name> | |
| 2174 | - </field> | |
| 2175 | - </group> | |
| 2176 | - <fields> | |
| 2177 | - </fields> | |
| 2178 | - <cluster_schema/> | |
| 2179 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2180 | - <xloc>442</xloc> | |
| 2181 | - <yloc>44</yloc> | |
| 2182 | - <draw>Y</draw> | |
| 2183 | - </GUI> | |
| 2184 | - </step> | |
| 2185 | - | |
| 2186 | - <step> | |
| 2187 | - <name>添加对应班次数</name> | |
| 2188 | - <type>GroupBy</type> | |
| 2189 | - <description/> | |
| 2190 | - <distribute>Y</distribute> | |
| 2191 | - <custom_distribution/> | |
| 2192 | - <copies>1</copies> | |
| 2193 | - <partitioning> | |
| 2194 | - <method>none</method> | |
| 2195 | - <schema_name/> | |
| 2196 | - </partitioning> | |
| 2197 | - <all_rows>Y</all_rows> | |
| 2198 | - <ignore_aggregate>N</ignore_aggregate> | |
| 2199 | - <field_ignore/> | |
| 2200 | - <directory>%%java.io.tmpdir%%</directory> | |
| 2201 | - <prefix>grp</prefix> | |
| 2202 | - <add_linenr>Y</add_linenr> | |
| 2203 | - <linenr_fieldname>bcs</linenr_fieldname> | |
| 2204 | - <give_back_row>N</give_back_row> | |
| 2205 | - <group> | |
| 2206 | - </group> | |
| 2207 | - <fields> | |
| 2208 | - </fields> | |
| 2209 | - <cluster_schema/> | |
| 2210 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2211 | - <xloc>692</xloc> | |
| 2212 | - <yloc>44</yloc> | |
| 2213 | - <draw>Y</draw> | |
| 2214 | - </GUI> | |
| 2215 | - </step> | |
| 2216 | - | |
| 2217 | - <step> | |
| 2218 | - <name>班次数据范式化</name> | |
| 2219 | - <type>Normaliser</type> | |
| 2220 | - <description/> | |
| 2221 | - <distribute>Y</distribute> | |
| 2222 | - <custom_distribution/> | |
| 2223 | - <copies>1</copies> | |
| 2224 | - <partitioning> | |
| 2225 | - <method>none</method> | |
| 2226 | - <schema_name/> | |
| 2227 | - </partitioning> | |
| 2228 | - <typefield>站点名称</typefield> | |
| 2229 | - <fields> </fields> <cluster_schema/> | |
| 2230 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2231 | - <xloc>248</xloc> | |
| 2232 | - <yloc>44</yloc> | |
| 2233 | - <draw>Y</draw> | |
| 2234 | - </GUI> | |
| 2235 | - </step> | |
| 2236 | - | |
| 2237 | - <step> | |
| 2238 | - <name>班次类型字典</name> | |
| 2239 | - <type>ValueMapper</type> | |
| 2240 | - <description/> | |
| 2241 | - <distribute>Y</distribute> | |
| 2242 | - <custom_distribution/> | |
| 2243 | - <copies>1</copies> | |
| 2244 | - <partitioning> | |
| 2245 | - <method>none</method> | |
| 2246 | - <schema_name/> | |
| 2247 | - </partitioning> | |
| 2248 | - <field_to_use>bctype</field_to_use> | |
| 2249 | - <target_field>bctype_code</target_field> | |
| 2250 | - <non_match_default>未知类型</non_match_default> | |
| 2251 | - <fields> | |
| 2252 | - <field> | |
| 2253 | - <source_value>正常班次</source_value> | |
| 2254 | - <target_value>normal</target_value> | |
| 2255 | - </field> | |
| 2256 | - <field> | |
| 2257 | - <source_value>出场</source_value> | |
| 2258 | - <target_value>out</target_value> | |
| 2259 | - </field> | |
| 2260 | - <field> | |
| 2261 | - <source_value>进场</source_value> | |
| 2262 | - <target_value>in</target_value> | |
| 2263 | - </field> | |
| 2264 | - <field> | |
| 2265 | - <source_value>加油</source_value> | |
| 2266 | - <target_value>oil</target_value> | |
| 2267 | - </field> | |
| 2268 | - <field> | |
| 2269 | - <source_value>临加</source_value> | |
| 2270 | - <target_value>temp</target_value> | |
| 2271 | - </field> | |
| 2272 | - <field> | |
| 2273 | - <source_value>区间</source_value> | |
| 2274 | - <target_value>region</target_value> | |
| 2275 | - </field> | |
| 2276 | - <field> | |
| 2277 | - <source_value>放空</source_value> | |
| 2278 | - <target_value>venting</target_value> | |
| 2279 | - </field> | |
| 2280 | - <field> | |
| 2281 | - <source_value>放大站</source_value> | |
| 2282 | - <target_value>major</target_value> | |
| 2283 | - </field> | |
| 2284 | - </fields> | |
| 2285 | - <cluster_schema/> | |
| 2286 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2287 | - <xloc>149</xloc> | |
| 2288 | - <yloc>491</yloc> | |
| 2289 | - <draw>Y</draw> | |
| 2290 | - </GUI> | |
| 2291 | - </step> | |
| 2292 | - | |
| 2293 | - <step> | |
| 2294 | - <name>班次类型字典 2</name> | |
| 2295 | - <type>ValueMapper</type> | |
| 2296 | - <description/> | |
| 2297 | - <distribute>Y</distribute> | |
| 2298 | - <custom_distribution/> | |
| 2299 | - <copies>1</copies> | |
| 2300 | - <partitioning> | |
| 2301 | - <method>none</method> | |
| 2302 | - <schema_name/> | |
| 2303 | - </partitioning> | |
| 2304 | - <field_to_use>bctype</field_to_use> | |
| 2305 | - <target_field>bctype_code</target_field> | |
| 2306 | - <non_match_default>未知类型</non_match_default> | |
| 2307 | - <fields> | |
| 2308 | - <field> | |
| 2309 | - <source_value>正常班次</source_value> | |
| 2310 | - <target_value>normal</target_value> | |
| 2311 | - </field> | |
| 2312 | - <field> | |
| 2313 | - <source_value>出场</source_value> | |
| 2314 | - <target_value>out</target_value> | |
| 2315 | - </field> | |
| 2316 | - <field> | |
| 2317 | - <source_value>进场</source_value> | |
| 2318 | - <target_value>in</target_value> | |
| 2319 | - </field> | |
| 2320 | - <field> | |
| 2321 | - <source_value>加油</source_value> | |
| 2322 | - <target_value>oil</target_value> | |
| 2323 | - </field> | |
| 2324 | - <field> | |
| 2325 | - <source_value>临加</source_value> | |
| 2326 | - <target_value>temp</target_value> | |
| 2327 | - </field> | |
| 2328 | - <field> | |
| 2329 | - <source_value>区间</source_value> | |
| 2330 | - <target_value>region</target_value> | |
| 2331 | - </field> | |
| 2332 | - <field> | |
| 2333 | - <source_value>放空</source_value> | |
| 2334 | - <target_value>venting</target_value> | |
| 2335 | - </field> | |
| 2336 | - <field> | |
| 2337 | - <source_value>放大站</source_value> | |
| 2338 | - <target_value>major</target_value> | |
| 2339 | - </field> | |
| 2340 | - </fields> | |
| 2341 | - <cluster_schema/> | |
| 2342 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2343 | - <xloc>333</xloc> | |
| 2344 | - <yloc>681</yloc> | |
| 2345 | - <draw>Y</draw> | |
| 2346 | - </GUI> | |
| 2347 | - </step> | |
| 2348 | - | |
| 2349 | - <step> | |
| 2350 | - <name>班次类型字典 3</name> | |
| 2351 | - <type>ValueMapper</type> | |
| 2352 | - <description/> | |
| 2353 | - <distribute>Y</distribute> | |
| 2354 | - <custom_distribution/> | |
| 2355 | - <copies>1</copies> | |
| 2356 | - <partitioning> | |
| 2357 | - <method>none</method> | |
| 2358 | - <schema_name/> | |
| 2359 | - </partitioning> | |
| 2360 | - <field_to_use>bctype</field_to_use> | |
| 2361 | - <target_field>bctype_code</target_field> | |
| 2362 | - <non_match_default>未知类型</non_match_default> | |
| 2363 | - <fields> | |
| 2364 | - <field> | |
| 2365 | - <source_value>正常班次</source_value> | |
| 2366 | - <target_value>normal</target_value> | |
| 2367 | - </field> | |
| 2368 | - <field> | |
| 2369 | - <source_value>出场</source_value> | |
| 2370 | - <target_value>out</target_value> | |
| 2371 | - </field> | |
| 2372 | - <field> | |
| 2373 | - <source_value>进场</source_value> | |
| 2374 | - <target_value>in</target_value> | |
| 2375 | - </field> | |
| 2376 | - <field> | |
| 2377 | - <source_value>加油</source_value> | |
| 2378 | - <target_value>oil</target_value> | |
| 2379 | - </field> | |
| 2380 | - <field> | |
| 2381 | - <source_value>临加</source_value> | |
| 2382 | - <target_value>temp</target_value> | |
| 2383 | - </field> | |
| 2384 | - <field> | |
| 2385 | - <source_value>区间</source_value> | |
| 2386 | - <target_value>region</target_value> | |
| 2387 | - </field> | |
| 2388 | - <field> | |
| 2389 | - <source_value>放空</source_value> | |
| 2390 | - <target_value>venting</target_value> | |
| 2391 | - </field> | |
| 2392 | - <field> | |
| 2393 | - <source_value>放大站</source_value> | |
| 2394 | - <target_value>major</target_value> | |
| 2395 | - </field> | |
| 2396 | - </fields> | |
| 2397 | - <cluster_schema/> | |
| 2398 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2399 | - <xloc>551</xloc> | |
| 2400 | - <yloc>928</yloc> | |
| 2401 | - <draw>Y</draw> | |
| 2402 | - </GUI> | |
| 2403 | - </step> | |
| 2404 | - | |
| 2405 | - <step> | |
| 2406 | - <name>类型修正</name> | |
| 2407 | - <type>SelectValues</type> | |
| 2408 | - <description/> | |
| 2409 | - <distribute>Y</distribute> | |
| 2410 | - <custom_distribution/> | |
| 2411 | - <copies>1</copies> | |
| 2412 | - <partitioning> | |
| 2413 | - <method>none</method> | |
| 2414 | - <schema_name/> | |
| 2415 | - </partitioning> | |
| 2416 | - <fields> <select_unspecified>N</select_unspecified> | |
| 2417 | - <meta> <name>jhlc</name> | |
| 2418 | - <rename>jhlc</rename> | |
| 2419 | - <type>Number</type> | |
| 2420 | - <length>-2</length> | |
| 2421 | - <precision>-2</precision> | |
| 2422 | - <conversion_mask/> | |
| 2423 | - <date_format_lenient>false</date_format_lenient> | |
| 2424 | - <date_format_locale/> | |
| 2425 | - <date_format_timezone/> | |
| 2426 | - <lenient_string_to_number>false</lenient_string_to_number> | |
| 2427 | - <encoding/> | |
| 2428 | - <decimal_symbol/> | |
| 2429 | - <grouping_symbol/> | |
| 2430 | - <currency_symbol/> | |
| 2431 | - <storage_type/> | |
| 2432 | - </meta> <meta> <name>bcsj</name> | |
| 2433 | - <rename>bcsj</rename> | |
| 2434 | - <type>Integer</type> | |
| 2435 | - <length>-2</length> | |
| 2436 | - <precision>-2</precision> | |
| 2437 | - <conversion_mask/> | |
| 2438 | - <date_format_lenient>false</date_format_lenient> | |
| 2439 | - <date_format_locale/> | |
| 2440 | - <date_format_timezone/> | |
| 2441 | - <lenient_string_to_number>false</lenient_string_to_number> | |
| 2442 | - <encoding/> | |
| 2443 | - <decimal_symbol/> | |
| 2444 | - <grouping_symbol/> | |
| 2445 | - <currency_symbol/> | |
| 2446 | - <storage_type/> | |
| 2447 | - </meta> </fields> <cluster_schema/> | |
| 2448 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2449 | - <xloc>146</xloc> | |
| 2450 | - <yloc>768</yloc> | |
| 2451 | - <draw>Y</draw> | |
| 2452 | - </GUI> | |
| 2453 | - </step> | |
| 2454 | - | |
| 2455 | - <step> | |
| 2456 | - <name>类型修正 2</name> | |
| 2457 | - <type>SelectValues</type> | |
| 2458 | - <description/> | |
| 2459 | - <distribute>Y</distribute> | |
| 2460 | - <custom_distribution/> | |
| 2461 | - <copies>1</copies> | |
| 2462 | - <partitioning> | |
| 2463 | - <method>none</method> | |
| 2464 | - <schema_name/> | |
| 2465 | - </partitioning> | |
| 2466 | - <fields> <select_unspecified>N</select_unspecified> | |
| 2467 | - <meta> <name>out_mileage</name> | |
| 2468 | - <rename>out_mileage</rename> | |
| 2469 | - <type>Number</type> | |
| 2470 | - <length>-2</length> | |
| 2471 | - <precision>-2</precision> | |
| 2472 | - <conversion_mask/> | |
| 2473 | - <date_format_lenient>false</date_format_lenient> | |
| 2474 | - <date_format_locale/> | |
| 2475 | - <date_format_timezone/> | |
| 2476 | - <lenient_string_to_number>false</lenient_string_to_number> | |
| 2477 | - <encoding/> | |
| 2478 | - <decimal_symbol/> | |
| 2479 | - <grouping_symbol/> | |
| 2480 | - <currency_symbol/> | |
| 2481 | - <storage_type/> | |
| 2482 | - </meta> <meta> <name>out_time</name> | |
| 2483 | - <rename>out_time</rename> | |
| 2484 | - <type>Integer</type> | |
| 2485 | - <length>-2</length> | |
| 2486 | - <precision>-2</precision> | |
| 2487 | - <conversion_mask/> | |
| 2488 | - <date_format_lenient>false</date_format_lenient> | |
| 2489 | - <date_format_locale/> | |
| 2490 | - <date_format_timezone/> | |
| 2491 | - <lenient_string_to_number>false</lenient_string_to_number> | |
| 2492 | - <encoding/> | |
| 2493 | - <decimal_symbol/> | |
| 2494 | - <grouping_symbol/> | |
| 2495 | - <currency_symbol/> | |
| 2496 | - <storage_type/> | |
| 2497 | - </meta> <meta> <name>sxx</name> | |
| 2498 | - <rename>sxx</rename> | |
| 2499 | - <type>Integer</type> | |
| 2500 | - <length>-2</length> | |
| 2501 | - <precision>-2</precision> | |
| 2502 | - <conversion_mask/> | |
| 2503 | - <date_format_lenient>false</date_format_lenient> | |
| 2504 | - <date_format_locale/> | |
| 2505 | - <date_format_timezone/> | |
| 2506 | - <lenient_string_to_number>false</lenient_string_to_number> | |
| 2507 | - <encoding/> | |
| 2508 | - <decimal_symbol/> | |
| 2509 | - <grouping_symbol/> | |
| 2510 | - <currency_symbol/> | |
| 2511 | - <storage_type/> | |
| 2512 | - </meta> </fields> <cluster_schema/> | |
| 2513 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2514 | - <xloc>338</xloc> | |
| 2515 | - <yloc>1008</yloc> | |
| 2516 | - <draw>Y</draw> | |
| 2517 | - </GUI> | |
| 2518 | - </step> | |
| 2519 | - | |
| 2520 | - <step> | |
| 2521 | - <name>类型修正 3</name> | |
| 2522 | - <type>SelectValues</type> | |
| 2523 | - <description/> | |
| 2524 | - <distribute>Y</distribute> | |
| 2525 | - <custom_distribution/> | |
| 2526 | - <copies>1</copies> | |
| 2527 | - <partitioning> | |
| 2528 | - <method>none</method> | |
| 2529 | - <schema_name/> | |
| 2530 | - </partitioning> | |
| 2531 | - <fields> <select_unspecified>N</select_unspecified> | |
| 2532 | - <meta> <name>parade_mileage</name> | |
| 2533 | - <rename>parade_mileage</rename> | |
| 2534 | - <type>Number</type> | |
| 2535 | - <length>-2</length> | |
| 2536 | - <precision>-2</precision> | |
| 2537 | - <conversion_mask/> | |
| 2538 | - <date_format_lenient>false</date_format_lenient> | |
| 2539 | - <date_format_locale/> | |
| 2540 | - <date_format_timezone/> | |
| 2541 | - <lenient_string_to_number>false</lenient_string_to_number> | |
| 2542 | - <encoding/> | |
| 2543 | - <decimal_symbol/> | |
| 2544 | - <grouping_symbol/> | |
| 2545 | - <currency_symbol/> | |
| 2546 | - <storage_type/> | |
| 2547 | - </meta> <meta> <name>parade_time</name> | |
| 2548 | - <rename>parade_time</rename> | |
| 2549 | - <type>Integer</type> | |
| 2550 | - <length>-2</length> | |
| 2551 | - <precision>-2</precision> | |
| 2552 | - <conversion_mask/> | |
| 2553 | - <date_format_lenient>false</date_format_lenient> | |
| 2554 | - <date_format_locale/> | |
| 2555 | - <date_format_timezone/> | |
| 2556 | - <lenient_string_to_number>false</lenient_string_to_number> | |
| 2557 | - <encoding/> | |
| 2558 | - <decimal_symbol/> | |
| 2559 | - <grouping_symbol/> | |
| 2560 | - <currency_symbol/> | |
| 2561 | - <storage_type/> | |
| 2562 | - </meta> <meta> <name>sxx2</name> | |
| 2563 | - <rename>sxx2</rename> | |
| 2564 | - <type>Integer</type> | |
| 2565 | - <length>-2</length> | |
| 2566 | - <precision>-2</precision> | |
| 2567 | - <conversion_mask/> | |
| 2568 | - <date_format_lenient>false</date_format_lenient> | |
| 2569 | - <date_format_locale/> | |
| 2570 | - <date_format_timezone/> | |
| 2571 | - <lenient_string_to_number>false</lenient_string_to_number> | |
| 2572 | - <encoding/> | |
| 2573 | - <decimal_symbol/> | |
| 2574 | - <grouping_symbol/> | |
| 2575 | - <currency_symbol/> | |
| 2576 | - <storage_type/> | |
| 2577 | - </meta> </fields> <cluster_schema/> | |
| 2578 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2579 | - <xloc>847</xloc> | |
| 2580 | - <yloc>1003</yloc> | |
| 2581 | - <draw>Y</draw> | |
| 2582 | - </GUI> | |
| 2583 | - </step> | |
| 2584 | - | |
| 2585 | - <step> | |
| 2586 | - <name>计算班次类型</name> | |
| 2587 | - <type>ValueMapper</type> | |
| 2588 | - <description/> | |
| 2589 | - <distribute>Y</distribute> | |
| 2590 | - <custom_distribution/> | |
| 2591 | - <copies>1</copies> | |
| 2592 | - <partitioning> | |
| 2593 | - <method>none</method> | |
| 2594 | - <schema_name/> | |
| 2595 | - </partitioning> | |
| 2596 | - <field_to_use>qdzname</field_to_use> | |
| 2597 | - <target_field>bctype</target_field> | |
| 2598 | - <non_match_default>正常班次</non_match_default> | |
| 2599 | - <fields> | |
| 2600 | - <field> | |
| 2601 | - <source_value>出场</source_value> | |
| 2602 | - <target_value>出场</target_value> | |
| 2603 | - </field> | |
| 2604 | - <field> | |
| 2605 | - <source_value>进场</source_value> | |
| 2606 | - <target_value>进场</target_value> | |
| 2607 | - </field> | |
| 2608 | - </fields> | |
| 2609 | - <cluster_schema/> | |
| 2610 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2611 | - <xloc>1014</xloc> | |
| 2612 | - <yloc>401</yloc> | |
| 2613 | - <draw>Y</draw> | |
| 2614 | - </GUI> | |
| 2615 | - </step> | |
| 2616 | - | |
| 2617 | - <step> | |
| 2618 | - <name>记录关联 (笛卡尔输出)</name> | |
| 2619 | - <type>JoinRows</type> | |
| 2620 | - <description/> | |
| 2621 | - <distribute>Y</distribute> | |
| 2622 | - <custom_distribution/> | |
| 2623 | - <copies>1</copies> | |
| 2624 | - <partitioning> | |
| 2625 | - <method>none</method> | |
| 2626 | - <schema_name/> | |
| 2627 | - </partitioning> | |
| 2628 | - <directory>%%java.io.tmpdir%%</directory> | |
| 2629 | - <prefix>out</prefix> | |
| 2630 | - <cache_size>500</cache_size> | |
| 2631 | - <main/> | |
| 2632 | - <compare> | |
| 2633 | -<condition> | |
| 2634 | - <negated>N</negated> | |
| 2635 | - <leftvalue/> | |
| 2636 | - <function>=</function> | |
| 2637 | - <rightvalue/> | |
| 2638 | - </condition> | |
| 2639 | - </compare> | |
| 2640 | - <cluster_schema/> | |
| 2641 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2642 | - <xloc>310</xloc> | |
| 2643 | - <yloc>133</yloc> | |
| 2644 | - <draw>Y</draw> | |
| 2645 | - </GUI> | |
| 2646 | - </step> | |
| 2647 | - | |
| 2648 | - <step> | |
| 2649 | - <name>过滤记录(发车时间为空)</name> | |
| 2650 | - <type>FilterRows</type> | |
| 2651 | - <description/> | |
| 2652 | - <distribute>Y</distribute> | |
| 2653 | - <custom_distribution/> | |
| 2654 | - <copies>1</copies> | |
| 2655 | - <partitioning> | |
| 2656 | - <method>none</method> | |
| 2657 | - <schema_name/> | |
| 2658 | - </partitioning> | |
| 2659 | -<send_true_to/> | |
| 2660 | -<send_false_to/> | |
| 2661 | - <compare> | |
| 2662 | -<condition> | |
| 2663 | - <negated>N</negated> | |
| 2664 | - <leftvalue>sendtime</leftvalue> | |
| 2665 | - <function>IS NOT NULL</function> | |
| 2666 | - <rightvalue/> | |
| 2667 | - </condition> | |
| 2668 | - </compare> | |
| 2669 | - <cluster_schema/> | |
| 2670 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2671 | - <xloc>571</xloc> | |
| 2672 | - <yloc>44</yloc> | |
| 2673 | - <draw>Y</draw> | |
| 2674 | - </GUI> | |
| 2675 | - </step> | |
| 2676 | - | |
| 2677 | - <step> | |
| 2678 | - <name>进场班次_确定起点站名字</name> | |
| 2679 | - <type>ScriptValueMod</type> | |
| 2680 | - <description/> | |
| 2681 | - <distribute>Y</distribute> | |
| 2682 | - <custom_distribution/> | |
| 2683 | - <copies>1</copies> | |
| 2684 | - <partitioning> | |
| 2685 | - <method>none</method> | |
| 2686 | - <schema_name/> | |
| 2687 | - </partitioning> | |
| 2688 | - <compatible>N</compatible> | |
| 2689 | - <optimizationLevel>9</optimizationLevel> | |
| 2690 | - <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 2691 | - <jsScript_name>Script 1</jsScript_name> | |
| 2692 | - <jsScript_script>//Script here

// 添加站点标识
var cc_groups = qdzgroups.split(","); // 所有班次起点站数组
var qdzname_calcu = cc_groups[gno - 2]; // 进场班次的起点站是上一个班次的终点站,这里只有上一个班次的起点站,还需要计算
var startZdtype_calcu = 'B';
var endZdtype_calcu = 'E';

var destory = 0; // 未撤销flag</jsScript_script> | |
| 2693 | - </jsScript> </jsScripts> <fields> <field> <name>qdzname_calcu</name> | |
| 2694 | - <rename>qdzname_calcu</rename> | |
| 2695 | - <type>String</type> | |
| 2696 | - <length>-1</length> | |
| 2697 | - <precision>-1</precision> | |
| 2698 | - <replace>N</replace> | |
| 2699 | - </field> <field> <name>startZdtype_calcu</name> | |
| 2700 | - <rename>startZdtype_calcu</rename> | |
| 2701 | - <type>String</type> | |
| 2702 | - <length>-1</length> | |
| 2703 | - <precision>-1</precision> | |
| 2704 | - <replace>N</replace> | |
| 2705 | - </field> <field> <name>endZdtype_calcu</name> | |
| 2706 | - <rename>endZdtype_calcu</rename> | |
| 2707 | - <type>String</type> | |
| 2708 | - <length>-1</length> | |
| 2709 | - <precision>-1</precision> | |
| 2710 | - <replace>N</replace> | |
| 2711 | - </field> <field> <name>destory</name> | |
| 2712 | - <rename>destory</rename> | |
| 2713 | - <type>Integer</type> | |
| 2714 | - <length>-1</length> | |
| 2715 | - <precision>-1</precision> | |
| 2716 | - <replace>N</replace> | |
| 2717 | - </field> </fields> <cluster_schema/> | |
| 2718 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2719 | - <xloc>754</xloc> | |
| 2720 | - <yloc>610</yloc> | |
| 2721 | - <draw>Y</draw> | |
| 2722 | - </GUI> | |
| 2723 | - </step> | |
| 2724 | - | |
| 2725 | - <step> | |
| 2726 | - <name>进场班次数据</name> | |
| 2727 | - <type>Dummy</type> | |
| 2728 | - <description/> | |
| 2729 | - <distribute>Y</distribute> | |
| 2730 | - <custom_distribution/> | |
| 2731 | - <copies>1</copies> | |
| 2732 | - <partitioning> | |
| 2733 | - <method>none</method> | |
| 2734 | - <schema_name/> | |
| 2735 | - </partitioning> | |
| 2736 | - <cluster_schema/> | |
| 2737 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2738 | - <xloc>997</xloc> | |
| 2739 | - <yloc>606</yloc> | |
| 2740 | - <draw>Y</draw> | |
| 2741 | - </GUI> | |
| 2742 | - </step> | |
| 2743 | - | |
| 2744 | - <step> | |
| 2745 | - <name>上下行NULL判定</name> | |
| 2746 | - <type>IfNull</type> | |
| 2747 | - <description/> | |
| 2748 | - <distribute>Y</distribute> | |
| 2749 | - <custom_distribution/> | |
| 2750 | - <copies>1</copies> | |
| 2751 | - <partitioning> | |
| 2752 | - <method>none</method> | |
| 2753 | - <schema_name/> | |
| 2754 | - </partitioning> | |
| 2755 | - <replaceAllByValue/> | |
| 2756 | - <replaceAllMask/> | |
| 2757 | - <selectFields>Y</selectFields> | |
| 2758 | - <selectValuesType>N</selectValuesType> | |
| 2759 | - <setEmptyStringAll>N</setEmptyStringAll> | |
| 2760 | - <valuetypes> | |
| 2761 | - </valuetypes> | |
| 2762 | - <fields> | |
| 2763 | - <field> | |
| 2764 | - <name>sxx</name> | |
| 2765 | - <value>0</value> | |
| 2766 | - <mask/> | |
| 2767 | - <set_empty_string>N</set_empty_string> | |
| 2768 | - </field> | |
| 2769 | - </fields> | |
| 2770 | - <cluster_schema/> | |
| 2771 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2772 | - <xloc>230</xloc> | |
| 2773 | - <yloc>946</yloc> | |
| 2774 | - <draw>Y</draw> | |
| 2775 | - </GUI> | |
| 2776 | - </step> | |
| 2777 | - | |
| 2778 | - <step> | |
| 2779 | - <name>上下行判定 2</name> | |
| 2780 | - <type>IfNull</type> | |
| 2781 | - <description/> | |
| 2782 | - <distribute>Y</distribute> | |
| 2783 | - <custom_distribution/> | |
| 2784 | - <copies>1</copies> | |
| 2785 | - <partitioning> | |
| 2786 | - <method>none</method> | |
| 2787 | - <schema_name/> | |
| 2788 | - </partitioning> | |
| 2789 | - <replaceAllByValue/> | |
| 2790 | - <replaceAllMask/> | |
| 2791 | - <selectFields>Y</selectFields> | |
| 2792 | - <selectValuesType>N</selectValuesType> | |
| 2793 | - <setEmptyStringAll>N</setEmptyStringAll> | |
| 2794 | - <valuetypes> | |
| 2795 | - </valuetypes> | |
| 2796 | - <fields> | |
| 2797 | - <field> | |
| 2798 | - <name>sxx2</name> | |
| 2799 | - <value>0</value> | |
| 2800 | - <mask/> | |
| 2801 | - <set_empty_string>N</set_empty_string> | |
| 2802 | - </field> | |
| 2803 | - </fields> | |
| 2804 | - <cluster_schema/> | |
| 2805 | - <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2806 | - <xloc>804</xloc> | |
| 2807 | - <yloc>1081</yloc> | |
| 2808 | - <draw>Y</draw> | |
| 2809 | - </GUI> | |
| 2810 | - </step> | |
| 2811 | - | |
| 2812 | - <step_error_handling> | |
| 2813 | - <error> | |
| 2814 | - <source_step>插入/更新bsth_c_s_ttinfo_detail</source_step> | |
| 2815 | - <target_step/> | |
| 2816 | - <is_enabled>Y</is_enabled> | |
| 2817 | - <nr_valuename>c1</nr_valuename> | |
| 2818 | - <descriptions_valuename>c2</descriptions_valuename> | |
| 2819 | - <fields_valuename>c3</fields_valuename> | |
| 2820 | - <codes_valuename>c4</codes_valuename> | |
| 2821 | - <max_errors/> | |
| 2822 | - <max_pct_errors/> | |
| 2823 | - <min_pct_rows/> | |
| 2824 | - </error> | |
| 2825 | - </step_error_handling> | |
| 2826 | - <slave-step-copy-partition-distribution> | |
| 2827 | -</slave-step-copy-partition-distribution> | |
| 2828 | - <slave_transformation>N</slave_transformation> | |
| 2829 | - | |
| 2830 | -</transformation> | |
| 1 | +<?xml version="1.0" encoding="UTF-8"?> | |
| 2 | +<transformation> | |
| 3 | + <info> | |
| 4 | + <name>ttinfodetailDataInput</name> | |
| 5 | + <description>时刻表明细信息导入</description> | |
| 6 | + <extended_description>时刻表明细信息</extended_description> | |
| 7 | + <trans_version/> | |
| 8 | + <trans_type>Normal</trans_type> | |
| 9 | + <trans_status>0</trans_status> | |
| 10 | + <directory>/</directory> | |
| 11 | + <parameters> | |
| 12 | + </parameters> | |
| 13 | + <log> | |
| 14 | +<trans-log-table><connection/> | |
| 15 | +<schema/> | |
| 16 | +<table/> | |
| 17 | +<size_limit_lines/> | |
| 18 | +<interval/> | |
| 19 | +<timeout_days/> | |
| 20 | +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>TRANSNAME</id><enabled>Y</enabled><name>TRANSNAME</name></field><field><id>STATUS</id><enabled>Y</enabled><name>STATUS</name></field><field><id>LINES_READ</id><enabled>Y</enabled><name>LINES_READ</name><subject/></field><field><id>LINES_WRITTEN</id><enabled>Y</enabled><name>LINES_WRITTEN</name><subject/></field><field><id>LINES_UPDATED</id><enabled>Y</enabled><name>LINES_UPDATED</name><subject/></field><field><id>LINES_INPUT</id><enabled>Y</enabled><name>LINES_INPUT</name><subject/></field><field><id>LINES_OUTPUT</id><enabled>Y</enabled><name>LINES_OUTPUT</name><subject/></field><field><id>LINES_REJECTED</id><enabled>Y</enabled><name>LINES_REJECTED</name><subject/></field><field><id>ERRORS</id><enabled>Y</enabled><name>ERRORS</name></field><field><id>STARTDATE</id><enabled>Y</enabled><name>STARTDATE</name></field><field><id>ENDDATE</id><enabled>Y</enabled><name>ENDDATE</name></field><field><id>LOGDATE</id><enabled>Y</enabled><name>LOGDATE</name></field><field><id>DEPDATE</id><enabled>Y</enabled><name>DEPDATE</name></field><field><id>REPLAYDATE</id><enabled>Y</enabled><name>REPLAYDATE</name></field><field><id>LOG_FIELD</id><enabled>Y</enabled><name>LOG_FIELD</name></field><field><id>EXECUTING_SERVER</id><enabled>N</enabled><name>EXECUTING_SERVER</name></field><field><id>EXECUTING_USER</id><enabled>N</enabled><name>EXECUTING_USER</name></field><field><id>CLIENT</id><enabled>N</enabled><name>CLIENT</name></field></trans-log-table> | |
| 21 | +<perf-log-table><connection/> | |
| 22 | +<schema/> | |
| 23 | +<table/> | |
| 24 | +<interval/> | |
| 25 | +<timeout_days/> | |
| 26 | +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>SEQ_NR</id><enabled>Y</enabled><name>SEQ_NR</name></field><field><id>LOGDATE</id><enabled>Y</enabled><name>LOGDATE</name></field><field><id>TRANSNAME</id><enabled>Y</enabled><name>TRANSNAME</name></field><field><id>STEPNAME</id><enabled>Y</enabled><name>STEPNAME</name></field><field><id>STEP_COPY</id><enabled>Y</enabled><name>STEP_COPY</name></field><field><id>LINES_READ</id><enabled>Y</enabled><name>LINES_READ</name></field><field><id>LINES_WRITTEN</id><enabled>Y</enabled><name>LINES_WRITTEN</name></field><field><id>LINES_UPDATED</id><enabled>Y</enabled><name>LINES_UPDATED</name></field><field><id>LINES_INPUT</id><enabled>Y</enabled><name>LINES_INPUT</name></field><field><id>LINES_OUTPUT</id><enabled>Y</enabled><name>LINES_OUTPUT</name></field><field><id>LINES_REJECTED</id><enabled>Y</enabled><name>LINES_REJECTED</name></field><field><id>ERRORS</id><enabled>Y</enabled><name>ERRORS</name></field><field><id>INPUT_BUFFER_ROWS</id><enabled>Y</enabled><name>INPUT_BUFFER_ROWS</name></field><field><id>OUTPUT_BUFFER_ROWS</id><enabled>Y</enabled><name>OUTPUT_BUFFER_ROWS</name></field></perf-log-table> | |
| 27 | +<channel-log-table><connection/> | |
| 28 | +<schema/> | |
| 29 | +<table/> | |
| 30 | +<timeout_days/> | |
| 31 | +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>LOG_DATE</id><enabled>Y</enabled><name>LOG_DATE</name></field><field><id>LOGGING_OBJECT_TYPE</id><enabled>Y</enabled><name>LOGGING_OBJECT_TYPE</name></field><field><id>OBJECT_NAME</id><enabled>Y</enabled><name>OBJECT_NAME</name></field><field><id>OBJECT_COPY</id><enabled>Y</enabled><name>OBJECT_COPY</name></field><field><id>REPOSITORY_DIRECTORY</id><enabled>Y</enabled><name>REPOSITORY_DIRECTORY</name></field><field><id>FILENAME</id><enabled>Y</enabled><name>FILENAME</name></field><field><id>OBJECT_ID</id><enabled>Y</enabled><name>OBJECT_ID</name></field><field><id>OBJECT_REVISION</id><enabled>Y</enabled><name>OBJECT_REVISION</name></field><field><id>PARENT_CHANNEL_ID</id><enabled>Y</enabled><name>PARENT_CHANNEL_ID</name></field><field><id>ROOT_CHANNEL_ID</id><enabled>Y</enabled><name>ROOT_CHANNEL_ID</name></field></channel-log-table> | |
| 32 | +<step-log-table><connection/> | |
| 33 | +<schema/> | |
| 34 | +<table/> | |
| 35 | +<timeout_days/> | |
| 36 | +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>LOG_DATE</id><enabled>Y</enabled><name>LOG_DATE</name></field><field><id>TRANSNAME</id><enabled>Y</enabled><name>TRANSNAME</name></field><field><id>STEPNAME</id><enabled>Y</enabled><name>STEPNAME</name></field><field><id>STEP_COPY</id><enabled>Y</enabled><name>STEP_COPY</name></field><field><id>LINES_READ</id><enabled>Y</enabled><name>LINES_READ</name></field><field><id>LINES_WRITTEN</id><enabled>Y</enabled><name>LINES_WRITTEN</name></field><field><id>LINES_UPDATED</id><enabled>Y</enabled><name>LINES_UPDATED</name></field><field><id>LINES_INPUT</id><enabled>Y</enabled><name>LINES_INPUT</name></field><field><id>LINES_OUTPUT</id><enabled>Y</enabled><name>LINES_OUTPUT</name></field><field><id>LINES_REJECTED</id><enabled>Y</enabled><name>LINES_REJECTED</name></field><field><id>ERRORS</id><enabled>Y</enabled><name>ERRORS</name></field><field><id>LOG_FIELD</id><enabled>N</enabled><name>LOG_FIELD</name></field></step-log-table> | |
| 37 | +<metrics-log-table><connection/> | |
| 38 | +<schema/> | |
| 39 | +<table/> | |
| 40 | +<timeout_days/> | |
| 41 | +<field><id>ID_BATCH</id><enabled>Y</enabled><name>ID_BATCH</name></field><field><id>CHANNEL_ID</id><enabled>Y</enabled><name>CHANNEL_ID</name></field><field><id>LOG_DATE</id><enabled>Y</enabled><name>LOG_DATE</name></field><field><id>METRICS_DATE</id><enabled>Y</enabled><name>METRICS_DATE</name></field><field><id>METRICS_CODE</id><enabled>Y</enabled><name>METRICS_CODE</name></field><field><id>METRICS_DESCRIPTION</id><enabled>Y</enabled><name>METRICS_DESCRIPTION</name></field><field><id>METRICS_SUBJECT</id><enabled>Y</enabled><name>METRICS_SUBJECT</name></field><field><id>METRICS_TYPE</id><enabled>Y</enabled><name>METRICS_TYPE</name></field><field><id>METRICS_VALUE</id><enabled>Y</enabled><name>METRICS_VALUE</name></field></metrics-log-table> | |
| 42 | + </log> | |
| 43 | + <maxdate> | |
| 44 | + <connection/> | |
| 45 | + <table/> | |
| 46 | + <field/> | |
| 47 | + <offset>0.0</offset> | |
| 48 | + <maxdiff>0.0</maxdiff> | |
| 49 | + </maxdate> | |
| 50 | + <size_rowset>10000</size_rowset> | |
| 51 | + <sleep_time_empty>50</sleep_time_empty> | |
| 52 | + <sleep_time_full>50</sleep_time_full> | |
| 53 | + <unique_connections>N</unique_connections> | |
| 54 | + <feedback_shown>Y</feedback_shown> | |
| 55 | + <feedback_size>50000</feedback_size> | |
| 56 | + <using_thread_priorities>Y</using_thread_priorities> | |
| 57 | + <shared_objects_file/> | |
| 58 | + <capture_step_performance>N</capture_step_performance> | |
| 59 | + <step_performance_capturing_delay>1000</step_performance_capturing_delay> | |
| 60 | + <step_performance_capturing_size_limit>100</step_performance_capturing_size_limit> | |
| 61 | + <dependencies> | |
| 62 | + </dependencies> | |
| 63 | + <partitionschemas> | |
| 64 | + </partitionschemas> | |
| 65 | + <slaveservers> | |
| 66 | + </slaveservers> | |
| 67 | + <clusterschemas> | |
| 68 | + </clusterschemas> | |
| 69 | + <created_user>-</created_user> | |
| 70 | + <created_date>2016/06/30 12:21:57.536</created_date> | |
| 71 | + <modified_user>-</modified_user> | |
| 72 | + <modified_date>2016/06/30 12:21:57.536</modified_date> | |
| 73 | + <key_for_session_key>H4sIAAAAAAAAAAMAAAAAAAAAAAA=</key_for_session_key> | |
| 74 | + <is_key_private>N</is_key_private> | |
| 75 | + </info> | |
| 76 | + <notepads> | |
| 77 | + <notepad> | |
| 78 | + <note>字典表对应(以后直接查找表 bsth_c_sys_dictionary)
类型 代码 名称
LineTrend 0 上行
LineTrend 1 下行
ScheduleType normal 正常班次
ScheduleType out 出场
ScheduleType in 进场
ScheduleType temp 临加
ScheduleType region 区间
ScheduleType venting 放空
ScheduleType major 放大站</note> | |
| 79 | + <xloc>606</xloc> | |
| 80 | + <yloc>129</yloc> | |
| 81 | + <width>332</width> | |
| 82 | + <heigth>186</heigth> | |
| 83 | + <fontname>YaHei Consolas Hybrid</fontname> | |
| 84 | + <fontsize>12</fontsize> | |
| 85 | + <fontbold>N</fontbold> | |
| 86 | + <fontitalic>N</fontitalic> | |
| 87 | + <fontcolorred>0</fontcolorred> | |
| 88 | + <fontcolorgreen>0</fontcolorgreen> | |
| 89 | + <fontcolorblue>0</fontcolorblue> | |
| 90 | + <backgroundcolorred>255</backgroundcolorred> | |
| 91 | + <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 92 | + <backgroundcolorblue>112</backgroundcolorblue> | |
| 93 | + <bordercolorred>100</bordercolorred> | |
| 94 | + <bordercolorgreen>100</bordercolorgreen> | |
| 95 | + <bordercolorblue>100</bordercolorblue> | |
| 96 | + <drawshadow>Y</drawshadow> | |
| 97 | + </notepad> | |
| 98 | + <notepad> | |
| 99 | + <note>因为时刻表输入格式不确定性,主要因为表结构是反范式化的,
所以需要外部动态指定愿数据,头三个step动态指定愿数据

</note> | |
| 100 | + <xloc>79</xloc> | |
| 101 | + <yloc>206</yloc> | |
| 102 | + <width>346</width> | |
| 103 | + <heigth>74</heigth> | |
| 104 | + <fontname>YaHei Consolas Hybrid</fontname> | |
| 105 | + <fontsize>12</fontsize> | |
| 106 | + <fontbold>N</fontbold> | |
| 107 | + <fontitalic>N</fontitalic> | |
| 108 | + <fontcolorred>0</fontcolorred> | |
| 109 | + <fontcolorgreen>0</fontcolorgreen> | |
| 110 | + <fontcolorblue>0</fontcolorblue> | |
| 111 | + <backgroundcolorred>255</backgroundcolorred> | |
| 112 | + <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 113 | + <backgroundcolorblue>112</backgroundcolorblue> | |
| 114 | + <bordercolorred>100</bordercolorred> | |
| 115 | + <bordercolorgreen>100</bordercolorgreen> | |
| 116 | + <bordercolorblue>100</bordercolorblue> | |
| 117 | + <drawshadow>Y</drawshadow> | |
| 118 | + </notepad> | |
| 119 | + <notepad> | |
| 120 | + <note>这里有些问题
在window2012的环境下,
MySql数据库查询中如果返回中文内容的字段,这个内容乱码
解决办法,就是数据库查询全部缓存,就不乱码
linux环境下没问题</note> | |
| 121 | + <xloc>721</xloc> | |
| 122 | + <yloc>762</yloc> | |
| 123 | + <width>333</width> | |
| 124 | + <heigth>90</heigth> | |
| 125 | + <fontname>YaHei Consolas Hybrid</fontname> | |
| 126 | + <fontsize>12</fontsize> | |
| 127 | + <fontbold>N</fontbold> | |
| 128 | + <fontitalic>N</fontitalic> | |
| 129 | + <fontcolorred>0</fontcolorred> | |
| 130 | + <fontcolorgreen>0</fontcolorgreen> | |
| 131 | + <fontcolorblue>0</fontcolorblue> | |
| 132 | + <backgroundcolorred>255</backgroundcolorred> | |
| 133 | + <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 134 | + <backgroundcolorblue>112</backgroundcolorblue> | |
| 135 | + <bordercolorred>100</bordercolorred> | |
| 136 | + <bordercolorgreen>100</bordercolorgreen> | |
| 137 | + <bordercolorblue>100</bordercolorblue> | |
| 138 | + <drawshadow>Y</drawshadow> | |
| 139 | + </notepad> | |
| 140 | + <notepad> | |
| 141 | + <note>出场班次,方向有时确定不准,
空的情况下设定为0(上行)</note> | |
| 142 | + <xloc>120</xloc> | |
| 143 | + <yloc>1016</yloc> | |
| 144 | + <width>178</width> | |
| 145 | + <heigth>42</heigth> | |
| 146 | + <fontname>YaHei Consolas Hybrid</fontname> | |
| 147 | + <fontsize>12</fontsize> | |
| 148 | + <fontbold>N</fontbold> | |
| 149 | + <fontitalic>N</fontitalic> | |
| 150 | + <fontcolorred>0</fontcolorred> | |
| 151 | + <fontcolorgreen>0</fontcolorgreen> | |
| 152 | + <fontcolorblue>0</fontcolorblue> | |
| 153 | + <backgroundcolorred>255</backgroundcolorred> | |
| 154 | + <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 155 | + <backgroundcolorblue>112</backgroundcolorblue> | |
| 156 | + <bordercolorred>100</bordercolorred> | |
| 157 | + <bordercolorgreen>100</bordercolorgreen> | |
| 158 | + <bordercolorblue>100</bordercolorblue> | |
| 159 | + <drawshadow>Y</drawshadow> | |
| 160 | + </notepad> | |
| 161 | + <notepad> | |
| 162 | + <note>进场班次,方向有时确定不准,
空的情况下设定为0(上行)</note> | |
| 163 | + <xloc>578</xloc> | |
| 164 | + <yloc>1084</yloc> | |
| 165 | + <width>178</width> | |
| 166 | + <heigth>42</heigth> | |
| 167 | + <fontname>YaHei Consolas Hybrid</fontname> | |
| 168 | + <fontsize>12</fontsize> | |
| 169 | + <fontbold>N</fontbold> | |
| 170 | + <fontitalic>N</fontitalic> | |
| 171 | + <fontcolorred>0</fontcolorred> | |
| 172 | + <fontcolorgreen>0</fontcolorgreen> | |
| 173 | + <fontcolorblue>0</fontcolorblue> | |
| 174 | + <backgroundcolorred>255</backgroundcolorred> | |
| 175 | + <backgroundcolorgreen>205</backgroundcolorgreen> | |
| 176 | + <backgroundcolorblue>112</backgroundcolorblue> | |
| 177 | + <bordercolorred>100</bordercolorred> | |
| 178 | + <bordercolorgreen>100</bordercolorgreen> | |
| 179 | + <bordercolorblue>100</bordercolorblue> | |
| 180 | + <drawshadow>Y</drawshadow> | |
| 181 | + </notepad> | |
| 182 | + </notepads> | |
| 183 | + <connection> | |
| 184 | + <name>bus_control_variable</name> | |
| 185 | + <server>${v_db_ip}</server> | |
| 186 | + <type>MYSQL</type> | |
| 187 | + <access>Native</access> | |
| 188 | + <database>${v_db_dname}</database> | |
| 189 | + <port>3306</port> | |
| 190 | + <username>${v_db_uname}</username> | |
| 191 | + <password>${v_db_pwd}</password> | |
| 192 | + <servername/> | |
| 193 | + <data_tablespace/> | |
| 194 | + <index_tablespace/> | |
| 195 | + <attributes> | |
| 196 | + <attribute><code>EXTRA_OPTION_MYSQL.characterEncoding</code><attribute>utf8</attribute></attribute> | |
| 197 | + <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 198 | + <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 199 | + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 200 | + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 201 | + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 202 | + <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute> | |
| 203 | + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 204 | + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 205 | + <attribute><code>STREAM_RESULTS</code><attribute>N</attribute></attribute> | |
| 206 | + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 207 | + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 208 | + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 209 | + </attributes> | |
| 210 | + </connection> | |
| 211 | + <connection> | |
| 212 | + <name>bus_control_公司_201</name> | |
| 213 | + <server>localhost</server> | |
| 214 | + <type>MYSQL</type> | |
| 215 | + <access>Native</access> | |
| 216 | + <database>control</database> | |
| 217 | + <port>3306</port> | |
| 218 | + <username>root</username> | |
| 219 | + <password>Encrypted </password> | |
| 220 | + <servername/> | |
| 221 | + <data_tablespace/> | |
| 222 | + <index_tablespace/> | |
| 223 | + <attributes> | |
| 224 | + <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 225 | + <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 226 | + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 227 | + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 228 | + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 229 | + <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute> | |
| 230 | + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 231 | + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 232 | + <attribute><code>STREAM_RESULTS</code><attribute>N</attribute></attribute> | |
| 233 | + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 234 | + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 235 | + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 236 | + </attributes> | |
| 237 | + </connection> | |
| 238 | + <connection> | |
| 239 | + <name>bus_control_本机</name> | |
| 240 | + <server>localhost</server> | |
| 241 | + <type>MYSQL</type> | |
| 242 | + <access>Native</access> | |
| 243 | + <database>control</database> | |
| 244 | + <port>3306</port> | |
| 245 | + <username>root</username> | |
| 246 | + <password>Encrypted </password> | |
| 247 | + <servername/> | |
| 248 | + <data_tablespace/> | |
| 249 | + <index_tablespace/> | |
| 250 | + <attributes> | |
| 251 | + <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 252 | + <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 253 | + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 254 | + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 255 | + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 256 | + <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute> | |
| 257 | + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 258 | + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 259 | + <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute> | |
| 260 | + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 261 | + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 262 | + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 263 | + </attributes> | |
| 264 | + </connection> | |
| 265 | + <connection> | |
| 266 | + <name>xlab_mysql_youle</name> | |
| 267 | + <server>101.231.124.8</server> | |
| 268 | + <type>MYSQL</type> | |
| 269 | + <access>Native</access> | |
| 270 | + <database>xlab_youle</database> | |
| 271 | + <port>45687</port> | |
| 272 | + <username>xlab-youle</username> | |
| 273 | + <password>Encrypted 2be98afc86aa78a88aa1be369d187a3df</password> | |
| 274 | + <servername/> | |
| 275 | + <data_tablespace/> | |
| 276 | + <index_tablespace/> | |
| 277 | + <attributes> | |
| 278 | + <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 279 | + <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 280 | + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 281 | + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 282 | + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 283 | + <attribute><code>PORT_NUMBER</code><attribute>45687</attribute></attribute> | |
| 284 | + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 285 | + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 286 | + <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute> | |
| 287 | + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>N</attribute></attribute> | |
| 288 | + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>N</attribute></attribute> | |
| 289 | + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 290 | + </attributes> | |
| 291 | + </connection> | |
| 292 | + <connection> | |
| 293 | + <name>xlab_mysql_youle(本机)</name> | |
| 294 | + <server>localhost</server> | |
| 295 | + <type>MYSQL</type> | |
| 296 | + <access>Native</access> | |
| 297 | + <database>xlab_youle</database> | |
| 298 | + <port>3306</port> | |
| 299 | + <username>root</username> | |
| 300 | + <password>Encrypted </password> | |
| 301 | + <servername/> | |
| 302 | + <data_tablespace/> | |
| 303 | + <index_tablespace/> | |
| 304 | + <attributes> | |
| 305 | + <attribute><code>EXTRA_OPTION_MYSQL.defaultFetchSize</code><attribute>500</attribute></attribute> | |
| 306 | + <attribute><code>EXTRA_OPTION_MYSQL.useCursorFetch</code><attribute>true</attribute></attribute> | |
| 307 | + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 308 | + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 309 | + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 310 | + <attribute><code>PORT_NUMBER</code><attribute>3306</attribute></attribute> | |
| 311 | + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 312 | + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 313 | + <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute> | |
| 314 | + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>N</attribute></attribute> | |
| 315 | + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>N</attribute></attribute> | |
| 316 | + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 317 | + </attributes> | |
| 318 | + </connection> | |
| 319 | + <connection> | |
| 320 | + <name>xlab_youle</name> | |
| 321 | + <server/> | |
| 322 | + <type>MYSQL</type> | |
| 323 | + <access>JNDI</access> | |
| 324 | + <database>xlab_youle</database> | |
| 325 | + <port>1521</port> | |
| 326 | + <username/> | |
| 327 | + <password>Encrypted </password> | |
| 328 | + <servername/> | |
| 329 | + <data_tablespace/> | |
| 330 | + <index_tablespace/> | |
| 331 | + <attributes> | |
| 332 | + <attribute><code>FORCE_IDENTIFIERS_TO_LOWERCASE</code><attribute>N</attribute></attribute> | |
| 333 | + <attribute><code>FORCE_IDENTIFIERS_TO_UPPERCASE</code><attribute>N</attribute></attribute> | |
| 334 | + <attribute><code>IS_CLUSTERED</code><attribute>N</attribute></attribute> | |
| 335 | + <attribute><code>PORT_NUMBER</code><attribute>1521</attribute></attribute> | |
| 336 | + <attribute><code>PRESERVE_RESERVED_WORD_CASE</code><attribute>N</attribute></attribute> | |
| 337 | + <attribute><code>QUOTE_ALL_FIELDS</code><attribute>N</attribute></attribute> | |
| 338 | + <attribute><code>STREAM_RESULTS</code><attribute>Y</attribute></attribute> | |
| 339 | + <attribute><code>SUPPORTS_BOOLEAN_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 340 | + <attribute><code>SUPPORTS_TIMESTAMP_DATA_TYPE</code><attribute>Y</attribute></attribute> | |
| 341 | + <attribute><code>USE_POOLING</code><attribute>N</attribute></attribute> | |
| 342 | + </attributes> | |
| 343 | + </connection> | |
| 344 | + <order> | |
| 345 | + <hop> <from>时刻表明细信息Excel输入</from><to>班次数据范式化</to><enabled>Y</enabled> </hop> | |
| 346 | + <hop> <from>添加发车顺序号</from><to>过滤记录(发车时间为空)</to><enabled>Y</enabled> </hop> | |
| 347 | + <hop> <from>过滤记录(发车时间为空)</from><to>添加对应班次数</to><enabled>Y</enabled> </hop> | |
| 348 | + <hop> <from>添加对应班次数</from><to>处理数据</to><enabled>Y</enabled> </hop> | |
| 349 | + <hop> <from>处理数据</from><to>分组各个路牌的站</to><enabled>Y</enabled> </hop> | |
| 350 | + <hop> <from>查找时刻表基础信息关联</from><to>查找路牌关联</to><enabled>Y</enabled> </hop> | |
| 351 | + <hop> <from>查找线路关联</from><to>查找时刻表基础信息关联</to><enabled>Y</enabled> </hop> | |
| 352 | + <hop> <from>上下行字典</from><to>班次类型字典</to><enabled>Y</enabled> </hop> | |
| 353 | + <hop> <from>上下行字典 2</from><to>班次类型字典 2</to><enabled>Y</enabled> </hop> | |
| 354 | + <hop> <from>上下行字典 3</from><to>班次类型字典 3</to><enabled>Y</enabled> </hop> | |
| 355 | + <hop> <from>匹配上下行正常班次里程时间</from><to>类型修正</to><enabled>Y</enabled> </hop> | |
| 356 | + <hop> <from>按照班次类型过滤数据1</from><to>按照班次类型过滤数据2</to><enabled>Y</enabled> </hop> | |
| 357 | + <hop> <from>按照班次类型过滤数据1</from><to>正常班次数据</to><enabled>Y</enabled> </hop> | |
| 358 | + <hop> <from>按照班次类型过滤数据2</from><to>出场班次数据</to><enabled>Y</enabled> </hop> | |
| 359 | + <hop> <from>按照班次类型过滤数据2</from><to>进场班次数据</to><enabled>Y</enabled> </hop> | |
| 360 | + <hop> <from>查找线路上下行里程时间</from><to>匹配上下行正常班次里程时间</to><enabled>Y</enabled> </hop> | |
| 361 | + <hop> <from>查找终点站关联</from><to>上下行字典</to><enabled>Y</enabled> </hop> | |
| 362 | + <hop> <from>查找起点站关联并确定上下行</from><to>查找终点站关联</to><enabled>Y</enabled> </hop> | |
| 363 | + <hop> <from>正常班次_处理数据</from><to>查找起点站关联并确定上下行</to><enabled>Y</enabled> </hop> | |
| 364 | + <hop> <from>正常班次数据</from><to>正常班次_处理数据</to><enabled>Y</enabled> </hop> | |
| 365 | + <hop> <from>班次类型字典</from><to>查找线路上下行里程时间</to><enabled>Y</enabled> </hop> | |
| 366 | + <hop> <from>班次类型字典 2</from><to>查找线路出场里程时间</to><enabled>Y</enabled> </hop> | |
| 367 | + <hop> <from>班次类型字典 3</from><to>查找线路进场里程时间</to><enabled>Y</enabled> </hop> | |
| 368 | + <hop> <from>查找路牌关联</from><to>计算班次类型</to><enabled>Y</enabled> </hop> | |
| 369 | + <hop> <from>计算班次类型</from><to>按照班次类型过滤数据1</to><enabled>Y</enabled> </hop> | |
| 370 | + <hop> <from>出场班次数据</from><to>查找停车场1</to><enabled>Y</enabled> </hop> | |
| 371 | + <hop> <from>查找停车场1</from><to>出场班次_确定终点站名字</to><enabled>Y</enabled> </hop> | |
| 372 | + <hop> <from>出场班次_确定终点站名字</from><to>查找出场终点站关联并确定上下行</to><enabled>Y</enabled> </hop> | |
| 373 | + <hop> <from>查找出场终点站关联并确定上下行</from><to>上下行字典 2</to><enabled>Y</enabled> </hop> | |
| 374 | + <hop> <from>进场班次数据</from><to>查找停车场2</to><enabled>Y</enabled> </hop> | |
| 375 | + <hop> <from>查找停车场2</from><to>进场班次_确定起点站名字</to><enabled>Y</enabled> </hop> | |
| 376 | + <hop> <from>进场班次_确定起点站名字</from><to>查找进场班次上一个班次的线路方向</to><enabled>Y</enabled> </hop> | |
| 377 | + <hop> <from>查找进场班次上一个班次的线路方向</from><to>查找进场班次上一个班次的终点站,并作为进场班次的起点站</to><enabled>Y</enabled> </hop> | |
| 378 | + <hop> <from>字段选择</from><to>添加发车顺序号</to><enabled>Y</enabled> </hop> | |
| 379 | + <hop> <from>分组各个路牌的站</from><to>查找线路关联</to><enabled>Y</enabled> </hop> | |
| 380 | + <hop> <from>增加时刻表名字,线路名字,停车场名字</from><to>记录关联 (笛卡尔输出)</to><enabled>Y</enabled> </hop> | |
| 381 | + <hop> <from>班次数据范式化</from><to>记录关联 (笛卡尔输出)</to><enabled>Y</enabled> </hop> | |
| 382 | + <hop> <from>记录关联 (笛卡尔输出)</from><to>字段选择</to><enabled>Y</enabled> </hop> | |
| 383 | + <hop> <from>类型修正</from><to>插入/更新bsth_c_s_ttinfo_detail</to><enabled>Y</enabled> </hop> | |
| 384 | + <hop> <from>查找进场班次上一个班次的终点站,并作为进场班次的起点站</from><to>查找进场起点站关联确定上下行</to><enabled>Y</enabled> </hop> | |
| 385 | + <hop> <from>查找进场起点站关联确定上下行</from><to>上下行字典 3</to><enabled>Y</enabled> </hop> | |
| 386 | + <hop> <from>查找线路出场里程时间</from><to>匹配出场班次里程时间</to><enabled>Y</enabled> </hop> | |
| 387 | + <hop> <from>查找线路进场里程时间</from><to>匹配进场班次里程时间</to><enabled>Y</enabled> </hop> | |
| 388 | + <hop> <from>匹配出场班次里程时间</from><to>上下行NULL判定</to><enabled>Y</enabled> </hop> | |
| 389 | + <hop> <from>上下行NULL判定</from><to>类型修正 2</to><enabled>Y</enabled> </hop> | |
| 390 | + <hop> <from>类型修正 2</from><to>插入/更新bsth_c_s_ttinfo_detail 2</to><enabled>Y</enabled> </hop> | |
| 391 | + <hop> <from>匹配进场班次里程时间</from><to>上下行判定 2</to><enabled>Y</enabled> </hop> | |
| 392 | + <hop> <from>上下行判定 2</from><to>类型修正 3</to><enabled>Y</enabled> </hop> | |
| 393 | + <hop> <from>类型修正 3</from><to>插入/更新bsth_c_s_ttinfo_detail 3</to><enabled>Y</enabled> </hop> | |
| 394 | + </order> | |
| 395 | + <step> | |
| 396 | + <name>上下行字典</name> | |
| 397 | + <type>ValueMapper</type> | |
| 398 | + <description/> | |
| 399 | + <distribute>Y</distribute> | |
| 400 | + <custom_distribution/> | |
| 401 | + <copies>1</copies> | |
| 402 | + <partitioning> | |
| 403 | + <method>none</method> | |
| 404 | + <schema_name/> | |
| 405 | + </partitioning> | |
| 406 | + <field_to_use>sxx</field_to_use> | |
| 407 | + <target_field>sxx_desc</target_field> | |
| 408 | + <non_match_default/> | |
| 409 | + <fields> | |
| 410 | + <field> | |
| 411 | + <source_value>0</source_value> | |
| 412 | + <target_value>上行</target_value> | |
| 413 | + </field> | |
| 414 | + <field> | |
| 415 | + <source_value>1</source_value> | |
| 416 | + <target_value>下行</target_value> | |
| 417 | + </field> | |
| 418 | + </fields> | |
| 419 | + <cluster_schema/> | |
| 420 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 421 | + <xloc>147</xloc> | |
| 422 | + <yloc>403</yloc> | |
| 423 | + <draw>Y</draw> | |
| 424 | + </GUI> | |
| 425 | + </step> | |
| 426 | + | |
| 427 | + <step> | |
| 428 | + <name>上下行字典 2</name> | |
| 429 | + <type>ValueMapper</type> | |
| 430 | + <description/> | |
| 431 | + <distribute>Y</distribute> | |
| 432 | + <custom_distribution/> | |
| 433 | + <copies>1</copies> | |
| 434 | + <partitioning> | |
| 435 | + <method>none</method> | |
| 436 | + <schema_name/> | |
| 437 | + </partitioning> | |
| 438 | + <field_to_use>sxx</field_to_use> | |
| 439 | + <target_field>sxx_desc</target_field> | |
| 440 | + <non_match_default/> | |
| 441 | + <fields> | |
| 442 | + <field> | |
| 443 | + <source_value>0</source_value> | |
| 444 | + <target_value>上行</target_value> | |
| 445 | + </field> | |
| 446 | + <field> | |
| 447 | + <source_value>1</source_value> | |
| 448 | + <target_value>下行</target_value> | |
| 449 | + </field> | |
| 450 | + </fields> | |
| 451 | + <cluster_schema/> | |
| 452 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 453 | + <xloc>331</xloc> | |
| 454 | + <yloc>598</yloc> | |
| 455 | + <draw>Y</draw> | |
| 456 | + </GUI> | |
| 457 | + </step> | |
| 458 | + | |
| 459 | + <step> | |
| 460 | + <name>上下行字典 3</name> | |
| 461 | + <type>ValueMapper</type> | |
| 462 | + <description/> | |
| 463 | + <distribute>Y</distribute> | |
| 464 | + <custom_distribution/> | |
| 465 | + <copies>1</copies> | |
| 466 | + <partitioning> | |
| 467 | + <method>none</method> | |
| 468 | + <schema_name/> | |
| 469 | + </partitioning> | |
| 470 | + <field_to_use>sxx</field_to_use> | |
| 471 | + <target_field>sxx_desc</target_field> | |
| 472 | + <non_match_default/> | |
| 473 | + <fields> | |
| 474 | + <field> | |
| 475 | + <source_value>0</source_value> | |
| 476 | + <target_value>上行</target_value> | |
| 477 | + </field> | |
| 478 | + <field> | |
| 479 | + <source_value>1</source_value> | |
| 480 | + <target_value>下行</target_value> | |
| 481 | + </field> | |
| 482 | + </fields> | |
| 483 | + <cluster_schema/> | |
| 484 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 485 | + <xloc>553</xloc> | |
| 486 | + <yloc>859</yloc> | |
| 487 | + <draw>Y</draw> | |
| 488 | + </GUI> | |
| 489 | + </step> | |
| 490 | + | |
| 491 | + <step> | |
| 492 | + <name>出场班次_确定终点站名字</name> | |
| 493 | + <type>ScriptValueMod</type> | |
| 494 | + <description/> | |
| 495 | + <distribute>Y</distribute> | |
| 496 | + <custom_distribution/> | |
| 497 | + <copies>1</copies> | |
| 498 | + <partitioning> | |
| 499 | + <method>none</method> | |
| 500 | + <schema_name/> | |
| 501 | + </partitioning> | |
| 502 | + <compatible>N</compatible> | |
| 503 | + <optimizationLevel>9</optimizationLevel> | |
| 504 | + <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 505 | + <jsScript_name>Script 1</jsScript_name> | |
| 506 | + <jsScript_script>//Script here

// 添加站点标识
var cc_groups = qdzgroups.split(","); // 所有班次起点站数组
var zdzname = cc_groups[gno]; // 出场班次的终点站是下个班次的起始站
var endZdtype = 'E';

var destory = 0; // 未撤销flag</jsScript_script> | |
| 507 | + </jsScript> </jsScripts> <fields> <field> <name>zdzname</name> | |
| 508 | + <rename>zdzname</rename> | |
| 509 | + <type>String</type> | |
| 510 | + <length>-1</length> | |
| 511 | + <precision>-1</precision> | |
| 512 | + <replace>N</replace> | |
| 513 | + </field> <field> <name>endZdtype</name> | |
| 514 | + <rename>endZdtype</rename> | |
| 515 | + <type>String</type> | |
| 516 | + <length>-1</length> | |
| 517 | + <precision>-1</precision> | |
| 518 | + <replace>N</replace> | |
| 519 | + </field> <field> <name>destory</name> | |
| 520 | + <rename>destory</rename> | |
| 521 | + <type>Integer</type> | |
| 522 | + <length>-1</length> | |
| 523 | + <precision>-1</precision> | |
| 524 | + <replace>N</replace> | |
| 525 | + </field> </fields> <cluster_schema/> | |
| 526 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 527 | + <xloc>575</xloc> | |
| 528 | + <yloc>502</yloc> | |
| 529 | + <draw>Y</draw> | |
| 530 | + </GUI> | |
| 531 | + </step> | |
| 532 | + | |
| 533 | + <step> | |
| 534 | + <name>出场班次数据</name> | |
| 535 | + <type>Dummy</type> | |
| 536 | + <description/> | |
| 537 | + <distribute>Y</distribute> | |
| 538 | + <custom_distribution/> | |
| 539 | + <copies>1</copies> | |
| 540 | + <partitioning> | |
| 541 | + <method>none</method> | |
| 542 | + <schema_name/> | |
| 543 | + </partitioning> | |
| 544 | + <cluster_schema/> | |
| 545 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 546 | + <xloc>869</xloc> | |
| 547 | + <yloc>504</yloc> | |
| 548 | + <draw>Y</draw> | |
| 549 | + </GUI> | |
| 550 | + </step> | |
| 551 | + | |
| 552 | + <step> | |
| 553 | + <name>分组各个路牌的站</name> | |
| 554 | + <type>GroupBy</type> | |
| 555 | + <description/> | |
| 556 | + <distribute>Y</distribute> | |
| 557 | + <custom_distribution/> | |
| 558 | + <copies>1</copies> | |
| 559 | + <partitioning> | |
| 560 | + <method>none</method> | |
| 561 | + <schema_name/> | |
| 562 | + </partitioning> | |
| 563 | + <all_rows>Y</all_rows> | |
| 564 | + <ignore_aggregate>N</ignore_aggregate> | |
| 565 | + <field_ignore/> | |
| 566 | + <directory>%%java.io.tmpdir%%</directory> | |
| 567 | + <prefix>grp</prefix> | |
| 568 | + <add_linenr>Y</add_linenr> | |
| 569 | + <linenr_fieldname>gno</linenr_fieldname> | |
| 570 | + <give_back_row>N</give_back_row> | |
| 571 | + <group> | |
| 572 | + <field> | |
| 573 | + <name>lp</name> | |
| 574 | + </field> | |
| 575 | + </group> | |
| 576 | + <fields> | |
| 577 | + <field> | |
| 578 | + <aggregate>qdzgroups</aggregate> | |
| 579 | + <subject>qdzname</subject> | |
| 580 | + <type>CONCAT_STRING</type> | |
| 581 | + <valuefield>,</valuefield> | |
| 582 | + </field> | |
| 583 | + </fields> | |
| 584 | + <cluster_schema/> | |
| 585 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 586 | + <xloc>892</xloc> | |
| 587 | + <yloc>44</yloc> | |
| 588 | + <draw>Y</draw> | |
| 589 | + </GUI> | |
| 590 | + </step> | |
| 591 | + | |
| 592 | + <step> | |
| 593 | + <name>匹配上下行正常班次里程时间</name> | |
| 594 | + <type>ScriptValueMod</type> | |
| 595 | + <description/> | |
| 596 | + <distribute>Y</distribute> | |
| 597 | + <custom_distribution/> | |
| 598 | + <copies>1</copies> | |
| 599 | + <partitioning> | |
| 600 | + <method>none</method> | |
| 601 | + <schema_name/> | |
| 602 | + </partitioning> | |
| 603 | + <compatible>N</compatible> | |
| 604 | + <optimizationLevel>9</optimizationLevel> | |
| 605 | + <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 606 | + <jsScript_name>Script 1</jsScript_name> | |
| 607 | + <jsScript_script>//Script here

var jhlc; // 计划里程
var bcsj; // 班次时间

if (sxx == 0) { // 上行
 jhlc = up_mileage;
 bcsj = up_travel_time;
} else { // sxx == 1 下行
 jhlc = down_mileage;
 bcsj = down_travel_time;
}</jsScript_script> | |
| 608 | + </jsScript> </jsScripts> <fields> <field> <name>jhlc</name> | |
| 609 | + <rename>jhlc</rename> | |
| 610 | + <type>String</type> | |
| 611 | + <length>-1</length> | |
| 612 | + <precision>-1</precision> | |
| 613 | + <replace>N</replace> | |
| 614 | + </field> <field> <name>bcsj</name> | |
| 615 | + <rename>bcsj</rename> | |
| 616 | + <type>String</type> | |
| 617 | + <length>-1</length> | |
| 618 | + <precision>-1</precision> | |
| 619 | + <replace>N</replace> | |
| 620 | + </field> </fields> <cluster_schema/> | |
| 621 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 622 | + <xloc>148</xloc> | |
| 623 | + <yloc>674</yloc> | |
| 624 | + <draw>Y</draw> | |
| 625 | + </GUI> | |
| 626 | + </step> | |
| 627 | + | |
| 628 | + <step> | |
| 629 | + <name>匹配出场班次里程时间</name> | |
| 630 | + <type>ScriptValueMod</type> | |
| 631 | + <description/> | |
| 632 | + <distribute>Y</distribute> | |
| 633 | + <custom_distribution/> | |
| 634 | + <copies>1</copies> | |
| 635 | + <partitioning> | |
| 636 | + <method>none</method> | |
| 637 | + <schema_name/> | |
| 638 | + </partitioning> | |
| 639 | + <compatible>N</compatible> | |
| 640 | + <optimizationLevel>9</optimizationLevel> | |
| 641 | + <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 642 | + <jsScript_name>Script 1</jsScript_name> | |
| 643 | + <jsScript_script>//Script here

var out_mileage; // 出场计划里程
var out_time; // 出场计划时间

if (sxx == 0) { // 上行
 out_mileage = up_out_mileage;
 out_time = up_out_timer;
} else { // sxx == 1 下行
 out_mileage = down_out_mileage;
 out_time = down_out_timer;
}



</jsScript_script> | |
| 644 | + </jsScript> </jsScripts> <fields> <field> <name>out_mileage</name> | |
| 645 | + <rename>out_mileage</rename> | |
| 646 | + <type>String</type> | |
| 647 | + <length>-1</length> | |
| 648 | + <precision>-1</precision> | |
| 649 | + <replace>N</replace> | |
| 650 | + </field> <field> <name>out_time</name> | |
| 651 | + <rename>out_time</rename> | |
| 652 | + <type>String</type> | |
| 653 | + <length>-1</length> | |
| 654 | + <precision>-1</precision> | |
| 655 | + <replace>N</replace> | |
| 656 | + </field> </fields> <cluster_schema/> | |
| 657 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 658 | + <xloc>336</xloc> | |
| 659 | + <yloc>862</yloc> | |
| 660 | + <draw>Y</draw> | |
| 661 | + </GUI> | |
| 662 | + </step> | |
| 663 | + | |
| 664 | + <step> | |
| 665 | + <name>匹配进场班次里程时间</name> | |
| 666 | + <type>ScriptValueMod</type> | |
| 667 | + <description/> | |
| 668 | + <distribute>Y</distribute> | |
| 669 | + <custom_distribution/> | |
| 670 | + <copies>1</copies> | |
| 671 | + <partitioning> | |
| 672 | + <method>none</method> | |
| 673 | + <schema_name/> | |
| 674 | + </partitioning> | |
| 675 | + <compatible>N</compatible> | |
| 676 | + <optimizationLevel>9</optimizationLevel> | |
| 677 | + <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 678 | + <jsScript_name>Script 1</jsScript_name> | |
| 679 | + <jsScript_script>//Script here

var parade_mileage; // 进场计划里程
var parade_time; // 进场计划时间

if (sxx2 == 0) { // 上行
 parade_mileage = up_in_mileage;
 parade_time = up_in_timer;
} else { // sxx == 1 下行
 parade_mileage = down_in_mileage;
 parade_time = down_in_timer;
}



</jsScript_script> | |
| 680 | + </jsScript> </jsScripts> <fields> <field> <name>parade_mileage</name> | |
| 681 | + <rename>parade_mileage</rename> | |
| 682 | + <type>String</type> | |
| 683 | + <length>-1</length> | |
| 684 | + <precision>-1</precision> | |
| 685 | + <replace>N</replace> | |
| 686 | + </field> <field> <name>parade_time</name> | |
| 687 | + <rename>parade_time</rename> | |
| 688 | + <type>String</type> | |
| 689 | + <length>-1</length> | |
| 690 | + <precision>-1</precision> | |
| 691 | + <replace>N</replace> | |
| 692 | + </field> </fields> <cluster_schema/> | |
| 693 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 694 | + <xloc>726</xloc> | |
| 695 | + <yloc>1005</yloc> | |
| 696 | + <draw>Y</draw> | |
| 697 | + </GUI> | |
| 698 | + </step> | |
| 699 | + | |
| 700 | + <step> | |
| 701 | + <name>增加时刻表名字,线路名字,停车场名字</name> | |
| 702 | + <type>DataGrid</type> | |
| 703 | + <description/> | |
| 704 | + <distribute>Y</distribute> | |
| 705 | + <custom_distribution/> | |
| 706 | + <copies>1</copies> | |
| 707 | + <partitioning> | |
| 708 | + <method>none</method> | |
| 709 | + <schema_name/> | |
| 710 | + </partitioning> | |
| 711 | + <fields> | |
| 712 | + </fields> | |
| 713 | + <data> | |
| 714 | + <line> </line> | |
| 715 | + </data> | |
| 716 | + <cluster_schema/> | |
| 717 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 718 | + <xloc>110</xloc> | |
| 719 | + <yloc>133</yloc> | |
| 720 | + <draw>Y</draw> | |
| 721 | + </GUI> | |
| 722 | + </step> | |
| 723 | + | |
| 724 | + <step> | |
| 725 | + <name>处理数据</name> | |
| 726 | + <type>ScriptValueMod</type> | |
| 727 | + <description/> | |
| 728 | + <distribute>Y</distribute> | |
| 729 | + <custom_distribution/> | |
| 730 | + <copies>1</copies> | |
| 731 | + <partitioning> | |
| 732 | + <method>none</method> | |
| 733 | + <schema_name/> | |
| 734 | + </partitioning> | |
| 735 | + <compatible>N</compatible> | |
| 736 | + <optimizationLevel>9</optimizationLevel> | |
| 737 | + <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 738 | + <jsScript_name>Script 1</jsScript_name> | |
| 739 | + <jsScript_script>//Script here

// 使用正则表达式去除站点名称中的数字
qdzname = qdzname.replace(/\d+/g,'');

// sendtime处理
var sendtime_calcu;
if (sendtime.length != 5) 
 sendtime_calcu = sendtime.substr(0, 2) + ":" + sendtime.substr(2, 2);
else 
 sendtime_calcu = sendtime;

// 设置分班
var isfb = 0;

// 设置isCanceled
var iscanceled = 0;</jsScript_script> | |
| 740 | + </jsScript> </jsScripts> <fields> <field> <name>qdzname</name> | |
| 741 | + <rename>qdzname</rename> | |
| 742 | + <type>String</type> | |
| 743 | + <length>-1</length> | |
| 744 | + <precision>-1</precision> | |
| 745 | + <replace>Y</replace> | |
| 746 | + </field> <field> <name>isfb</name> | |
| 747 | + <rename>isfb</rename> | |
| 748 | + <type>Integer</type> | |
| 749 | + <length>-1</length> | |
| 750 | + <precision>-1</precision> | |
| 751 | + <replace>N</replace> | |
| 752 | + </field> <field> <name>iscanceled</name> | |
| 753 | + <rename>iscanceled</rename> | |
| 754 | + <type>Integer</type> | |
| 755 | + <length>-1</length> | |
| 756 | + <precision>-1</precision> | |
| 757 | + <replace>N</replace> | |
| 758 | + </field> <field> <name>sendtime_calcu</name> | |
| 759 | + <rename>sendtime_calcu</rename> | |
| 760 | + <type>String</type> | |
| 761 | + <length>-1</length> | |
| 762 | + <precision>-1</precision> | |
| 763 | + <replace>N</replace> | |
| 764 | + </field> </fields> <cluster_schema/> | |
| 765 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 766 | + <xloc>788</xloc> | |
| 767 | + <yloc>44</yloc> | |
| 768 | + <draw>Y</draw> | |
| 769 | + </GUI> | |
| 770 | + </step> | |
| 771 | + | |
| 772 | + <step> | |
| 773 | + <name>字段选择</name> | |
| 774 | + <type>SelectValues</type> | |
| 775 | + <description/> | |
| 776 | + <distribute>Y</distribute> | |
| 777 | + <custom_distribution/> | |
| 778 | + <copies>1</copies> | |
| 779 | + <partitioning> | |
| 780 | + <method>none</method> | |
| 781 | + <schema_name/> | |
| 782 | + </partitioning> | |
| 783 | + <fields> <field> <name>路牌</name> | |
| 784 | + <rename>lp</rename> | |
| 785 | + <length>-2</length> | |
| 786 | + <precision>-2</precision> | |
| 787 | + </field> <field> <name>站点名称</name> | |
| 788 | + <rename>qdzname</rename> | |
| 789 | + <length>-2</length> | |
| 790 | + <precision>-2</precision> | |
| 791 | + </field> <field> <name>发车时间</name> | |
| 792 | + <rename>sendtime</rename> | |
| 793 | + <length>-2</length> | |
| 794 | + <precision>-2</precision> | |
| 795 | + </field> <select_unspecified>Y</select_unspecified> | |
| 796 | + </fields> <cluster_schema/> | |
| 797 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 798 | + <xloc>444</xloc> | |
| 799 | + <yloc>131</yloc> | |
| 800 | + <draw>Y</draw> | |
| 801 | + </GUI> | |
| 802 | + </step> | |
| 803 | + | |
| 804 | + <step> | |
| 805 | + <name>按照班次类型过滤数据1</name> | |
| 806 | + <type>FilterRows</type> | |
| 807 | + <description/> | |
| 808 | + <distribute>Y</distribute> | |
| 809 | + <custom_distribution/> | |
| 810 | + <copies>1</copies> | |
| 811 | + <partitioning> | |
| 812 | + <method>none</method> | |
| 813 | + <schema_name/> | |
| 814 | + </partitioning> | |
| 815 | +<send_true_to>正常班次数据</send_true_to> | |
| 816 | +<send_false_to>按照班次类型过滤数据2</send_false_to> | |
| 817 | + <compare> | |
| 818 | +<condition> | |
| 819 | + <negated>N</negated> | |
| 820 | + <leftvalue>bctype</leftvalue> | |
| 821 | + <function>=</function> | |
| 822 | + <rightvalue/> | |
| 823 | + <value><name>constant</name><type>String</type><text>正常班次</text><length>-1</length><precision>-1</precision><isnull>N</isnull><mask/></value> </condition> | |
| 824 | + </compare> | |
| 825 | + <cluster_schema/> | |
| 826 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 827 | + <xloc>860</xloc> | |
| 828 | + <yloc>401</yloc> | |
| 829 | + <draw>Y</draw> | |
| 830 | + </GUI> | |
| 831 | + </step> | |
| 832 | + | |
| 833 | + <step> | |
| 834 | + <name>按照班次类型过滤数据2</name> | |
| 835 | + <type>FilterRows</type> | |
| 836 | + <description/> | |
| 837 | + <distribute>Y</distribute> | |
| 838 | + <custom_distribution/> | |
| 839 | + <copies>1</copies> | |
| 840 | + <partitioning> | |
| 841 | + <method>none</method> | |
| 842 | + <schema_name/> | |
| 843 | + </partitioning> | |
| 844 | +<send_true_to>出场班次数据</send_true_to> | |
| 845 | +<send_false_to>进场班次数据</send_false_to> | |
| 846 | + <compare> | |
| 847 | +<condition> | |
| 848 | + <negated>N</negated> | |
| 849 | + <leftvalue>bctype</leftvalue> | |
| 850 | + <function>=</function> | |
| 851 | + <rightvalue/> | |
| 852 | + <value><name>constant</name><type>String</type><text>出场</text><length>-1</length><precision>-1</precision><isnull>N</isnull><mask/></value> </condition> | |
| 853 | + </compare> | |
| 854 | + <cluster_schema/> | |
| 855 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 856 | + <xloc>995</xloc> | |
| 857 | + <yloc>503</yloc> | |
| 858 | + <draw>Y</draw> | |
| 859 | + </GUI> | |
| 860 | + </step> | |
| 861 | + | |
| 862 | + <step> | |
| 863 | + <name>插入/更新bsth_c_s_ttinfo_detail</name> | |
| 864 | + <type>InsertUpdate</type> | |
| 865 | + <description/> | |
| 866 | + <distribute>Y</distribute> | |
| 867 | + <custom_distribution/> | |
| 868 | + <copies>1</copies> | |
| 869 | + <partitioning> | |
| 870 | + <method>none</method> | |
| 871 | + <schema_name/> | |
| 872 | + </partitioning> | |
| 873 | + <connection>bus_control_variable</connection> | |
| 874 | + <commit>100</commit> | |
| 875 | + <update_bypassed>N</update_bypassed> | |
| 876 | + <lookup> | |
| 877 | + <schema/> | |
| 878 | + <table>bsth_c_s_ttinfo_detail</table> | |
| 879 | + <key> | |
| 880 | + <name>xlid</name> | |
| 881 | + <field>xl</field> | |
| 882 | + <condition>=</condition> | |
| 883 | + <name2/> | |
| 884 | + </key> | |
| 885 | + <key> | |
| 886 | + <name>ttid</name> | |
| 887 | + <field>ttinfo</field> | |
| 888 | + <condition>=</condition> | |
| 889 | + <name2/> | |
| 890 | + </key> | |
| 891 | + <key> | |
| 892 | + <name>lpid</name> | |
| 893 | + <field>lp</field> | |
| 894 | + <condition>=</condition> | |
| 895 | + <name2/> | |
| 896 | + </key> | |
| 897 | + <key> | |
| 898 | + <name>fcno</name> | |
| 899 | + <field>fcno</field> | |
| 900 | + <condition>=</condition> | |
| 901 | + <name2/> | |
| 902 | + </key> | |
| 903 | + <key> | |
| 904 | + <name>bcs</name> | |
| 905 | + <field>bcs</field> | |
| 906 | + <condition>=</condition> | |
| 907 | + <name2/> | |
| 908 | + </key> | |
| 909 | + <value> | |
| 910 | + <name>lp</name> | |
| 911 | + <rename>lpid</rename> | |
| 912 | + <update>Y</update> | |
| 913 | + </value> | |
| 914 | + <value> | |
| 915 | + <name>bc_type</name> | |
| 916 | + <rename>bctype_code</rename> | |
| 917 | + <update>Y</update> | |
| 918 | + </value> | |
| 919 | + <value> | |
| 920 | + <name>bcs</name> | |
| 921 | + <rename>bcs</rename> | |
| 922 | + <update>Y</update> | |
| 923 | + </value> | |
| 924 | + <value> | |
| 925 | + <name>bcsj</name> | |
| 926 | + <rename>bcsj</rename> | |
| 927 | + <update>Y</update> | |
| 928 | + </value> | |
| 929 | + <value> | |
| 930 | + <name>fcno</name> | |
| 931 | + <rename>fcno</rename> | |
| 932 | + <update>Y</update> | |
| 933 | + </value> | |
| 934 | + <value> | |
| 935 | + <name>jhlc</name> | |
| 936 | + <rename>jhlc</rename> | |
| 937 | + <update>Y</update> | |
| 938 | + </value> | |
| 939 | + <value> | |
| 940 | + <name>fcsj</name> | |
| 941 | + <rename>sendtime_calcu</rename> | |
| 942 | + <update>Y</update> | |
| 943 | + </value> | |
| 944 | + <value> | |
| 945 | + <name>ttinfo</name> | |
| 946 | + <rename>ttid</rename> | |
| 947 | + <update>Y</update> | |
| 948 | + </value> | |
| 949 | + <value> | |
| 950 | + <name>xl</name> | |
| 951 | + <rename>xlid</rename> | |
| 952 | + <update>Y</update> | |
| 953 | + </value> | |
| 954 | + <value> | |
| 955 | + <name>qdz</name> | |
| 956 | + <rename>qdzid</rename> | |
| 957 | + <update>Y</update> | |
| 958 | + </value> | |
| 959 | + <value> | |
| 960 | + <name>zdz</name> | |
| 961 | + <rename>zdzid</rename> | |
| 962 | + <update>Y</update> | |
| 963 | + </value> | |
| 964 | + <value> | |
| 965 | + <name>xl_dir</name> | |
| 966 | + <rename>sxx</rename> | |
| 967 | + <update>Y</update> | |
| 968 | + </value> | |
| 969 | + <value> | |
| 970 | + <name>isfb</name> | |
| 971 | + <rename>isfb</rename> | |
| 972 | + <update>Y</update> | |
| 973 | + </value> | |
| 974 | + </lookup> | |
| 975 | + <cluster_schema/> | |
| 976 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 977 | + <xloc>143</xloc> | |
| 978 | + <yloc>860</yloc> | |
| 979 | + <draw>Y</draw> | |
| 980 | + </GUI> | |
| 981 | + </step> | |
| 982 | + | |
| 983 | + <step> | |
| 984 | + <name>插入/更新bsth_c_s_ttinfo_detail 2</name> | |
| 985 | + <type>InsertUpdate</type> | |
| 986 | + <description/> | |
| 987 | + <distribute>Y</distribute> | |
| 988 | + <custom_distribution/> | |
| 989 | + <copies>1</copies> | |
| 990 | + <partitioning> | |
| 991 | + <method>none</method> | |
| 992 | + <schema_name/> | |
| 993 | + </partitioning> | |
| 994 | + <connection>bus_control_variable</connection> | |
| 995 | + <commit>100</commit> | |
| 996 | + <update_bypassed>N</update_bypassed> | |
| 997 | + <lookup> | |
| 998 | + <schema/> | |
| 999 | + <table>bsth_c_s_ttinfo_detail</table> | |
| 1000 | + <key> | |
| 1001 | + <name>xlid</name> | |
| 1002 | + <field>xl</field> | |
| 1003 | + <condition>=</condition> | |
| 1004 | + <name2/> | |
| 1005 | + </key> | |
| 1006 | + <key> | |
| 1007 | + <name>ttid</name> | |
| 1008 | + <field>ttinfo</field> | |
| 1009 | + <condition>=</condition> | |
| 1010 | + <name2/> | |
| 1011 | + </key> | |
| 1012 | + <key> | |
| 1013 | + <name>lpid</name> | |
| 1014 | + <field>lp</field> | |
| 1015 | + <condition>=</condition> | |
| 1016 | + <name2/> | |
| 1017 | + </key> | |
| 1018 | + <key> | |
| 1019 | + <name>fcno</name> | |
| 1020 | + <field>fcno</field> | |
| 1021 | + <condition>=</condition> | |
| 1022 | + <name2/> | |
| 1023 | + </key> | |
| 1024 | + <key> | |
| 1025 | + <name>bcs</name> | |
| 1026 | + <field>bcs</field> | |
| 1027 | + <condition>=</condition> | |
| 1028 | + <name2/> | |
| 1029 | + </key> | |
| 1030 | + <value> | |
| 1031 | + <name>tcc</name> | |
| 1032 | + <rename>qdzid</rename> | |
| 1033 | + <update>Y</update> | |
| 1034 | + </value> | |
| 1035 | + <value> | |
| 1036 | + <name>zdz</name> | |
| 1037 | + <rename>zdzid</rename> | |
| 1038 | + <update>Y</update> | |
| 1039 | + </value> | |
| 1040 | + <value> | |
| 1041 | + <name>xl</name> | |
| 1042 | + <rename>xlid</rename> | |
| 1043 | + <update>Y</update> | |
| 1044 | + </value> | |
| 1045 | + <value> | |
| 1046 | + <name>ttinfo</name> | |
| 1047 | + <rename>ttid</rename> | |
| 1048 | + <update>Y</update> | |
| 1049 | + </value> | |
| 1050 | + <value> | |
| 1051 | + <name>xl_dir</name> | |
| 1052 | + <rename>sxx</rename> | |
| 1053 | + <update>Y</update> | |
| 1054 | + </value> | |
| 1055 | + <value> | |
| 1056 | + <name>lp</name> | |
| 1057 | + <rename>lpid</rename> | |
| 1058 | + <update>Y</update> | |
| 1059 | + </value> | |
| 1060 | + <value> | |
| 1061 | + <name>jhlc</name> | |
| 1062 | + <rename>out_mileage</rename> | |
| 1063 | + <update>Y</update> | |
| 1064 | + </value> | |
| 1065 | + <value> | |
| 1066 | + <name>fcsj</name> | |
| 1067 | + <rename>sendtime_calcu</rename> | |
| 1068 | + <update>Y</update> | |
| 1069 | + </value> | |
| 1070 | + <value> | |
| 1071 | + <name>bcsj</name> | |
| 1072 | + <rename>out_time</rename> | |
| 1073 | + <update>Y</update> | |
| 1074 | + </value> | |
| 1075 | + <value> | |
| 1076 | + <name>bcs</name> | |
| 1077 | + <rename>bcs</rename> | |
| 1078 | + <update>Y</update> | |
| 1079 | + </value> | |
| 1080 | + <value> | |
| 1081 | + <name>fcno</name> | |
| 1082 | + <rename>fcno</rename> | |
| 1083 | + <update>Y</update> | |
| 1084 | + </value> | |
| 1085 | + <value> | |
| 1086 | + <name>bc_type</name> | |
| 1087 | + <rename>bctype_code</rename> | |
| 1088 | + <update>Y</update> | |
| 1089 | + </value> | |
| 1090 | + <value> | |
| 1091 | + <name>isfb</name> | |
| 1092 | + <rename>isfb</rename> | |
| 1093 | + <update>Y</update> | |
| 1094 | + </value> | |
| 1095 | + </lookup> | |
| 1096 | + <cluster_schema/> | |
| 1097 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1098 | + <xloc>340</xloc> | |
| 1099 | + <yloc>1087</yloc> | |
| 1100 | + <draw>Y</draw> | |
| 1101 | + </GUI> | |
| 1102 | + </step> | |
| 1103 | + | |
| 1104 | + <step> | |
| 1105 | + <name>插入/更新bsth_c_s_ttinfo_detail 3</name> | |
| 1106 | + <type>InsertUpdate</type> | |
| 1107 | + <description/> | |
| 1108 | + <distribute>Y</distribute> | |
| 1109 | + <custom_distribution/> | |
| 1110 | + <copies>1</copies> | |
| 1111 | + <partitioning> | |
| 1112 | + <method>none</method> | |
| 1113 | + <schema_name/> | |
| 1114 | + </partitioning> | |
| 1115 | + <connection>bus_control_variable</connection> | |
| 1116 | + <commit>100</commit> | |
| 1117 | + <update_bypassed>N</update_bypassed> | |
| 1118 | + <lookup> | |
| 1119 | + <schema/> | |
| 1120 | + <table>bsth_c_s_ttinfo_detail</table> | |
| 1121 | + <key> | |
| 1122 | + <name>xlid</name> | |
| 1123 | + <field>xl</field> | |
| 1124 | + <condition>=</condition> | |
| 1125 | + <name2/> | |
| 1126 | + </key> | |
| 1127 | + <key> | |
| 1128 | + <name>ttid</name> | |
| 1129 | + <field>ttinfo</field> | |
| 1130 | + <condition>=</condition> | |
| 1131 | + <name2/> | |
| 1132 | + </key> | |
| 1133 | + <key> | |
| 1134 | + <name>lpid</name> | |
| 1135 | + <field>lp</field> | |
| 1136 | + <condition>=</condition> | |
| 1137 | + <name2/> | |
| 1138 | + </key> | |
| 1139 | + <key> | |
| 1140 | + <name>fcno</name> | |
| 1141 | + <field>fcno</field> | |
| 1142 | + <condition>=</condition> | |
| 1143 | + <name2/> | |
| 1144 | + </key> | |
| 1145 | + <key> | |
| 1146 | + <name>bcs</name> | |
| 1147 | + <field>bcs</field> | |
| 1148 | + <condition>=</condition> | |
| 1149 | + <name2/> | |
| 1150 | + </key> | |
| 1151 | + <value> | |
| 1152 | + <name>fcno</name> | |
| 1153 | + <rename>fcno</rename> | |
| 1154 | + <update>Y</update> | |
| 1155 | + </value> | |
| 1156 | + <value> | |
| 1157 | + <name>bcs</name> | |
| 1158 | + <rename>bcs</rename> | |
| 1159 | + <update>Y</update> | |
| 1160 | + </value> | |
| 1161 | + <value> | |
| 1162 | + <name>xl</name> | |
| 1163 | + <rename>xlid</rename> | |
| 1164 | + <update>Y</update> | |
| 1165 | + </value> | |
| 1166 | + <value> | |
| 1167 | + <name>ttinfo</name> | |
| 1168 | + <rename>ttid</rename> | |
| 1169 | + <update>Y</update> | |
| 1170 | + </value> | |
| 1171 | + <value> | |
| 1172 | + <name>lp</name> | |
| 1173 | + <rename>lpid</rename> | |
| 1174 | + <update>Y</update> | |
| 1175 | + </value> | |
| 1176 | + <value> | |
| 1177 | + <name>bc_type</name> | |
| 1178 | + <rename>bctype_code</rename> | |
| 1179 | + <update>Y</update> | |
| 1180 | + </value> | |
| 1181 | + <value> | |
| 1182 | + <name>bcsj</name> | |
| 1183 | + <rename>parade_time</rename> | |
| 1184 | + <update>Y</update> | |
| 1185 | + </value> | |
| 1186 | + <value> | |
| 1187 | + <name>jhlc</name> | |
| 1188 | + <rename>parade_mileage</rename> | |
| 1189 | + <update>Y</update> | |
| 1190 | + </value> | |
| 1191 | + <value> | |
| 1192 | + <name>fcsj</name> | |
| 1193 | + <rename>sendtime_calcu</rename> | |
| 1194 | + <update>Y</update> | |
| 1195 | + </value> | |
| 1196 | + <value> | |
| 1197 | + <name>xl_dir</name> | |
| 1198 | + <rename>sxx2</rename> | |
| 1199 | + <update>Y</update> | |
| 1200 | + </value> | |
| 1201 | + <value> | |
| 1202 | + <name>qdz</name> | |
| 1203 | + <rename>qdzid</rename> | |
| 1204 | + <update>Y</update> | |
| 1205 | + </value> | |
| 1206 | + <value> | |
| 1207 | + <name>tcc</name> | |
| 1208 | + <rename>zdzid</rename> | |
| 1209 | + <update>Y</update> | |
| 1210 | + </value> | |
| 1211 | + <value> | |
| 1212 | + <name>isfb</name> | |
| 1213 | + <rename>isfb</rename> | |
| 1214 | + <update>Y</update> | |
| 1215 | + </value> | |
| 1216 | + </lookup> | |
| 1217 | + <cluster_schema/> | |
| 1218 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1219 | + <xloc>845</xloc> | |
| 1220 | + <yloc>899</yloc> | |
| 1221 | + <draw>Y</draw> | |
| 1222 | + </GUI> | |
| 1223 | + </step> | |
| 1224 | + | |
| 1225 | + <step> | |
| 1226 | + <name>时刻表明细信息Excel输入</name> | |
| 1227 | + <type>ExcelInput</type> | |
| 1228 | + <description/> | |
| 1229 | + <distribute>N</distribute> | |
| 1230 | + <custom_distribution/> | |
| 1231 | + <copies>1</copies> | |
| 1232 | + <partitioning> | |
| 1233 | + <method>none</method> | |
| 1234 | + <schema_name/> | |
| 1235 | + </partitioning> | |
| 1236 | + <header>Y</header> | |
| 1237 | + <noempty>Y</noempty> | |
| 1238 | + <stoponempty>N</stoponempty> | |
| 1239 | + <filefield/> | |
| 1240 | + <sheetfield/> | |
| 1241 | + <sheetrownumfield/> | |
| 1242 | + <rownumfield/> | |
| 1243 | + <sheetfield/> | |
| 1244 | + <filefield/> | |
| 1245 | + <limit>0</limit> | |
| 1246 | + <encoding/> | |
| 1247 | + <add_to_result_filenames>Y</add_to_result_filenames> | |
| 1248 | + <accept_filenames>N</accept_filenames> | |
| 1249 | + <accept_field/> | |
| 1250 | + <accept_stepname/> | |
| 1251 | + <file> | |
| 1252 | + <name/> | |
| 1253 | + <filemask/> | |
| 1254 | + <exclude_filemask/> | |
| 1255 | + <file_required>N</file_required> | |
| 1256 | + <include_subfolders>N</include_subfolders> | |
| 1257 | + </file> | |
| 1258 | + <fields> | |
| 1259 | + </fields> | |
| 1260 | + <sheets> | |
| 1261 | + <sheet> | |
| 1262 | + <name/> | |
| 1263 | + <startrow>0</startrow> | |
| 1264 | + <startcol>0</startcol> | |
| 1265 | + </sheet> | |
| 1266 | + </sheets> | |
| 1267 | + <strict_types>N</strict_types> | |
| 1268 | + <error_ignored>N</error_ignored> | |
| 1269 | + <error_line_skipped>N</error_line_skipped> | |
| 1270 | + <bad_line_files_destination_directory/> | |
| 1271 | + <bad_line_files_extension>warning</bad_line_files_extension> | |
| 1272 | + <error_line_files_destination_directory/> | |
| 1273 | + <error_line_files_extension>error</error_line_files_extension> | |
| 1274 | + <line_number_files_destination_directory/> | |
| 1275 | + <line_number_files_extension>line</line_number_files_extension> | |
| 1276 | + <shortFileFieldName/> | |
| 1277 | + <pathFieldName/> | |
| 1278 | + <hiddenFieldName/> | |
| 1279 | + <lastModificationTimeFieldName/> | |
| 1280 | + <uriNameFieldName/> | |
| 1281 | + <rootUriNameFieldName/> | |
| 1282 | + <extensionFieldName/> | |
| 1283 | + <sizeFieldName/> | |
| 1284 | + <spreadsheet_type>JXL</spreadsheet_type> | |
| 1285 | + <cluster_schema/> | |
| 1286 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1287 | + <xloc>112</xloc> | |
| 1288 | + <yloc>44</yloc> | |
| 1289 | + <draw>Y</draw> | |
| 1290 | + </GUI> | |
| 1291 | + </step> | |
| 1292 | + | |
| 1293 | + <step> | |
| 1294 | + <name>查找停车场1</name> | |
| 1295 | + <type>DBLookup</type> | |
| 1296 | + <description/> | |
| 1297 | + <distribute>Y</distribute> | |
| 1298 | + <custom_distribution/> | |
| 1299 | + <copies>1</copies> | |
| 1300 | + <partitioning> | |
| 1301 | + <method>none</method> | |
| 1302 | + <schema_name/> | |
| 1303 | + </partitioning> | |
| 1304 | + <connection>bus_control_variable</connection> | |
| 1305 | + <cache>N</cache> | |
| 1306 | + <cache_load_all>N</cache_load_all> | |
| 1307 | + <cache_size>0</cache_size> | |
| 1308 | + <lookup> | |
| 1309 | + <schema/> | |
| 1310 | + <table>bsth_c_car_park</table> | |
| 1311 | + <orderby/> | |
| 1312 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1313 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1314 | + <key> | |
| 1315 | + <name>tccname_</name> | |
| 1316 | + <field>park_name</field> | |
| 1317 | + <condition>=</condition> | |
| 1318 | + <name2/> | |
| 1319 | + </key> | |
| 1320 | + <value> | |
| 1321 | + <name>id</name> | |
| 1322 | + <rename>qdzid</rename> | |
| 1323 | + <default/> | |
| 1324 | + <type>Integer</type> | |
| 1325 | + </value> | |
| 1326 | + </lookup> | |
| 1327 | + <cluster_schema/> | |
| 1328 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1329 | + <xloc>755</xloc> | |
| 1330 | + <yloc>504</yloc> | |
| 1331 | + <draw>Y</draw> | |
| 1332 | + </GUI> | |
| 1333 | + </step> | |
| 1334 | + | |
| 1335 | + <step> | |
| 1336 | + <name>查找停车场2</name> | |
| 1337 | + <type>DBLookup</type> | |
| 1338 | + <description/> | |
| 1339 | + <distribute>Y</distribute> | |
| 1340 | + <custom_distribution/> | |
| 1341 | + <copies>1</copies> | |
| 1342 | + <partitioning> | |
| 1343 | + <method>none</method> | |
| 1344 | + <schema_name/> | |
| 1345 | + </partitioning> | |
| 1346 | + <connection>bus_control_variable</connection> | |
| 1347 | + <cache>N</cache> | |
| 1348 | + <cache_load_all>N</cache_load_all> | |
| 1349 | + <cache_size>0</cache_size> | |
| 1350 | + <lookup> | |
| 1351 | + <schema/> | |
| 1352 | + <table>bsth_c_car_park</table> | |
| 1353 | + <orderby/> | |
| 1354 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1355 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1356 | + <key> | |
| 1357 | + <name>tccname_</name> | |
| 1358 | + <field>park_name</field> | |
| 1359 | + <condition>=</condition> | |
| 1360 | + <name2/> | |
| 1361 | + </key> | |
| 1362 | + <value> | |
| 1363 | + <name>id</name> | |
| 1364 | + <rename>zdzid</rename> | |
| 1365 | + <default/> | |
| 1366 | + <type>Integer</type> | |
| 1367 | + </value> | |
| 1368 | + </lookup> | |
| 1369 | + <cluster_schema/> | |
| 1370 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1371 | + <xloc>887</xloc> | |
| 1372 | + <yloc>608</yloc> | |
| 1373 | + <draw>Y</draw> | |
| 1374 | + </GUI> | |
| 1375 | + </step> | |
| 1376 | + | |
| 1377 | + <step> | |
| 1378 | + <name>查找出场终点站关联并确定上下行</name> | |
| 1379 | + <type>DBLookup</type> | |
| 1380 | + <description/> | |
| 1381 | + <distribute>Y</distribute> | |
| 1382 | + <custom_distribution/> | |
| 1383 | + <copies>1</copies> | |
| 1384 | + <partitioning> | |
| 1385 | + <method>none</method> | |
| 1386 | + <schema_name/> | |
| 1387 | + </partitioning> | |
| 1388 | + <connection>bus_control_variable</connection> | |
| 1389 | + <cache>N</cache> | |
| 1390 | + <cache_load_all>N</cache_load_all> | |
| 1391 | + <cache_size>0</cache_size> | |
| 1392 | + <lookup> | |
| 1393 | + <schema/> | |
| 1394 | + <table>bsth_c_stationroute</table> | |
| 1395 | + <orderby/> | |
| 1396 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1397 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1398 | + <key> | |
| 1399 | + <name>xlid</name> | |
| 1400 | + <field>line</field> | |
| 1401 | + <condition>=</condition> | |
| 1402 | + <name2/> | |
| 1403 | + </key> | |
| 1404 | + <key> | |
| 1405 | + <name>zdzname</name> | |
| 1406 | + <field>station_name</field> | |
| 1407 | + <condition>=</condition> | |
| 1408 | + <name2/> | |
| 1409 | + </key> | |
| 1410 | + <key> | |
| 1411 | + <name>endZdtype</name> | |
| 1412 | + <field>station_mark</field> | |
| 1413 | + <condition>=</condition> | |
| 1414 | + <name2/> | |
| 1415 | + </key> | |
| 1416 | + <key> | |
| 1417 | + <name>destory</name> | |
| 1418 | + <field>destroy</field> | |
| 1419 | + <condition>=</condition> | |
| 1420 | + <name2/> | |
| 1421 | + </key> | |
| 1422 | + <value> | |
| 1423 | + <name>station</name> | |
| 1424 | + <rename>zdzid</rename> | |
| 1425 | + <default/> | |
| 1426 | + <type>Integer</type> | |
| 1427 | + </value> | |
| 1428 | + <value> | |
| 1429 | + <name>directions</name> | |
| 1430 | + <rename>sxx</rename> | |
| 1431 | + <default/> | |
| 1432 | + <type>Integer</type> | |
| 1433 | + </value> | |
| 1434 | + </lookup> | |
| 1435 | + <cluster_schema/> | |
| 1436 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1437 | + <xloc>329</xloc> | |
| 1438 | + <yloc>505</yloc> | |
| 1439 | + <draw>Y</draw> | |
| 1440 | + </GUI> | |
| 1441 | + </step> | |
| 1442 | + | |
| 1443 | + <step> | |
| 1444 | + <name>查找时刻表基础信息关联</name> | |
| 1445 | + <type>DBLookup</type> | |
| 1446 | + <description/> | |
| 1447 | + <distribute>Y</distribute> | |
| 1448 | + <custom_distribution/> | |
| 1449 | + <copies>1</copies> | |
| 1450 | + <partitioning> | |
| 1451 | + <method>none</method> | |
| 1452 | + <schema_name/> | |
| 1453 | + </partitioning> | |
| 1454 | + <connection>bus_control_variable</connection> | |
| 1455 | + <cache>N</cache> | |
| 1456 | + <cache_load_all>N</cache_load_all> | |
| 1457 | + <cache_size>0</cache_size> | |
| 1458 | + <lookup> | |
| 1459 | + <schema/> | |
| 1460 | + <table>bsth_c_s_ttinfo</table> | |
| 1461 | + <orderby/> | |
| 1462 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1463 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1464 | + <key> | |
| 1465 | + <name>xlid</name> | |
| 1466 | + <field>xl</field> | |
| 1467 | + <condition>=</condition> | |
| 1468 | + <name2/> | |
| 1469 | + </key> | |
| 1470 | + <key> | |
| 1471 | + <name>ttinfoname_</name> | |
| 1472 | + <field>name</field> | |
| 1473 | + <condition>=</condition> | |
| 1474 | + <name2/> | |
| 1475 | + </key> | |
| 1476 | + <key> | |
| 1477 | + <name>iscanceled</name> | |
| 1478 | + <field>is_cancel</field> | |
| 1479 | + <condition>=</condition> | |
| 1480 | + <name2/> | |
| 1481 | + </key> | |
| 1482 | + <value> | |
| 1483 | + <name>id</name> | |
| 1484 | + <rename>ttid</rename> | |
| 1485 | + <default/> | |
| 1486 | + <type>Integer</type> | |
| 1487 | + </value> | |
| 1488 | + </lookup> | |
| 1489 | + <cluster_schema/> | |
| 1490 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1491 | + <xloc>1011</xloc> | |
| 1492 | + <yloc>134</yloc> | |
| 1493 | + <draw>Y</draw> | |
| 1494 | + </GUI> | |
| 1495 | + </step> | |
| 1496 | + | |
| 1497 | + <step> | |
| 1498 | + <name>查找线路上下行里程时间</name> | |
| 1499 | + <type>DBLookup</type> | |
| 1500 | + <description/> | |
| 1501 | + <distribute>Y</distribute> | |
| 1502 | + <custom_distribution/> | |
| 1503 | + <copies>1</copies> | |
| 1504 | + <partitioning> | |
| 1505 | + <method>none</method> | |
| 1506 | + <schema_name/> | |
| 1507 | + </partitioning> | |
| 1508 | + <connection>bus_control_variable</connection> | |
| 1509 | + <cache>N</cache> | |
| 1510 | + <cache_load_all>N</cache_load_all> | |
| 1511 | + <cache_size>0</cache_size> | |
| 1512 | + <lookup> | |
| 1513 | + <schema/> | |
| 1514 | + <table>bsth_c_line_information</table> | |
| 1515 | + <orderby/> | |
| 1516 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1517 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1518 | + <key> | |
| 1519 | + <name>xlid</name> | |
| 1520 | + <field>line</field> | |
| 1521 | + <condition>=</condition> | |
| 1522 | + <name2/> | |
| 1523 | + </key> | |
| 1524 | + <value> | |
| 1525 | + <name>up_mileage</name> | |
| 1526 | + <rename>up_mileage</rename> | |
| 1527 | + <default/> | |
| 1528 | + <type>Number</type> | |
| 1529 | + </value> | |
| 1530 | + <value> | |
| 1531 | + <name>down_mileage</name> | |
| 1532 | + <rename>down_mileage</rename> | |
| 1533 | + <default/> | |
| 1534 | + <type>Number</type> | |
| 1535 | + </value> | |
| 1536 | + <value> | |
| 1537 | + <name>up_travel_time</name> | |
| 1538 | + <rename>up_travel_time</rename> | |
| 1539 | + <default/> | |
| 1540 | + <type>Number</type> | |
| 1541 | + </value> | |
| 1542 | + <value> | |
| 1543 | + <name>down_travel_time</name> | |
| 1544 | + <rename>down_travel_time</rename> | |
| 1545 | + <default/> | |
| 1546 | + <type>Number</type> | |
| 1547 | + </value> | |
| 1548 | + </lookup> | |
| 1549 | + <cluster_schema/> | |
| 1550 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1551 | + <xloc>149</xloc> | |
| 1552 | + <yloc>581</yloc> | |
| 1553 | + <draw>Y</draw> | |
| 1554 | + </GUI> | |
| 1555 | + </step> | |
| 1556 | + | |
| 1557 | + <step> | |
| 1558 | + <name>查找线路关联</name> | |
| 1559 | + <type>DBLookup</type> | |
| 1560 | + <description/> | |
| 1561 | + <distribute>Y</distribute> | |
| 1562 | + <custom_distribution/> | |
| 1563 | + <copies>1</copies> | |
| 1564 | + <partitioning> | |
| 1565 | + <method>none</method> | |
| 1566 | + <schema_name/> | |
| 1567 | + </partitioning> | |
| 1568 | + <connection>bus_control_variable</connection> | |
| 1569 | + <cache>N</cache> | |
| 1570 | + <cache_load_all>N</cache_load_all> | |
| 1571 | + <cache_size>0</cache_size> | |
| 1572 | + <lookup> | |
| 1573 | + <schema/> | |
| 1574 | + <table>bsth_c_line</table> | |
| 1575 | + <orderby/> | |
| 1576 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1577 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1578 | + <key> | |
| 1579 | + <name>xlname_</name> | |
| 1580 | + <field>name</field> | |
| 1581 | + <condition>=</condition> | |
| 1582 | + <name2/> | |
| 1583 | + </key> | |
| 1584 | + <value> | |
| 1585 | + <name>id</name> | |
| 1586 | + <rename>xlid</rename> | |
| 1587 | + <default/> | |
| 1588 | + <type>Integer</type> | |
| 1589 | + </value> | |
| 1590 | + </lookup> | |
| 1591 | + <cluster_schema/> | |
| 1592 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1593 | + <xloc>1007</xloc> | |
| 1594 | + <yloc>43</yloc> | |
| 1595 | + <draw>Y</draw> | |
| 1596 | + </GUI> | |
| 1597 | + </step> | |
| 1598 | + | |
| 1599 | + <step> | |
| 1600 | + <name>查找线路出场里程时间</name> | |
| 1601 | + <type>DBLookup</type> | |
| 1602 | + <description/> | |
| 1603 | + <distribute>Y</distribute> | |
| 1604 | + <custom_distribution/> | |
| 1605 | + <copies>1</copies> | |
| 1606 | + <partitioning> | |
| 1607 | + <method>none</method> | |
| 1608 | + <schema_name/> | |
| 1609 | + </partitioning> | |
| 1610 | + <connection>bus_control_variable</connection> | |
| 1611 | + <cache>N</cache> | |
| 1612 | + <cache_load_all>N</cache_load_all> | |
| 1613 | + <cache_size>0</cache_size> | |
| 1614 | + <lookup> | |
| 1615 | + <schema/> | |
| 1616 | + <table>bsth_c_line_information</table> | |
| 1617 | + <orderby/> | |
| 1618 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1619 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1620 | + <key> | |
| 1621 | + <name>xlid</name> | |
| 1622 | + <field>line</field> | |
| 1623 | + <condition>=</condition> | |
| 1624 | + <name2/> | |
| 1625 | + </key> | |
| 1626 | + <value> | |
| 1627 | + <name>up_out_timer</name> | |
| 1628 | + <rename>up_out_timer</rename> | |
| 1629 | + <default/> | |
| 1630 | + <type>Number</type> | |
| 1631 | + </value> | |
| 1632 | + <value> | |
| 1633 | + <name>up_out_mileage</name> | |
| 1634 | + <rename>up_out_mileage</rename> | |
| 1635 | + <default/> | |
| 1636 | + <type>Number</type> | |
| 1637 | + </value> | |
| 1638 | + <value> | |
| 1639 | + <name>down_out_timer</name> | |
| 1640 | + <rename>down_out_timer</rename> | |
| 1641 | + <default/> | |
| 1642 | + <type>Number</type> | |
| 1643 | + </value> | |
| 1644 | + <value> | |
| 1645 | + <name>down_out_mileage</name> | |
| 1646 | + <rename>down_out_mileage</rename> | |
| 1647 | + <default/> | |
| 1648 | + <type>Number</type> | |
| 1649 | + </value> | |
| 1650 | + </lookup> | |
| 1651 | + <cluster_schema/> | |
| 1652 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1653 | + <xloc>335</xloc> | |
| 1654 | + <yloc>763</yloc> | |
| 1655 | + <draw>Y</draw> | |
| 1656 | + </GUI> | |
| 1657 | + </step> | |
| 1658 | + | |
| 1659 | + <step> | |
| 1660 | + <name>查找线路进场里程时间</name> | |
| 1661 | + <type>DBLookup</type> | |
| 1662 | + <description/> | |
| 1663 | + <distribute>Y</distribute> | |
| 1664 | + <custom_distribution/> | |
| 1665 | + <copies>1</copies> | |
| 1666 | + <partitioning> | |
| 1667 | + <method>none</method> | |
| 1668 | + <schema_name/> | |
| 1669 | + </partitioning> | |
| 1670 | + <connection>bus_control_variable</connection> | |
| 1671 | + <cache>N</cache> | |
| 1672 | + <cache_load_all>N</cache_load_all> | |
| 1673 | + <cache_size>0</cache_size> | |
| 1674 | + <lookup> | |
| 1675 | + <schema/> | |
| 1676 | + <table>bsth_c_line_information</table> | |
| 1677 | + <orderby/> | |
| 1678 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1679 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1680 | + <key> | |
| 1681 | + <name>xlid</name> | |
| 1682 | + <field>line</field> | |
| 1683 | + <condition>=</condition> | |
| 1684 | + <name2/> | |
| 1685 | + </key> | |
| 1686 | + <value> | |
| 1687 | + <name>up_in_mileage</name> | |
| 1688 | + <rename>up_in_mileage</rename> | |
| 1689 | + <default/> | |
| 1690 | + <type>Number</type> | |
| 1691 | + </value> | |
| 1692 | + <value> | |
| 1693 | + <name>up_in_timer</name> | |
| 1694 | + <rename>up_in_timer</rename> | |
| 1695 | + <default/> | |
| 1696 | + <type>Number</type> | |
| 1697 | + </value> | |
| 1698 | + <value> | |
| 1699 | + <name>down_in_mileage</name> | |
| 1700 | + <rename>down_in_mileage</rename> | |
| 1701 | + <default/> | |
| 1702 | + <type>Number</type> | |
| 1703 | + </value> | |
| 1704 | + <value> | |
| 1705 | + <name>down_in_timer</name> | |
| 1706 | + <rename>down_in_timer</rename> | |
| 1707 | + <default/> | |
| 1708 | + <type>Number</type> | |
| 1709 | + </value> | |
| 1710 | + </lookup> | |
| 1711 | + <cluster_schema/> | |
| 1712 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1713 | + <xloc>553</xloc> | |
| 1714 | + <yloc>1004</yloc> | |
| 1715 | + <draw>Y</draw> | |
| 1716 | + </GUI> | |
| 1717 | + </step> | |
| 1718 | + | |
| 1719 | + <step> | |
| 1720 | + <name>查找终点站关联</name> | |
| 1721 | + <type>DBLookup</type> | |
| 1722 | + <description/> | |
| 1723 | + <distribute>Y</distribute> | |
| 1724 | + <custom_distribution/> | |
| 1725 | + <copies>1</copies> | |
| 1726 | + <partitioning> | |
| 1727 | + <method>none</method> | |
| 1728 | + <schema_name/> | |
| 1729 | + </partitioning> | |
| 1730 | + <connection>bus_control_variable</connection> | |
| 1731 | + <cache>N</cache> | |
| 1732 | + <cache_load_all>N</cache_load_all> | |
| 1733 | + <cache_size>0</cache_size> | |
| 1734 | + <lookup> | |
| 1735 | + <schema/> | |
| 1736 | + <table>bsth_c_stationroute</table> | |
| 1737 | + <orderby/> | |
| 1738 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1739 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1740 | + <key> | |
| 1741 | + <name>xlid</name> | |
| 1742 | + <field>line</field> | |
| 1743 | + <condition>=</condition> | |
| 1744 | + <name2/> | |
| 1745 | + </key> | |
| 1746 | + <key> | |
| 1747 | + <name>sxx</name> | |
| 1748 | + <field>directions</field> | |
| 1749 | + <condition>=</condition> | |
| 1750 | + <name2/> | |
| 1751 | + </key> | |
| 1752 | + <key> | |
| 1753 | + <name>endZdtype</name> | |
| 1754 | + <field>station_mark</field> | |
| 1755 | + <condition>=</condition> | |
| 1756 | + <name2/> | |
| 1757 | + </key> | |
| 1758 | + <key> | |
| 1759 | + <name>destory</name> | |
| 1760 | + <field>destroy</field> | |
| 1761 | + <condition>=</condition> | |
| 1762 | + <name2/> | |
| 1763 | + </key> | |
| 1764 | + <value> | |
| 1765 | + <name>station_name</name> | |
| 1766 | + <rename>zdzname</rename> | |
| 1767 | + <default/> | |
| 1768 | + <type>String</type> | |
| 1769 | + </value> | |
| 1770 | + <value> | |
| 1771 | + <name>station</name> | |
| 1772 | + <rename>zdzid</rename> | |
| 1773 | + <default/> | |
| 1774 | + <type>Integer</type> | |
| 1775 | + </value> | |
| 1776 | + </lookup> | |
| 1777 | + <cluster_schema/> | |
| 1778 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1779 | + <xloc>280</xloc> | |
| 1780 | + <yloc>404</yloc> | |
| 1781 | + <draw>Y</draw> | |
| 1782 | + </GUI> | |
| 1783 | + </step> | |
| 1784 | + | |
| 1785 | + <step> | |
| 1786 | + <name>查找起点站关联并确定上下行</name> | |
| 1787 | + <type>DBLookup</type> | |
| 1788 | + <description/> | |
| 1789 | + <distribute>Y</distribute> | |
| 1790 | + <custom_distribution/> | |
| 1791 | + <copies>1</copies> | |
| 1792 | + <partitioning> | |
| 1793 | + <method>none</method> | |
| 1794 | + <schema_name/> | |
| 1795 | + </partitioning> | |
| 1796 | + <connection>bus_control_variable</connection> | |
| 1797 | + <cache>N</cache> | |
| 1798 | + <cache_load_all>N</cache_load_all> | |
| 1799 | + <cache_size>0</cache_size> | |
| 1800 | + <lookup> | |
| 1801 | + <schema/> | |
| 1802 | + <table>bsth_c_stationroute</table> | |
| 1803 | + <orderby/> | |
| 1804 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1805 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1806 | + <key> | |
| 1807 | + <name>xlid</name> | |
| 1808 | + <field>line</field> | |
| 1809 | + <condition>=</condition> | |
| 1810 | + <name2/> | |
| 1811 | + </key> | |
| 1812 | + <key> | |
| 1813 | + <name>qdzname</name> | |
| 1814 | + <field>station_name</field> | |
| 1815 | + <condition>=</condition> | |
| 1816 | + <name2/> | |
| 1817 | + </key> | |
| 1818 | + <key> | |
| 1819 | + <name>sendZdtype</name> | |
| 1820 | + <field>station_mark</field> | |
| 1821 | + <condition>=</condition> | |
| 1822 | + <name2/> | |
| 1823 | + </key> | |
| 1824 | + <key> | |
| 1825 | + <name>destory</name> | |
| 1826 | + <field>destroy</field> | |
| 1827 | + <condition>=</condition> | |
| 1828 | + <name2/> | |
| 1829 | + </key> | |
| 1830 | + <value> | |
| 1831 | + <name>station</name> | |
| 1832 | + <rename>qdzid</rename> | |
| 1833 | + <default/> | |
| 1834 | + <type>Integer</type> | |
| 1835 | + </value> | |
| 1836 | + <value> | |
| 1837 | + <name>directions</name> | |
| 1838 | + <rename>sxx</rename> | |
| 1839 | + <default/> | |
| 1840 | + <type>Integer</type> | |
| 1841 | + </value> | |
| 1842 | + </lookup> | |
| 1843 | + <cluster_schema/> | |
| 1844 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1845 | + <xloc>430</xloc> | |
| 1846 | + <yloc>403</yloc> | |
| 1847 | + <draw>Y</draw> | |
| 1848 | + </GUI> | |
| 1849 | + </step> | |
| 1850 | + | |
| 1851 | + <step> | |
| 1852 | + <name>查找路牌关联</name> | |
| 1853 | + <type>DBLookup</type> | |
| 1854 | + <description/> | |
| 1855 | + <distribute>Y</distribute> | |
| 1856 | + <custom_distribution/> | |
| 1857 | + <copies>1</copies> | |
| 1858 | + <partitioning> | |
| 1859 | + <method>none</method> | |
| 1860 | + <schema_name/> | |
| 1861 | + </partitioning> | |
| 1862 | + <connection>bus_control_variable</connection> | |
| 1863 | + <cache>N</cache> | |
| 1864 | + <cache_load_all>N</cache_load_all> | |
| 1865 | + <cache_size>0</cache_size> | |
| 1866 | + <lookup> | |
| 1867 | + <schema/> | |
| 1868 | + <table>bsth_c_s_gbi</table> | |
| 1869 | + <orderby/> | |
| 1870 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1871 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1872 | + <key> | |
| 1873 | + <name>xlid</name> | |
| 1874 | + <field>xl</field> | |
| 1875 | + <condition>=</condition> | |
| 1876 | + <name2/> | |
| 1877 | + </key> | |
| 1878 | + <key> | |
| 1879 | + <name>lp</name> | |
| 1880 | + <field>lp_name</field> | |
| 1881 | + <condition>=</condition> | |
| 1882 | + <name2/> | |
| 1883 | + </key> | |
| 1884 | + <key> | |
| 1885 | + <name>iscanceled</name> | |
| 1886 | + <field>is_cancel</field> | |
| 1887 | + <condition>=</condition> | |
| 1888 | + <name2/> | |
| 1889 | + </key> | |
| 1890 | + <value> | |
| 1891 | + <name>id</name> | |
| 1892 | + <rename>lpid</rename> | |
| 1893 | + <default/> | |
| 1894 | + <type>Integer</type> | |
| 1895 | + </value> | |
| 1896 | + </lookup> | |
| 1897 | + <cluster_schema/> | |
| 1898 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1899 | + <xloc>1013</xloc> | |
| 1900 | + <yloc>265</yloc> | |
| 1901 | + <draw>Y</draw> | |
| 1902 | + </GUI> | |
| 1903 | + </step> | |
| 1904 | + | |
| 1905 | + <step> | |
| 1906 | + <name>查找进场班次上一个班次的线路方向</name> | |
| 1907 | + <type>DBLookup</type> | |
| 1908 | + <description/> | |
| 1909 | + <distribute>Y</distribute> | |
| 1910 | + <custom_distribution/> | |
| 1911 | + <copies>1</copies> | |
| 1912 | + <partitioning> | |
| 1913 | + <method>none</method> | |
| 1914 | + <schema_name/> | |
| 1915 | + </partitioning> | |
| 1916 | + <connection>bus_control_variable</connection> | |
| 1917 | + <cache>N</cache> | |
| 1918 | + <cache_load_all>N</cache_load_all> | |
| 1919 | + <cache_size>0</cache_size> | |
| 1920 | + <lookup> | |
| 1921 | + <schema/> | |
| 1922 | + <table>bsth_c_stationroute</table> | |
| 1923 | + <orderby/> | |
| 1924 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1925 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1926 | + <key> | |
| 1927 | + <name>xlid</name> | |
| 1928 | + <field>line</field> | |
| 1929 | + <condition>=</condition> | |
| 1930 | + <name2/> | |
| 1931 | + </key> | |
| 1932 | + <key> | |
| 1933 | + <name>startZdtype_calcu</name> | |
| 1934 | + <field>station_mark</field> | |
| 1935 | + <condition>=</condition> | |
| 1936 | + <name2/> | |
| 1937 | + </key> | |
| 1938 | + <key> | |
| 1939 | + <name>qdzname_calcu</name> | |
| 1940 | + <field>station_name</field> | |
| 1941 | + <condition>=</condition> | |
| 1942 | + <name2/> | |
| 1943 | + </key> | |
| 1944 | + <key> | |
| 1945 | + <name>destory</name> | |
| 1946 | + <field>destroy</field> | |
| 1947 | + <condition>=</condition> | |
| 1948 | + <name2/> | |
| 1949 | + </key> | |
| 1950 | + <value> | |
| 1951 | + <name>directions</name> | |
| 1952 | + <rename>sxx</rename> | |
| 1953 | + <default/> | |
| 1954 | + <type>String</type> | |
| 1955 | + </value> | |
| 1956 | + </lookup> | |
| 1957 | + <cluster_schema/> | |
| 1958 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 1959 | + <xloc>548</xloc> | |
| 1960 | + <yloc>610</yloc> | |
| 1961 | + <draw>Y</draw> | |
| 1962 | + </GUI> | |
| 1963 | + </step> | |
| 1964 | + | |
| 1965 | + <step> | |
| 1966 | + <name>查找进场班次上一个班次的终点站,并作为进场班次的起点站</name> | |
| 1967 | + <type>DBLookup</type> | |
| 1968 | + <description/> | |
| 1969 | + <distribute>Y</distribute> | |
| 1970 | + <custom_distribution/> | |
| 1971 | + <copies>1</copies> | |
| 1972 | + <partitioning> | |
| 1973 | + <method>none</method> | |
| 1974 | + <schema_name/> | |
| 1975 | + </partitioning> | |
| 1976 | + <connection>bus_control_variable</connection> | |
| 1977 | + <cache>Y</cache> | |
| 1978 | + <cache_load_all>Y</cache_load_all> | |
| 1979 | + <cache_size>0</cache_size> | |
| 1980 | + <lookup> | |
| 1981 | + <schema/> | |
| 1982 | + <table>bsth_c_stationroute</table> | |
| 1983 | + <orderby/> | |
| 1984 | + <fail_on_multiple>N</fail_on_multiple> | |
| 1985 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 1986 | + <key> | |
| 1987 | + <name>xlid</name> | |
| 1988 | + <field>line</field> | |
| 1989 | + <condition>=</condition> | |
| 1990 | + <name2/> | |
| 1991 | + </key> | |
| 1992 | + <key> | |
| 1993 | + <name>endZdtype_calcu</name> | |
| 1994 | + <field>station_mark</field> | |
| 1995 | + <condition>=</condition> | |
| 1996 | + <name2/> | |
| 1997 | + </key> | |
| 1998 | + <key> | |
| 1999 | + <name>sxx</name> | |
| 2000 | + <field>directions</field> | |
| 2001 | + <condition>=</condition> | |
| 2002 | + <name2/> | |
| 2003 | + </key> | |
| 2004 | + <key> | |
| 2005 | + <name>destory</name> | |
| 2006 | + <field>destroy</field> | |
| 2007 | + <condition>=</condition> | |
| 2008 | + <name2/> | |
| 2009 | + </key> | |
| 2010 | + <value> | |
| 2011 | + <name>station_name</name> | |
| 2012 | + <rename>zdzname_calcu</rename> | |
| 2013 | + <default/> | |
| 2014 | + <type>Integer</type> | |
| 2015 | + </value> | |
| 2016 | + </lookup> | |
| 2017 | + <cluster_schema/> | |
| 2018 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2019 | + <xloc>550</xloc> | |
| 2020 | + <yloc>701</yloc> | |
| 2021 | + <draw>Y</draw> | |
| 2022 | + </GUI> | |
| 2023 | + </step> | |
| 2024 | + | |
| 2025 | + <step> | |
| 2026 | + <name>查找进场起点站关联确定上下行</name> | |
| 2027 | + <type>DBLookup</type> | |
| 2028 | + <description/> | |
| 2029 | + <distribute>Y</distribute> | |
| 2030 | + <custom_distribution/> | |
| 2031 | + <copies>1</copies> | |
| 2032 | + <partitioning> | |
| 2033 | + <method>none</method> | |
| 2034 | + <schema_name/> | |
| 2035 | + </partitioning> | |
| 2036 | + <connection>bus_control_variable</connection> | |
| 2037 | + <cache>N</cache> | |
| 2038 | + <cache_load_all>N</cache_load_all> | |
| 2039 | + <cache_size>0</cache_size> | |
| 2040 | + <lookup> | |
| 2041 | + <schema/> | |
| 2042 | + <table>bsth_c_stationroute</table> | |
| 2043 | + <orderby/> | |
| 2044 | + <fail_on_multiple>N</fail_on_multiple> | |
| 2045 | + <eat_row_on_failure>N</eat_row_on_failure> | |
| 2046 | + <key> | |
| 2047 | + <name>xlid</name> | |
| 2048 | + <field>line</field> | |
| 2049 | + <condition>=</condition> | |
| 2050 | + <name2/> | |
| 2051 | + </key> | |
| 2052 | + <key> | |
| 2053 | + <name>zdzname_calcu</name> | |
| 2054 | + <field>station_name</field> | |
| 2055 | + <condition>=</condition> | |
| 2056 | + <name2/> | |
| 2057 | + </key> | |
| 2058 | + <key> | |
| 2059 | + <name>startZdtype_calcu</name> | |
| 2060 | + <field>station_mark</field> | |
| 2061 | + <condition>=</condition> | |
| 2062 | + <name2/> | |
| 2063 | + </key> | |
| 2064 | + <key> | |
| 2065 | + <name>destory</name> | |
| 2066 | + <field>destroy</field> | |
| 2067 | + <condition>=</condition> | |
| 2068 | + <name2/> | |
| 2069 | + </key> | |
| 2070 | + <value> | |
| 2071 | + <name>directions</name> | |
| 2072 | + <rename>sxx2</rename> | |
| 2073 | + <default/> | |
| 2074 | + <type>Integer</type> | |
| 2075 | + </value> | |
| 2076 | + <value> | |
| 2077 | + <name>station</name> | |
| 2078 | + <rename>qdzid</rename> | |
| 2079 | + <default/> | |
| 2080 | + <type>Integer</type> | |
| 2081 | + </value> | |
| 2082 | + </lookup> | |
| 2083 | + <cluster_schema/> | |
| 2084 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2085 | + <xloc>551</xloc> | |
| 2086 | + <yloc>782</yloc> | |
| 2087 | + <draw>Y</draw> | |
| 2088 | + </GUI> | |
| 2089 | + </step> | |
| 2090 | + | |
| 2091 | + <step> | |
| 2092 | + <name>正常班次_处理数据</name> | |
| 2093 | + <type>ScriptValueMod</type> | |
| 2094 | + <description/> | |
| 2095 | + <distribute>Y</distribute> | |
| 2096 | + <custom_distribution/> | |
| 2097 | + <copies>1</copies> | |
| 2098 | + <partitioning> | |
| 2099 | + <method>none</method> | |
| 2100 | + <schema_name/> | |
| 2101 | + </partitioning> | |
| 2102 | + <compatible>N</compatible> | |
| 2103 | + <optimizationLevel>9</optimizationLevel> | |
| 2104 | + <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 2105 | + <jsScript_name>Script 1</jsScript_name> | |
| 2106 | + <jsScript_script>//Script here

// 添加站点标识
var sendZdtype = 'B';
var endZdtype = 'E';

var destory = 0; // 未撤销flag</jsScript_script> | |
| 2107 | + </jsScript> </jsScripts> <fields> <field> <name>sendZdtype</name> | |
| 2108 | + <rename>sendZdtype</rename> | |
| 2109 | + <type>String</type> | |
| 2110 | + <length>-1</length> | |
| 2111 | + <precision>-1</precision> | |
| 2112 | + <replace>N</replace> | |
| 2113 | + </field> <field> <name>endZdtype</name> | |
| 2114 | + <rename>endZdtype</rename> | |
| 2115 | + <type>String</type> | |
| 2116 | + <length>-1</length> | |
| 2117 | + <precision>-1</precision> | |
| 2118 | + <replace>N</replace> | |
| 2119 | + </field> <field> <name>destory</name> | |
| 2120 | + <rename>destory</rename> | |
| 2121 | + <type>Integer</type> | |
| 2122 | + <length>-1</length> | |
| 2123 | + <precision>-1</precision> | |
| 2124 | + <replace>N</replace> | |
| 2125 | + </field> </fields> <cluster_schema/> | |
| 2126 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2127 | + <xloc>588</xloc> | |
| 2128 | + <yloc>403</yloc> | |
| 2129 | + <draw>Y</draw> | |
| 2130 | + </GUI> | |
| 2131 | + </step> | |
| 2132 | + | |
| 2133 | + <step> | |
| 2134 | + <name>正常班次数据</name> | |
| 2135 | + <type>Dummy</type> | |
| 2136 | + <description/> | |
| 2137 | + <distribute>Y</distribute> | |
| 2138 | + <custom_distribution/> | |
| 2139 | + <copies>1</copies> | |
| 2140 | + <partitioning> | |
| 2141 | + <method>none</method> | |
| 2142 | + <schema_name/> | |
| 2143 | + </partitioning> | |
| 2144 | + <cluster_schema/> | |
| 2145 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2146 | + <xloc>725</xloc> | |
| 2147 | + <yloc>404</yloc> | |
| 2148 | + <draw>Y</draw> | |
| 2149 | + </GUI> | |
| 2150 | + </step> | |
| 2151 | + | |
| 2152 | + <step> | |
| 2153 | + <name>添加发车顺序号</name> | |
| 2154 | + <type>GroupBy</type> | |
| 2155 | + <description/> | |
| 2156 | + <distribute>Y</distribute> | |
| 2157 | + <custom_distribution/> | |
| 2158 | + <copies>1</copies> | |
| 2159 | + <partitioning> | |
| 2160 | + <method>none</method> | |
| 2161 | + <schema_name/> | |
| 2162 | + </partitioning> | |
| 2163 | + <all_rows>Y</all_rows> | |
| 2164 | + <ignore_aggregate>N</ignore_aggregate> | |
| 2165 | + <field_ignore/> | |
| 2166 | + <directory>%%java.io.tmpdir%%</directory> | |
| 2167 | + <prefix>grp</prefix> | |
| 2168 | + <add_linenr>Y</add_linenr> | |
| 2169 | + <linenr_fieldname>fcno</linenr_fieldname> | |
| 2170 | + <give_back_row>N</give_back_row> | |
| 2171 | + <group> | |
| 2172 | + <field> | |
| 2173 | + <name>lp</name> | |
| 2174 | + </field> | |
| 2175 | + </group> | |
| 2176 | + <fields> | |
| 2177 | + </fields> | |
| 2178 | + <cluster_schema/> | |
| 2179 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2180 | + <xloc>442</xloc> | |
| 2181 | + <yloc>44</yloc> | |
| 2182 | + <draw>Y</draw> | |
| 2183 | + </GUI> | |
| 2184 | + </step> | |
| 2185 | + | |
| 2186 | + <step> | |
| 2187 | + <name>添加对应班次数</name> | |
| 2188 | + <type>GroupBy</type> | |
| 2189 | + <description/> | |
| 2190 | + <distribute>Y</distribute> | |
| 2191 | + <custom_distribution/> | |
| 2192 | + <copies>1</copies> | |
| 2193 | + <partitioning> | |
| 2194 | + <method>none</method> | |
| 2195 | + <schema_name/> | |
| 2196 | + </partitioning> | |
| 2197 | + <all_rows>Y</all_rows> | |
| 2198 | + <ignore_aggregate>N</ignore_aggregate> | |
| 2199 | + <field_ignore/> | |
| 2200 | + <directory>%%java.io.tmpdir%%</directory> | |
| 2201 | + <prefix>grp</prefix> | |
| 2202 | + <add_linenr>Y</add_linenr> | |
| 2203 | + <linenr_fieldname>bcs</linenr_fieldname> | |
| 2204 | + <give_back_row>N</give_back_row> | |
| 2205 | + <group> | |
| 2206 | + </group> | |
| 2207 | + <fields> | |
| 2208 | + </fields> | |
| 2209 | + <cluster_schema/> | |
| 2210 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2211 | + <xloc>692</xloc> | |
| 2212 | + <yloc>44</yloc> | |
| 2213 | + <draw>Y</draw> | |
| 2214 | + </GUI> | |
| 2215 | + </step> | |
| 2216 | + | |
| 2217 | + <step> | |
| 2218 | + <name>班次数据范式化</name> | |
| 2219 | + <type>Normaliser</type> | |
| 2220 | + <description/> | |
| 2221 | + <distribute>Y</distribute> | |
| 2222 | + <custom_distribution/> | |
| 2223 | + <copies>1</copies> | |
| 2224 | + <partitioning> | |
| 2225 | + <method>none</method> | |
| 2226 | + <schema_name/> | |
| 2227 | + </partitioning> | |
| 2228 | + <typefield>站点名称</typefield> | |
| 2229 | + <fields> </fields> <cluster_schema/> | |
| 2230 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2231 | + <xloc>248</xloc> | |
| 2232 | + <yloc>44</yloc> | |
| 2233 | + <draw>Y</draw> | |
| 2234 | + </GUI> | |
| 2235 | + </step> | |
| 2236 | + | |
| 2237 | + <step> | |
| 2238 | + <name>班次类型字典</name> | |
| 2239 | + <type>ValueMapper</type> | |
| 2240 | + <description/> | |
| 2241 | + <distribute>Y</distribute> | |
| 2242 | + <custom_distribution/> | |
| 2243 | + <copies>1</copies> | |
| 2244 | + <partitioning> | |
| 2245 | + <method>none</method> | |
| 2246 | + <schema_name/> | |
| 2247 | + </partitioning> | |
| 2248 | + <field_to_use>bctype</field_to_use> | |
| 2249 | + <target_field>bctype_code</target_field> | |
| 2250 | + <non_match_default>未知类型</non_match_default> | |
| 2251 | + <fields> | |
| 2252 | + <field> | |
| 2253 | + <source_value>正常班次</source_value> | |
| 2254 | + <target_value>normal</target_value> | |
| 2255 | + </field> | |
| 2256 | + <field> | |
| 2257 | + <source_value>出场</source_value> | |
| 2258 | + <target_value>out</target_value> | |
| 2259 | + </field> | |
| 2260 | + <field> | |
| 2261 | + <source_value>进场</source_value> | |
| 2262 | + <target_value>in</target_value> | |
| 2263 | + </field> | |
| 2264 | + <field> | |
| 2265 | + <source_value>加油</source_value> | |
| 2266 | + <target_value>oil</target_value> | |
| 2267 | + </field> | |
| 2268 | + <field> | |
| 2269 | + <source_value>临加</source_value> | |
| 2270 | + <target_value>temp</target_value> | |
| 2271 | + </field> | |
| 2272 | + <field> | |
| 2273 | + <source_value>区间</source_value> | |
| 2274 | + <target_value>region</target_value> | |
| 2275 | + </field> | |
| 2276 | + <field> | |
| 2277 | + <source_value>放空</source_value> | |
| 2278 | + <target_value>venting</target_value> | |
| 2279 | + </field> | |
| 2280 | + <field> | |
| 2281 | + <source_value>放大站</source_value> | |
| 2282 | + <target_value>major</target_value> | |
| 2283 | + </field> | |
| 2284 | + </fields> | |
| 2285 | + <cluster_schema/> | |
| 2286 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2287 | + <xloc>149</xloc> | |
| 2288 | + <yloc>491</yloc> | |
| 2289 | + <draw>Y</draw> | |
| 2290 | + </GUI> | |
| 2291 | + </step> | |
| 2292 | + | |
| 2293 | + <step> | |
| 2294 | + <name>班次类型字典 2</name> | |
| 2295 | + <type>ValueMapper</type> | |
| 2296 | + <description/> | |
| 2297 | + <distribute>Y</distribute> | |
| 2298 | + <custom_distribution/> | |
| 2299 | + <copies>1</copies> | |
| 2300 | + <partitioning> | |
| 2301 | + <method>none</method> | |
| 2302 | + <schema_name/> | |
| 2303 | + </partitioning> | |
| 2304 | + <field_to_use>bctype</field_to_use> | |
| 2305 | + <target_field>bctype_code</target_field> | |
| 2306 | + <non_match_default>未知类型</non_match_default> | |
| 2307 | + <fields> | |
| 2308 | + <field> | |
| 2309 | + <source_value>正常班次</source_value> | |
| 2310 | + <target_value>normal</target_value> | |
| 2311 | + </field> | |
| 2312 | + <field> | |
| 2313 | + <source_value>出场</source_value> | |
| 2314 | + <target_value>out</target_value> | |
| 2315 | + </field> | |
| 2316 | + <field> | |
| 2317 | + <source_value>进场</source_value> | |
| 2318 | + <target_value>in</target_value> | |
| 2319 | + </field> | |
| 2320 | + <field> | |
| 2321 | + <source_value>加油</source_value> | |
| 2322 | + <target_value>oil</target_value> | |
| 2323 | + </field> | |
| 2324 | + <field> | |
| 2325 | + <source_value>临加</source_value> | |
| 2326 | + <target_value>temp</target_value> | |
| 2327 | + </field> | |
| 2328 | + <field> | |
| 2329 | + <source_value>区间</source_value> | |
| 2330 | + <target_value>region</target_value> | |
| 2331 | + </field> | |
| 2332 | + <field> | |
| 2333 | + <source_value>放空</source_value> | |
| 2334 | + <target_value>venting</target_value> | |
| 2335 | + </field> | |
| 2336 | + <field> | |
| 2337 | + <source_value>放大站</source_value> | |
| 2338 | + <target_value>major</target_value> | |
| 2339 | + </field> | |
| 2340 | + </fields> | |
| 2341 | + <cluster_schema/> | |
| 2342 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2343 | + <xloc>333</xloc> | |
| 2344 | + <yloc>681</yloc> | |
| 2345 | + <draw>Y</draw> | |
| 2346 | + </GUI> | |
| 2347 | + </step> | |
| 2348 | + | |
| 2349 | + <step> | |
| 2350 | + <name>班次类型字典 3</name> | |
| 2351 | + <type>ValueMapper</type> | |
| 2352 | + <description/> | |
| 2353 | + <distribute>Y</distribute> | |
| 2354 | + <custom_distribution/> | |
| 2355 | + <copies>1</copies> | |
| 2356 | + <partitioning> | |
| 2357 | + <method>none</method> | |
| 2358 | + <schema_name/> | |
| 2359 | + </partitioning> | |
| 2360 | + <field_to_use>bctype</field_to_use> | |
| 2361 | + <target_field>bctype_code</target_field> | |
| 2362 | + <non_match_default>未知类型</non_match_default> | |
| 2363 | + <fields> | |
| 2364 | + <field> | |
| 2365 | + <source_value>正常班次</source_value> | |
| 2366 | + <target_value>normal</target_value> | |
| 2367 | + </field> | |
| 2368 | + <field> | |
| 2369 | + <source_value>出场</source_value> | |
| 2370 | + <target_value>out</target_value> | |
| 2371 | + </field> | |
| 2372 | + <field> | |
| 2373 | + <source_value>进场</source_value> | |
| 2374 | + <target_value>in</target_value> | |
| 2375 | + </field> | |
| 2376 | + <field> | |
| 2377 | + <source_value>加油</source_value> | |
| 2378 | + <target_value>oil</target_value> | |
| 2379 | + </field> | |
| 2380 | + <field> | |
| 2381 | + <source_value>临加</source_value> | |
| 2382 | + <target_value>temp</target_value> | |
| 2383 | + </field> | |
| 2384 | + <field> | |
| 2385 | + <source_value>区间</source_value> | |
| 2386 | + <target_value>region</target_value> | |
| 2387 | + </field> | |
| 2388 | + <field> | |
| 2389 | + <source_value>放空</source_value> | |
| 2390 | + <target_value>venting</target_value> | |
| 2391 | + </field> | |
| 2392 | + <field> | |
| 2393 | + <source_value>放大站</source_value> | |
| 2394 | + <target_value>major</target_value> | |
| 2395 | + </field> | |
| 2396 | + </fields> | |
| 2397 | + <cluster_schema/> | |
| 2398 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2399 | + <xloc>551</xloc> | |
| 2400 | + <yloc>928</yloc> | |
| 2401 | + <draw>Y</draw> | |
| 2402 | + </GUI> | |
| 2403 | + </step> | |
| 2404 | + | |
| 2405 | + <step> | |
| 2406 | + <name>类型修正</name> | |
| 2407 | + <type>SelectValues</type> | |
| 2408 | + <description/> | |
| 2409 | + <distribute>Y</distribute> | |
| 2410 | + <custom_distribution/> | |
| 2411 | + <copies>1</copies> | |
| 2412 | + <partitioning> | |
| 2413 | + <method>none</method> | |
| 2414 | + <schema_name/> | |
| 2415 | + </partitioning> | |
| 2416 | + <fields> <select_unspecified>N</select_unspecified> | |
| 2417 | + <meta> <name>jhlc</name> | |
| 2418 | + <rename>jhlc</rename> | |
| 2419 | + <type>Number</type> | |
| 2420 | + <length>-2</length> | |
| 2421 | + <precision>-2</precision> | |
| 2422 | + <conversion_mask/> | |
| 2423 | + <date_format_lenient>false</date_format_lenient> | |
| 2424 | + <date_format_locale/> | |
| 2425 | + <date_format_timezone/> | |
| 2426 | + <lenient_string_to_number>false</lenient_string_to_number> | |
| 2427 | + <encoding/> | |
| 2428 | + <decimal_symbol/> | |
| 2429 | + <grouping_symbol/> | |
| 2430 | + <currency_symbol/> | |
| 2431 | + <storage_type/> | |
| 2432 | + </meta> <meta> <name>bcsj</name> | |
| 2433 | + <rename>bcsj</rename> | |
| 2434 | + <type>Integer</type> | |
| 2435 | + <length>-2</length> | |
| 2436 | + <precision>-2</precision> | |
| 2437 | + <conversion_mask/> | |
| 2438 | + <date_format_lenient>false</date_format_lenient> | |
| 2439 | + <date_format_locale/> | |
| 2440 | + <date_format_timezone/> | |
| 2441 | + <lenient_string_to_number>false</lenient_string_to_number> | |
| 2442 | + <encoding/> | |
| 2443 | + <decimal_symbol/> | |
| 2444 | + <grouping_symbol/> | |
| 2445 | + <currency_symbol/> | |
| 2446 | + <storage_type/> | |
| 2447 | + </meta> </fields> <cluster_schema/> | |
| 2448 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2449 | + <xloc>146</xloc> | |
| 2450 | + <yloc>768</yloc> | |
| 2451 | + <draw>Y</draw> | |
| 2452 | + </GUI> | |
| 2453 | + </step> | |
| 2454 | + | |
| 2455 | + <step> | |
| 2456 | + <name>类型修正 2</name> | |
| 2457 | + <type>SelectValues</type> | |
| 2458 | + <description/> | |
| 2459 | + <distribute>Y</distribute> | |
| 2460 | + <custom_distribution/> | |
| 2461 | + <copies>1</copies> | |
| 2462 | + <partitioning> | |
| 2463 | + <method>none</method> | |
| 2464 | + <schema_name/> | |
| 2465 | + </partitioning> | |
| 2466 | + <fields> <select_unspecified>N</select_unspecified> | |
| 2467 | + <meta> <name>out_mileage</name> | |
| 2468 | + <rename>out_mileage</rename> | |
| 2469 | + <type>Number</type> | |
| 2470 | + <length>-2</length> | |
| 2471 | + <precision>-2</precision> | |
| 2472 | + <conversion_mask/> | |
| 2473 | + <date_format_lenient>false</date_format_lenient> | |
| 2474 | + <date_format_locale/> | |
| 2475 | + <date_format_timezone/> | |
| 2476 | + <lenient_string_to_number>false</lenient_string_to_number> | |
| 2477 | + <encoding/> | |
| 2478 | + <decimal_symbol/> | |
| 2479 | + <grouping_symbol/> | |
| 2480 | + <currency_symbol/> | |
| 2481 | + <storage_type/> | |
| 2482 | + </meta> <meta> <name>out_time</name> | |
| 2483 | + <rename>out_time</rename> | |
| 2484 | + <type>Integer</type> | |
| 2485 | + <length>-2</length> | |
| 2486 | + <precision>-2</precision> | |
| 2487 | + <conversion_mask/> | |
| 2488 | + <date_format_lenient>false</date_format_lenient> | |
| 2489 | + <date_format_locale/> | |
| 2490 | + <date_format_timezone/> | |
| 2491 | + <lenient_string_to_number>false</lenient_string_to_number> | |
| 2492 | + <encoding/> | |
| 2493 | + <decimal_symbol/> | |
| 2494 | + <grouping_symbol/> | |
| 2495 | + <currency_symbol/> | |
| 2496 | + <storage_type/> | |
| 2497 | + </meta> <meta> <name>sxx</name> | |
| 2498 | + <rename>sxx</rename> | |
| 2499 | + <type>Integer</type> | |
| 2500 | + <length>-2</length> | |
| 2501 | + <precision>-2</precision> | |
| 2502 | + <conversion_mask/> | |
| 2503 | + <date_format_lenient>false</date_format_lenient> | |
| 2504 | + <date_format_locale/> | |
| 2505 | + <date_format_timezone/> | |
| 2506 | + <lenient_string_to_number>false</lenient_string_to_number> | |
| 2507 | + <encoding/> | |
| 2508 | + <decimal_symbol/> | |
| 2509 | + <grouping_symbol/> | |
| 2510 | + <currency_symbol/> | |
| 2511 | + <storage_type/> | |
| 2512 | + </meta> </fields> <cluster_schema/> | |
| 2513 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2514 | + <xloc>338</xloc> | |
| 2515 | + <yloc>1008</yloc> | |
| 2516 | + <draw>Y</draw> | |
| 2517 | + </GUI> | |
| 2518 | + </step> | |
| 2519 | + | |
| 2520 | + <step> | |
| 2521 | + <name>类型修正 3</name> | |
| 2522 | + <type>SelectValues</type> | |
| 2523 | + <description/> | |
| 2524 | + <distribute>Y</distribute> | |
| 2525 | + <custom_distribution/> | |
| 2526 | + <copies>1</copies> | |
| 2527 | + <partitioning> | |
| 2528 | + <method>none</method> | |
| 2529 | + <schema_name/> | |
| 2530 | + </partitioning> | |
| 2531 | + <fields> <select_unspecified>N</select_unspecified> | |
| 2532 | + <meta> <name>parade_mileage</name> | |
| 2533 | + <rename>parade_mileage</rename> | |
| 2534 | + <type>Number</type> | |
| 2535 | + <length>-2</length> | |
| 2536 | + <precision>-2</precision> | |
| 2537 | + <conversion_mask/> | |
| 2538 | + <date_format_lenient>false</date_format_lenient> | |
| 2539 | + <date_format_locale/> | |
| 2540 | + <date_format_timezone/> | |
| 2541 | + <lenient_string_to_number>false</lenient_string_to_number> | |
| 2542 | + <encoding/> | |
| 2543 | + <decimal_symbol/> | |
| 2544 | + <grouping_symbol/> | |
| 2545 | + <currency_symbol/> | |
| 2546 | + <storage_type/> | |
| 2547 | + </meta> <meta> <name>parade_time</name> | |
| 2548 | + <rename>parade_time</rename> | |
| 2549 | + <type>Integer</type> | |
| 2550 | + <length>-2</length> | |
| 2551 | + <precision>-2</precision> | |
| 2552 | + <conversion_mask/> | |
| 2553 | + <date_format_lenient>false</date_format_lenient> | |
| 2554 | + <date_format_locale/> | |
| 2555 | + <date_format_timezone/> | |
| 2556 | + <lenient_string_to_number>false</lenient_string_to_number> | |
| 2557 | + <encoding/> | |
| 2558 | + <decimal_symbol/> | |
| 2559 | + <grouping_symbol/> | |
| 2560 | + <currency_symbol/> | |
| 2561 | + <storage_type/> | |
| 2562 | + </meta> <meta> <name>sxx2</name> | |
| 2563 | + <rename>sxx2</rename> | |
| 2564 | + <type>Integer</type> | |
| 2565 | + <length>-2</length> | |
| 2566 | + <precision>-2</precision> | |
| 2567 | + <conversion_mask/> | |
| 2568 | + <date_format_lenient>false</date_format_lenient> | |
| 2569 | + <date_format_locale/> | |
| 2570 | + <date_format_timezone/> | |
| 2571 | + <lenient_string_to_number>false</lenient_string_to_number> | |
| 2572 | + <encoding/> | |
| 2573 | + <decimal_symbol/> | |
| 2574 | + <grouping_symbol/> | |
| 2575 | + <currency_symbol/> | |
| 2576 | + <storage_type/> | |
| 2577 | + </meta> </fields> <cluster_schema/> | |
| 2578 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2579 | + <xloc>847</xloc> | |
| 2580 | + <yloc>1003</yloc> | |
| 2581 | + <draw>Y</draw> | |
| 2582 | + </GUI> | |
| 2583 | + </step> | |
| 2584 | + | |
| 2585 | + <step> | |
| 2586 | + <name>计算班次类型</name> | |
| 2587 | + <type>ValueMapper</type> | |
| 2588 | + <description/> | |
| 2589 | + <distribute>Y</distribute> | |
| 2590 | + <custom_distribution/> | |
| 2591 | + <copies>1</copies> | |
| 2592 | + <partitioning> | |
| 2593 | + <method>none</method> | |
| 2594 | + <schema_name/> | |
| 2595 | + </partitioning> | |
| 2596 | + <field_to_use>qdzname</field_to_use> | |
| 2597 | + <target_field>bctype</target_field> | |
| 2598 | + <non_match_default>正常班次</non_match_default> | |
| 2599 | + <fields> | |
| 2600 | + <field> | |
| 2601 | + <source_value>出场</source_value> | |
| 2602 | + <target_value>出场</target_value> | |
| 2603 | + </field> | |
| 2604 | + <field> | |
| 2605 | + <source_value>进场</source_value> | |
| 2606 | + <target_value>进场</target_value> | |
| 2607 | + </field> | |
| 2608 | + </fields> | |
| 2609 | + <cluster_schema/> | |
| 2610 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2611 | + <xloc>1014</xloc> | |
| 2612 | + <yloc>401</yloc> | |
| 2613 | + <draw>Y</draw> | |
| 2614 | + </GUI> | |
| 2615 | + </step> | |
| 2616 | + | |
| 2617 | + <step> | |
| 2618 | + <name>记录关联 (笛卡尔输出)</name> | |
| 2619 | + <type>JoinRows</type> | |
| 2620 | + <description/> | |
| 2621 | + <distribute>Y</distribute> | |
| 2622 | + <custom_distribution/> | |
| 2623 | + <copies>1</copies> | |
| 2624 | + <partitioning> | |
| 2625 | + <method>none</method> | |
| 2626 | + <schema_name/> | |
| 2627 | + </partitioning> | |
| 2628 | + <directory>%%java.io.tmpdir%%</directory> | |
| 2629 | + <prefix>out</prefix> | |
| 2630 | + <cache_size>500</cache_size> | |
| 2631 | + <main/> | |
| 2632 | + <compare> | |
| 2633 | +<condition> | |
| 2634 | + <negated>N</negated> | |
| 2635 | + <leftvalue/> | |
| 2636 | + <function>=</function> | |
| 2637 | + <rightvalue/> | |
| 2638 | + </condition> | |
| 2639 | + </compare> | |
| 2640 | + <cluster_schema/> | |
| 2641 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2642 | + <xloc>310</xloc> | |
| 2643 | + <yloc>133</yloc> | |
| 2644 | + <draw>Y</draw> | |
| 2645 | + </GUI> | |
| 2646 | + </step> | |
| 2647 | + | |
| 2648 | + <step> | |
| 2649 | + <name>过滤记录(发车时间为空)</name> | |
| 2650 | + <type>FilterRows</type> | |
| 2651 | + <description/> | |
| 2652 | + <distribute>Y</distribute> | |
| 2653 | + <custom_distribution/> | |
| 2654 | + <copies>1</copies> | |
| 2655 | + <partitioning> | |
| 2656 | + <method>none</method> | |
| 2657 | + <schema_name/> | |
| 2658 | + </partitioning> | |
| 2659 | +<send_true_to/> | |
| 2660 | +<send_false_to/> | |
| 2661 | + <compare> | |
| 2662 | +<condition> | |
| 2663 | + <negated>N</negated> | |
| 2664 | + <leftvalue>sendtime</leftvalue> | |
| 2665 | + <function>IS NOT NULL</function> | |
| 2666 | + <rightvalue/> | |
| 2667 | + </condition> | |
| 2668 | + </compare> | |
| 2669 | + <cluster_schema/> | |
| 2670 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2671 | + <xloc>571</xloc> | |
| 2672 | + <yloc>44</yloc> | |
| 2673 | + <draw>Y</draw> | |
| 2674 | + </GUI> | |
| 2675 | + </step> | |
| 2676 | + | |
| 2677 | + <step> | |
| 2678 | + <name>进场班次_确定起点站名字</name> | |
| 2679 | + <type>ScriptValueMod</type> | |
| 2680 | + <description/> | |
| 2681 | + <distribute>Y</distribute> | |
| 2682 | + <custom_distribution/> | |
| 2683 | + <copies>1</copies> | |
| 2684 | + <partitioning> | |
| 2685 | + <method>none</method> | |
| 2686 | + <schema_name/> | |
| 2687 | + </partitioning> | |
| 2688 | + <compatible>N</compatible> | |
| 2689 | + <optimizationLevel>9</optimizationLevel> | |
| 2690 | + <jsScripts> <jsScript> <jsScript_type>0</jsScript_type> | |
| 2691 | + <jsScript_name>Script 1</jsScript_name> | |
| 2692 | + <jsScript_script>//Script here

// 添加站点标识
var cc_groups = qdzgroups.split(","); // 所有班次起点站数组
var qdzname_calcu = cc_groups[gno - 2]; // 进场班次的起点站是上一个班次的终点站,这里只有上一个班次的起点站,还需要计算
var startZdtype_calcu = 'B';
var endZdtype_calcu = 'E';

var destory = 0; // 未撤销flag</jsScript_script> | |
| 2693 | + </jsScript> </jsScripts> <fields> <field> <name>qdzname_calcu</name> | |
| 2694 | + <rename>qdzname_calcu</rename> | |
| 2695 | + <type>String</type> | |
| 2696 | + <length>-1</length> | |
| 2697 | + <precision>-1</precision> | |
| 2698 | + <replace>N</replace> | |
| 2699 | + </field> <field> <name>startZdtype_calcu</name> | |
| 2700 | + <rename>startZdtype_calcu</rename> | |
| 2701 | + <type>String</type> | |
| 2702 | + <length>-1</length> | |
| 2703 | + <precision>-1</precision> | |
| 2704 | + <replace>N</replace> | |
| 2705 | + </field> <field> <name>endZdtype_calcu</name> | |
| 2706 | + <rename>endZdtype_calcu</rename> | |
| 2707 | + <type>String</type> | |
| 2708 | + <length>-1</length> | |
| 2709 | + <precision>-1</precision> | |
| 2710 | + <replace>N</replace> | |
| 2711 | + </field> <field> <name>destory</name> | |
| 2712 | + <rename>destory</rename> | |
| 2713 | + <type>Integer</type> | |
| 2714 | + <length>-1</length> | |
| 2715 | + <precision>-1</precision> | |
| 2716 | + <replace>N</replace> | |
| 2717 | + </field> </fields> <cluster_schema/> | |
| 2718 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2719 | + <xloc>754</xloc> | |
| 2720 | + <yloc>610</yloc> | |
| 2721 | + <draw>Y</draw> | |
| 2722 | + </GUI> | |
| 2723 | + </step> | |
| 2724 | + | |
| 2725 | + <step> | |
| 2726 | + <name>进场班次数据</name> | |
| 2727 | + <type>Dummy</type> | |
| 2728 | + <description/> | |
| 2729 | + <distribute>Y</distribute> | |
| 2730 | + <custom_distribution/> | |
| 2731 | + <copies>1</copies> | |
| 2732 | + <partitioning> | |
| 2733 | + <method>none</method> | |
| 2734 | + <schema_name/> | |
| 2735 | + </partitioning> | |
| 2736 | + <cluster_schema/> | |
| 2737 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2738 | + <xloc>997</xloc> | |
| 2739 | + <yloc>606</yloc> | |
| 2740 | + <draw>Y</draw> | |
| 2741 | + </GUI> | |
| 2742 | + </step> | |
| 2743 | + | |
| 2744 | + <step> | |
| 2745 | + <name>上下行NULL判定</name> | |
| 2746 | + <type>IfNull</type> | |
| 2747 | + <description/> | |
| 2748 | + <distribute>Y</distribute> | |
| 2749 | + <custom_distribution/> | |
| 2750 | + <copies>1</copies> | |
| 2751 | + <partitioning> | |
| 2752 | + <method>none</method> | |
| 2753 | + <schema_name/> | |
| 2754 | + </partitioning> | |
| 2755 | + <replaceAllByValue/> | |
| 2756 | + <replaceAllMask/> | |
| 2757 | + <selectFields>Y</selectFields> | |
| 2758 | + <selectValuesType>N</selectValuesType> | |
| 2759 | + <setEmptyStringAll>N</setEmptyStringAll> | |
| 2760 | + <valuetypes> | |
| 2761 | + </valuetypes> | |
| 2762 | + <fields> | |
| 2763 | + <field> | |
| 2764 | + <name>sxx</name> | |
| 2765 | + <value>0</value> | |
| 2766 | + <mask/> | |
| 2767 | + <set_empty_string>N</set_empty_string> | |
| 2768 | + </field> | |
| 2769 | + </fields> | |
| 2770 | + <cluster_schema/> | |
| 2771 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2772 | + <xloc>230</xloc> | |
| 2773 | + <yloc>946</yloc> | |
| 2774 | + <draw>Y</draw> | |
| 2775 | + </GUI> | |
| 2776 | + </step> | |
| 2777 | + | |
| 2778 | + <step> | |
| 2779 | + <name>上下行判定 2</name> | |
| 2780 | + <type>IfNull</type> | |
| 2781 | + <description/> | |
| 2782 | + <distribute>Y</distribute> | |
| 2783 | + <custom_distribution/> | |
| 2784 | + <copies>1</copies> | |
| 2785 | + <partitioning> | |
| 2786 | + <method>none</method> | |
| 2787 | + <schema_name/> | |
| 2788 | + </partitioning> | |
| 2789 | + <replaceAllByValue/> | |
| 2790 | + <replaceAllMask/> | |
| 2791 | + <selectFields>Y</selectFields> | |
| 2792 | + <selectValuesType>N</selectValuesType> | |
| 2793 | + <setEmptyStringAll>N</setEmptyStringAll> | |
| 2794 | + <valuetypes> | |
| 2795 | + </valuetypes> | |
| 2796 | + <fields> | |
| 2797 | + <field> | |
| 2798 | + <name>sxx2</name> | |
| 2799 | + <value>0</value> | |
| 2800 | + <mask/> | |
| 2801 | + <set_empty_string>N</set_empty_string> | |
| 2802 | + </field> | |
| 2803 | + </fields> | |
| 2804 | + <cluster_schema/> | |
| 2805 | + <remotesteps> <input> </input> <output> </output> </remotesteps> <GUI> | |
| 2806 | + <xloc>804</xloc> | |
| 2807 | + <yloc>1081</yloc> | |
| 2808 | + <draw>Y</draw> | |
| 2809 | + </GUI> | |
| 2810 | + </step> | |
| 2811 | + | |
| 2812 | + <step_error_handling> | |
| 2813 | + <error> | |
| 2814 | + <source_step>插入/更新bsth_c_s_ttinfo_detail</source_step> | |
| 2815 | + <target_step/> | |
| 2816 | + <is_enabled>Y</is_enabled> | |
| 2817 | + <nr_valuename>c1</nr_valuename> | |
| 2818 | + <descriptions_valuename>c2</descriptions_valuename> | |
| 2819 | + <fields_valuename>c3</fields_valuename> | |
| 2820 | + <codes_valuename>c4</codes_valuename> | |
| 2821 | + <max_errors/> | |
| 2822 | + <max_pct_errors/> | |
| 2823 | + <min_pct_rows/> | |
| 2824 | + </error> | |
| 2825 | + </step_error_handling> | |
| 2826 | + <slave-step-copy-partition-distribution> | |
| 2827 | +</slave-step-copy-partition-distribution> | |
| 2828 | + <slave_transformation>N</slave_transformation> | |
| 2829 | + | |
| 2830 | +</transformation> | ... | ... |
src/main/resources/static/pages/forms/mould/account.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/allline.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/commandState.xls
0 → 100644
No preview for this file type
src/main/resources/static/pages/forms/mould/commandState1.xls
0 → 100644
No preview for this file type
src/main/resources/static/pages/forms/mould/correctForm.xls
0 → 100644
No preview for this file type
src/main/resources/static/pages/forms/mould/daily.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/historyMessage.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/message.xls
0 → 100644
No preview for this file type
src/main/resources/static/pages/forms/mould/timeAndSpeed.xls
0 → 100644
No preview for this file type
src/main/resources/static/pages/forms/mould/waybill_minhang.xls
No preview for this file type
src/main/resources/static/pages/forms/mould/waybill_qingpu.xls
0 → 100644
No preview for this file type
src/main/resources/static/pages/forms/statement/busInterval.html
| ... | ... | @@ -261,11 +261,22 @@ |
| 261 | 261 | }); |
| 262 | 262 | } |
| 263 | 263 | |
| 264 | -// $("#export").on("click",function(){ | |
| 265 | -// $get('/pcpc/workDaily',{line:line,date:date,type:'export'},function(result){ | |
| 266 | -// window.open("/downloadFile/download?fileName=营运服务日报表"+moment(date).format("YYYYMMDD")); | |
| 267 | -// }); | |
| 268 | -// }); | |
| 264 | + $("#export").on("click", function(){ | |
| 265 | + var params = {}; | |
| 266 | + params['line'] = line; | |
| 267 | + params['statu'] = statu; | |
| 268 | + params['startDate'] = startDate; | |
| 269 | + params['endDate'] = endDate; | |
| 270 | + params['model'] = model; | |
| 271 | + params['company'] = company; | |
| 272 | + params['subCompany'] = subCompany; | |
| 273 | + params['type'] = "export"; | |
| 274 | + $get('/busInterval/interval', params, function(result){ | |
| 275 | + window.open("/downloadFile/download?fileName=班次间隔统计表" | |
| 276 | + +moment(startDate).format("YYYYMMDD")+"-" | |
| 277 | + +moment(endDate).format("YYYYMMDD")); | |
| 278 | + }); | |
| 279 | + }); | |
| 269 | 280 | |
| 270 | 281 | |
| 271 | 282 | $("#lp1").hide(); | ... | ... |
src/main/resources/static/pages/forms/statement/commandState.html
| ... | ... | @@ -50,7 +50,7 @@ |
| 50 | 50 | </div> |
| 51 | 51 | <div class="form-group" style="margin-left: 9px"> |
| 52 | 52 | <input class="btn btn-default" type="button" id="query" value="筛选"/> |
| 53 | -<!-- <input class="btn btn-default" type="button" id="export" value="导出"/> --> | |
| 53 | + <input class="btn btn-default" type="button" id="export" value="导出"/> | |
| 54 | 54 | </div> |
| 55 | 55 | </form> |
| 56 | 56 | </div> |
| ... | ... | @@ -74,16 +74,23 @@ |
| 74 | 74 | |
| 75 | 75 | </tbody> |
| 76 | 76 | </table> |
| 77 | + <div id="box"> </div> | |
| 77 | 78 | <div id="works_hidden" class="hidden"> |
| 78 | 79 | <span class="item-label" style="width: 80px;margin-left: 20px;">明细: </span> |
| 79 | 80 | <span class="item-label" style="width: 80px;margin-left: 60px;">日期 </span> |
| 80 | 81 | <span class="item-label" style="width: 80px;" id="date1"></span> |
| 82 | + <span class="item-label" style="width: 80px;margin-left: 60px;">公司 </span> | |
| 83 | + <span class="item-label" style="width: 80px;" id="company2"></span> | |
| 84 | + <span class="item-label" style="width: 80px;margin-left: 60px;">分公司 </span> | |
| 85 | + <span class="item-label" style="width: 80px;" id="subCompany2"></span> | |
| 81 | 86 | <span class="item-label" style="width: 80px;margin-left: 60px;">线路 </span> |
| 82 | 87 | <span class="item-label" style="width: 80px;" id="line1"></span> |
| 83 | 88 | <span class="item-label" style="width: 80px;margin-left: 60px;">车辆 </span> |
| 84 | 89 | <span class="item-label" style="width: 80px;" id="clZbh1"></span> |
| 85 | 90 | <span class="item-label" style="width: 80px;margin-left: 60px;">人员 </span> |
| 86 | 91 | <span class="item-label" style="width: 80px;" id="jsy1"></span> |
| 92 | + <span class="item-label" style="width: 80px;margin-left: 60px;"></span> | |
| 93 | + <input class="btn btn-default" type="button" id="export1" value="导出当前明细"/> | |
| 87 | 94 | </div> |
| 88 | 95 | <table class="table table-bordered table-hover table-checkable" id="works"> |
| 89 | 96 | <thead> |
| ... | ... | @@ -112,6 +119,7 @@ |
| 112 | 119 | |
| 113 | 120 | <script> |
| 114 | 121 | $(function(){ |
| 122 | + $('#export').attr('disabled', "true"); | |
| 115 | 123 | var list; |
| 116 | 124 | |
| 117 | 125 | // 关闭左侧栏 |
| ... | ... | @@ -136,7 +144,7 @@ |
| 136 | 144 | $.get('/basic/lineCode2Name',function(result){ |
| 137 | 145 | var data=[]; |
| 138 | 146 | |
| 139 | - data.push({id: "", text: "全部线路"}); | |
| 147 | + data.push({id: " ", text: "全部线路"}); | |
| 140 | 148 | for(var code in result){ |
| 141 | 149 | data.push({id: code, text: result[code]}); |
| 142 | 150 | } |
| ... | ... | @@ -217,16 +225,26 @@ |
| 217 | 225 | |
| 218 | 226 | $("#query").on("click",jsDoQuery); |
| 219 | 227 | |
| 228 | + var line = ""; | |
| 229 | + var date = $("#date").val(); | |
| 230 | + var code = $("#code").val(); | |
| 231 | + var company = $("#company").val(); | |
| 232 | + var subCompany = $("#subCompany").val(); | |
| 220 | 233 | function jsDoQuery(pagination){ |
| 221 | 234 | var params = {}; |
| 222 | - var line = $("#line").val(); | |
| 223 | - if(line = " ") | |
| 235 | + line = $("#line").val(); | |
| 236 | + if(line == " ") | |
| 224 | 237 | line = ""; |
| 238 | + date = $("#date").val(); | |
| 239 | + code = $("#code").val(); | |
| 240 | + company = $("#company").val(); | |
| 241 | + subCompany = $("#subCompany").val(); | |
| 225 | 242 | params['line'] = line; |
| 226 | - params['date'] = $("#date").val(); | |
| 227 | - params['code'] = $("#code").val(); | |
| 228 | - params['company'] = $("#company").val(); | |
| 229 | - params['subCompany'] = $("#subCompany").val(); | |
| 243 | + params['date'] = date; | |
| 244 | + params['code'] = code; | |
| 245 | + params['type'] = "query"; | |
| 246 | + params['company'] = company; | |
| 247 | + params['subCompany'] = subCompany; | |
| 230 | 248 | $("#forms .hidden").removeClass("hidden"); |
| 231 | 249 | $get('/pcpc/commandState', params, function(result){ |
| 232 | 250 | // 把数据填充到模版中 |
| ... | ... | @@ -235,29 +253,69 @@ |
| 235 | 253 | // 把渲染好的模版html文本追加到表格中 |
| 236 | 254 | $('#forms tbody').html(tbodyHtml); |
| 237 | 255 | |
| 256 | + if(result.length == 0){ | |
| 257 | + $('#export').attr('disabled', "true"); | |
| 258 | + } else { | |
| 259 | + $("#export").removeAttr("disabled"); | |
| 260 | + } | |
| 261 | + | |
| 262 | + $("#works_hidden").removeClass("hidden"); | |
| 263 | + $("#works .hidden").removeClass("hidden"); | |
| 264 | + $("#works_hidden").addClass("hidden"); | |
| 265 | + $("#works").addClass("hidden"); | |
| 266 | + | |
| 238 | 267 | }); |
| 239 | 268 | } |
| 240 | 269 | |
| 241 | 270 | $("#export").on("click",function(){ |
| 242 | - $('#forms').tableExport({ type: 'excel', escape: 'false',filename:'(2016-02-29_2016-03-06)'}); | |
| 271 | + var params = {}; | |
| 272 | + params['line'] = line; | |
| 273 | + params['date'] = date; | |
| 274 | + params['code'] = code; | |
| 275 | + params['type'] = "export"; | |
| 276 | + params['company'] = company; | |
| 277 | + params['subCompany'] = subCompany; | |
| 278 | + $get('/pcpc/commandState', params, function(result){ | |
| 279 | + window.open("/downloadFile/download?fileName=指令状态分析"+moment(date).format("YYYYMMDD")); | |
| 280 | + }); | |
| 243 | 281 | }); |
| 244 | 282 | |
| 283 | + var jsy = ""; | |
| 245 | 284 | $("#forms tbody").on("click","a",function(){ |
| 246 | - var jsy = $(this).html(); | |
| 285 | + jsy = $(this).html(); | |
| 247 | 286 | $.each(list, function(i, g){ |
| 248 | 287 | if(jsy == g.jsy){ |
| 249 | 288 | $("#date1").html(g.date); |
| 250 | 289 | $("#line1").html(g.line); |
| 251 | 290 | $("#clZbh1").html(g.clZbh); |
| 252 | 291 | $("#jsy1").html(g.jsy); |
| 292 | + $("#company2").html(g.company); | |
| 293 | + $("subCompany2").html(g.subCompany); | |
| 253 | 294 | $("#works_hidden").removeClass("hidden"); |
| 254 | - $("#works .hidden").removeClass("hidden"); | |
| 295 | + $("#works").removeClass("hidden"); | |
| 255 | 296 | // 把数据填充到模版中 |
| 256 | 297 | var tbodyHtml = template('list_workList',{list:g.workList}); |
| 257 | 298 | // 把渲染好的模版html文本追加到表格中 |
| 258 | 299 | $('#works tbody').html(tbodyHtml); |
| 259 | 300 | } |
| 260 | 301 | }); |
| 302 | + | |
| 303 | + $("html,body").animate({scrollTop:$("#box").offset().top},1000); | |
| 304 | + | |
| 305 | + }); | |
| 306 | + | |
| 307 | + $("#export1").on("click",function(){ | |
| 308 | + var params = {}; | |
| 309 | + params['jsy'] = jsy; | |
| 310 | + params['line'] = line; | |
| 311 | + params['date'] = date; | |
| 312 | + params['code'] = code; | |
| 313 | + params['type'] = "export1"; | |
| 314 | + params['company'] = company; | |
| 315 | + params['subCompany'] = subCompany; | |
| 316 | + $get('/pcpc/commandState', params, function(result){ | |
| 317 | + window.open("/downloadFile/download?fileName=指令状态明细"+moment(date).format("YYYYMMDD")); | |
| 318 | + }); | |
| 261 | 319 | }); |
| 262 | 320 | |
| 263 | 321 | ... | ... |
src/main/resources/static/pages/forms/statement/correctForm.html
| ... | ... | @@ -49,7 +49,7 @@ |
| 49 | 49 | </div> |
| 50 | 50 | <div class="form-group"> |
| 51 | 51 | <input class="btn btn-default" type="button" id="query" value="筛选"/> |
| 52 | -<!-- <input class="btn btn-default" type="button" id="export" value="导出"/> --> | |
| 52 | + <input class="btn btn-default" type="button" id="export" value="导出"/> | |
| 53 | 53 | </div> |
| 54 | 54 | </form> |
| 55 | 55 | </div> | ... | ... |
src/main/resources/static/pages/forms/statement/historyMessage.html
| ... | ... | @@ -139,7 +139,7 @@ |
| 139 | 139 | code = $("#code").val(); |
| 140 | 140 | var type = "query"; |
| 141 | 141 | $(".hidden").removeClass("hidden"); |
| 142 | - $get('/realSchedule/historyMessage',{line:line,date:date,code:code},function(result){ | |
| 142 | + $get('/realSchedule/historyMessage',{line:line,date:date,code:code,type:type},function(result){ | |
| 143 | 143 | // 把数据填充到模版中 |
| 144 | 144 | var tbodyHtml = template('list_history',{list:result}); |
| 145 | 145 | // 把渲染好的模版html文本追加到表格中 | ... | ... |
src/main/resources/static/pages/forms/statement/statisticsDaily .html
| ... | ... | @@ -21,12 +21,12 @@ |
| 21 | 21 | <h1>统计日报</h1> |
| 22 | 22 | </div> |
| 23 | 23 | </div> |
| 24 | - | |
| 25 | -<div class="row"> | |
| 26 | - <div class="col-md-12"> | |
| 27 | - <div class="portlet light porttlet-fit bordered"> | |
| 28 | - <div class="portlet-title"> | |
| 29 | - <form class="form-inline" action=""> | |
| 24 | + | |
| 25 | +<div class="row"> | |
| 26 | + <div class="col-md-12"> | |
| 27 | + <div class="portlet light porttlet-fit bordered"> | |
| 28 | + <div class="portlet-title"> | |
| 29 | + <form class="form-inline" action=""> | |
| 30 | 30 | <div style="display: inline-block;"> |
| 31 | 31 | <span class="item-label" style="width: 80px;">线路: </span> |
| 32 | 32 | <select class="form-control" name="line" id="line" style="width: 180px;"></select> |
| ... | ... | @@ -38,10 +38,10 @@ |
| 38 | 38 | <div class="form-group"> |
| 39 | 39 | <input class="btn btn-default" type="button" id="query" value="查询"/> |
| 40 | 40 | <!-- <input class="btn btn-default" type="button" id="export" value="导出"/> --> |
| 41 | - </div> | |
| 42 | - </form> | |
| 43 | - </div> | |
| 44 | - <div class="portlet-body"> | |
| 41 | + </div> | |
| 42 | + </form> | |
| 43 | + </div> | |
| 44 | + <div class="portlet-body"> | |
| 45 | 45 | <div class="table-container" style="margin-top: 10px;overflow:auto;min-width: 906px"> |
| 46 | 46 | <label>早高峰:6:31~8:30 晚高峰:16:01~18:00</label> |
| 47 | 47 | <table class="table table-bordered table-hover table-checkable" id="forms"> |
| ... | ... | @@ -148,21 +148,21 @@ |
| 148 | 148 | <td colspan="35"> </td> |
| 149 | 149 | </tr> |
| 150 | 150 | </table> |
| 151 | - </div> | |
| 152 | - </div> | |
| 153 | - </div> | |
| 154 | - </div> | |
| 155 | -</div> | |
| 156 | - | |
| 157 | -<script> | |
| 158 | - $(function(){ | |
| 159 | - // 关闭左侧栏 | |
| 160 | - if (!$('body').hasClass('page-sidebar-closed')) | |
| 151 | + </div> | |
| 152 | + </div> | |
| 153 | + </div> | |
| 154 | + </div> | |
| 155 | +</div> | |
| 156 | + | |
| 157 | +<script> | |
| 158 | + $(function(){ | |
| 159 | + // 关闭左侧栏 | |
| 160 | + if (!$('body').hasClass('page-sidebar-closed')) | |
| 161 | 161 | $('.menu-toggler.sidebar-toggler').click(); |
| 162 | - | |
| 163 | - $("#date").datetimepicker({ | |
| 164 | - format : 'YYYY-MM-DD', | |
| 165 | - locale : 'zh-cn' | |
| 162 | + | |
| 163 | + $("#date").datetimepicker({ | |
| 164 | + format : 'YYYY-MM-DD', | |
| 165 | + locale : 'zh-cn' | |
| 166 | 166 | }); |
| 167 | 167 | $.get('/basic/lineCode2Name',function(result){ |
| 168 | 168 | var data=[]; |
| ... | ... | @@ -186,11 +186,11 @@ |
| 186 | 186 | // 把渲染好的模版html文本追加到表格中 |
| 187 | 187 | $('#forms .statisticsDaily').html(tbodyHtml); |
| 188 | 188 | }); |
| 189 | - }); | |
| 190 | - }); | |
| 191 | -</script> | |
| 192 | -<script type="text/html" id="statisticsDaily"> | |
| 193 | - {{each list as obj i}} | |
| 189 | + }); | |
| 190 | + }); | |
| 191 | +</script> | |
| 192 | +<script type="text/html" id="statisticsDaily"> | |
| 193 | + {{each list as obj i}} | |
| 194 | 194 | <tr> |
| 195 | 195 | <td>{{obj.xlName}}</td> |
| 196 | 196 | <td>{{obj.jhlc}}</td> |
| ... | ... | @@ -227,12 +227,12 @@ |
| 227 | 227 | <td>{{obj.djg_m}}</td> |
| 228 | 228 | <td>{{obj.djg_a}}</td> |
| 229 | 229 | <td>{{obj.djg_time}}</td> |
| 230 | - <td> </td> | |
| 231 | - </tr> | |
| 230 | + <td> </td> | |
| 231 | + </tr> | |
| 232 | 232 | {{/each}} |
| 233 | 233 | {{if list.length == 0}} |
| 234 | 234 | <tr> |
| 235 | 235 | <td colspan="36"><h6 class="muted">没有找到相关数据</h6></td> |
| 236 | 236 | </tr> |
| 237 | - {{/if}} | |
| 237 | + {{/if}} | |
| 238 | 238 | </script> |
| 239 | 239 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/forms/statement/timeAndSpeed.html
| ... | ... | @@ -82,7 +82,7 @@ |
| 82 | 82 | </div> |
| 83 | 83 | <div class="form-group" style="margin-left: 14px"> |
| 84 | 84 | <input class="btn btn-default" type="button" id="query" value="筛选"/> |
| 85 | -<!-- <input class="btn btn-default" type="button" id="export" value="导出"/> --> | |
| 85 | + <input class="btn btn-default" type="button" id="export" value="导出"/> | |
| 86 | 86 | </div> |
| 87 | 87 | </form> |
| 88 | 88 | </div> |
| ... | ... | @@ -252,11 +252,23 @@ |
| 252 | 252 | }); |
| 253 | 253 | } |
| 254 | 254 | |
| 255 | -// $("#export").on("click",function(){ | |
| 256 | -// $get('/pcpc/workDaily',{line:line,date:date,type:'export'},function(result){ | |
| 257 | -// window.open("/downloadFile/download?fileName=营运服务日报表"+moment(date).format("YYYYMMDD")); | |
| 258 | -// }); | |
| 259 | -// }); | |
| 255 | + $("#export").on("click", function(){ | |
| 256 | + var params = {}; | |
| 257 | + params['lp'] = lp; | |
| 258 | + params['line'] = line; | |
| 259 | + params['statu'] = statu; | |
| 260 | + params['startDate'] = startDate; | |
| 261 | + params['endDate'] = endDate; | |
| 262 | + params['model'] = model; | |
| 263 | + params['company'] = company; | |
| 264 | + params['subCompany'] = subCompany; | |
| 265 | + params['type'] = "export"; | |
| 266 | + $get('/busInterval/timeAndSpeed', params, function(result){ | |
| 267 | + window.open("/downloadFile/download?fileName=行驶时间及车速统计表" | |
| 268 | + +moment(startDate).format("YYYYMMDD")+"-" | |
| 269 | + +moment(endDate).format("YYYYMMDD")); | |
| 270 | + }); | |
| 271 | + }); | |
| 260 | 272 | |
| 261 | 273 | |
| 262 | 274 | $("#lp1").hide(); |
| ... | ... | @@ -368,8 +380,8 @@ |
| 368 | 380 | <th style='text-align:center;'>公司</th> |
| 369 | 381 | <th style='text-align:center;'>分公司</th> |
| 370 | 382 | <th style='text-align:center;'>线路</th> |
| 371 | - {{if list.statu == 0}}<th style='text-align:center;'>路牌数</th>{{/if}} | |
| 372 | - {{if list.statu == 1}}<th style='text-align:center;'>路牌</th>{{/if}} | |
| 383 | + {{if list.statu == 0}}<th style='text-align:center;'>路牌数量</th>{{/if}} | |
| 384 | + {{if list.statu == 1}}<th style='text-align:center;'>路牌名</th>{{/if}} | |
| 373 | 385 | <th>计划营运时间(小时)</th> |
| 374 | 386 | <th>计划营运车速(公里/小时)</th> |
| 375 | 387 | <th>实际营运时间(小时)</th> |
| ... | ... | @@ -399,7 +411,7 @@ |
| 399 | 411 | <td>{{obj.sjyscs}}</td> |
| 400 | 412 | </tr> |
| 401 | 413 | {{/each}} |
| 402 | - {{if list.dataList.length > 1}} | |
| 414 | + {{if list.dataList.length > 0}} | |
| 403 | 415 | <tr> |
| 404 | 416 | <td style='vertical-align:middle;' colspan='5'>合计平均值</td> |
| 405 | 417 | <td>{{list.jhyysj}}</td> |
| ... | ... | @@ -426,7 +438,7 @@ |
| 426 | 438 | <th style='text-align:center;'>公司</th> |
| 427 | 439 | <th style='text-align:center;'>分公司</th> |
| 428 | 440 | <th style='text-align:center;'>线路</th> |
| 429 | - <th style='text-align:center;'>路牌</th> | |
| 441 | + <th style='text-align:center;'>路牌名</th> | |
| 430 | 442 | <th>计划营运时间(小时)</th> |
| 431 | 443 | <th>计划营运车速(公里/小时)</th> |
| 432 | 444 | <th>实际营运时间(小时)</th> |
| ... | ... | @@ -455,7 +467,7 @@ |
| 455 | 467 | <td>{{obj.sjyscs}}</td> |
| 456 | 468 | </tr> |
| 457 | 469 | {{/each}} |
| 458 | - {{if list.work.length > 1}} | |
| 470 | + {{if list.work.length > 0}} | |
| 459 | 471 | <tr> |
| 460 | 472 | <td style='vertical-align:middle;' colspan='5'>合计平均值</td> |
| 461 | 473 | <td>{{list.jhyysj}}</td> | ... | ... |
src/main/resources/static/pages/forms/statement/waybill.html
| ... | ... | @@ -148,8 +148,9 @@ |
| 148 | 148 | */ |
| 149 | 149 | |
| 150 | 150 | var date = ''; |
| 151 | + var line =''; | |
| 151 | 152 | $("#query").on("click",function(){ |
| 152 | - var line = $("#line").val(); | |
| 153 | + line = $("#line").val(); | |
| 153 | 154 | date = $("#date").val(); |
| 154 | 155 | $(".hidden").removeClass("hidden"); |
| 155 | 156 | $get('/realSchedule/queryUserInfo',{line:line,date:date,state:2},function(result){ |
| ... | ... | @@ -174,21 +175,18 @@ |
| 174 | 175 | jName = params[0].split("\\")[0]; |
| 175 | 176 | var id = $("#"+params[1]).val(); |
| 176 | 177 | $get('/realSchedule/'+id,null,function(result){ |
| 177 | - console.log(result); | |
| 178 | 178 | result.scheduleDate = moment(result.scheduleDate).format("YYYY/MM/DD"); |
| 179 | 179 | var ludan_1 = template('ludan_1',result); |
| 180 | - //var ludan_4 = template('ludan_4',result); | |
| 181 | 180 | // 把渲染好的模版html文本追加到表格中 |
| 182 | 181 | $('#forms .ludan_1').html(ludan_1); |
| 183 | - //$('#forms .ludan_4').html(ludan_4); | |
| 184 | 182 | }); |
| 185 | - $post('/realSchedule/queryListWaybill',{jName:jName,clZbh:params[1],lpName:params[2],date:date},function(result){ | |
| 183 | + $post('/realSchedule/queryListWaybill',{jName:jName,clZbh:params[1],lpName:params[2],date:date,line:line},function(result){ | |
| 186 | 184 | getTime(result); |
| 187 | 185 | var ludan_2 = template('ludan_2',{list:result}); |
| 188 | 186 | // 把渲染好的模版html文本追加到表格中 |
| 189 | 187 | $('#forms .ludan_2').html(ludan_2); |
| 190 | 188 | }); |
| 191 | - $post('/realSchedule/findKMBC',{jName:jName,clZbh:params[1],lpName:params[2],date:date},function(result){ | |
| 189 | + $post('/realSchedule/findKMBC',{jName:jName,clZbh:params[1],lpName:params[2],date:date,line:line},function(result){ | |
| 192 | 190 | var ludan_3 = template('ludan_3',result); |
| 193 | 191 | $('#forms .ludan_3').html(ludan_3); |
| 194 | 192 | }); |
| ... | ... | @@ -199,8 +197,8 @@ |
| 199 | 197 | if(params.length < 1){ |
| 200 | 198 | return; |
| 201 | 199 | } |
| 202 | - $post('/realSchedule/exportWaybill',{jName:jName,clZbh:params[1],lpName:params[2],date:date},function(result){ | |
| 203 | - window.open("/downloadFile/download?fileName="+jName); | |
| 200 | + $post('/realSchedule/exportWaybill',{jName:jName,clZbh:params[1],lpName:params[2],date:date,line:line},function(result){ | |
| 201 | + window.open("/downloadFile/download?fileName="+date+"-"+jName+"-"+params[1]+"-"+params[2]+"-行车路单"); | |
| 204 | 202 | }); |
| 205 | 203 | }); |
| 206 | 204 | |
| ... | ... | @@ -321,7 +319,13 @@ |
| 321 | 319 | <td>{{obj.fast}}</td> |
| 322 | 320 | <td>{{obj.slow}}</td> |
| 323 | 321 | <td>{{obj.jhlc}}</td> |
| 324 | - <td>{{obj.remarks}}</td> | |
| 322 | + <td title={{obj.remarks}}> | |
| 323 | + {{if obj.remarks !=""}} | |
| 324 | + <div class="caption"> | |
| 325 | + <i class="fa fa-search"></i> | |
| 326 | + </div> | |
| 327 | + {{/if}} | |
| 328 | + </td> | |
| 325 | 329 | </tr> |
| 326 | 330 | {{/each}} |
| 327 | 331 | {{if list.length == 0}} |
| ... | ... | @@ -362,99 +366,3 @@ |
| 362 | 366 | <td colspan="2"></td> |
| 363 | 367 | </tr> |
| 364 | 368 | </script> |
| 365 | -<script type="text/html" id="ludan_4"> | |
| 366 | - <tr> | |
| 367 | - <td colspan="12">认真做好终点项目的例保保修工作,杜绝机械火警事故!</td> | |
| 368 | - <td>轮胎</td> | |
| 369 | - <td> </td> | |
| 370 | - </tr> | |
| 371 | - <tr> | |
| 372 | - <td colspan="3">重点例保项目</td> | |
| 373 | - <td>1</td> | |
| 374 | - <td>2</td> | |
| 375 | - <td>3</td> | |
| 376 | - <td colspan="3">重点例保项目</td> | |
| 377 | - <td>1</td> | |
| 378 | - <td>2</td> | |
| 379 | - <td>3</td> | |
| 380 | - <td>灭火机</td> | |
| 381 | - <td> </td> | |
| 382 | - </tr> | |
| 383 | - <tr> | |
| 384 | - <td colspan="3">各类制动</td> | |
| 385 | - <td> </td> | |
| 386 | - <td> </td> | |
| 387 | - <td> </td> | |
| 388 | - <td colspan="3">各类灯光</td> | |
| 389 | - <td> </td> | |
| 390 | - <td> </td> | |
| 391 | - <td> </td> | |
| 392 | - <td colspan="2">出场路码表里程</td> | |
| 393 | - </tr> | |
| 394 | - <tr> | |
| 395 | - <td colspan="3">方向机</td> | |
| 396 | - <td> </td> | |
| 397 | - <td> </td> | |
| 398 | - <td> </td> | |
| 399 | - <td colspan="3">各类仪表</td> | |
| 400 | - <td> </td> | |
| 401 | - <td> </td> | |
| 402 | - <td> </td> | |
| 403 | - <td colspan="2" rowspan="2"> </td> | |
| 404 | - </tr> | |
| 405 | - <tr> | |
| 406 | - <td colspan="3">欠压报警器</td> | |
| 407 | - <td> </td> | |
| 408 | - <td> </td> | |
| 409 | - <td> </td> | |
| 410 | - <td colspan="3">各类皮带</td> | |
| 411 | - <td> </td> | |
| 412 | - <td> </td> | |
| 413 | - <td> </td> | |
| 414 | - </tr> | |
| 415 | - <tr> | |
| 416 | - <td colspan="3">发动机清洁及响声</td> | |
| 417 | - <td> </td> | |
| 418 | - <td> </td> | |
| 419 | - <td> </td> | |
| 420 | - <td colspan="3">油箱及托架</td> | |
| 421 | - <td> </td> | |
| 422 | - <td> </td> | |
| 423 | - <td> </td> | |
| 424 | - <td colspan="2">出场路码表里程</td> | |
| 425 | - </tr> | |
| 426 | - <tr> | |
| 427 | - <td colspan="3">地盘响声</td> | |
| 428 | - <td> </td> | |
| 429 | - <td> </td> | |
| 430 | - <td> </td> | |
| 431 | - <td colspan="3">轮胎、半轴螺栓螺母</td> | |
| 432 | - <td> </td> | |
| 433 | - <td> </td> | |
| 434 | - <td> </td> | |
| 435 | - <td colspan="2" rowspan="3"> </td> | |
| 436 | - </tr> | |
| 437 | - <tr> | |
| 438 | - <td colspan="3">化油器及油路</td> | |
| 439 | - <td> </td> | |
| 440 | - <td> </td> | |
| 441 | - <td> </td> | |
| 442 | - <td colspan="3">油、电、水、气</td> | |
| 443 | - <td> </td> | |
| 444 | - <td> </td> | |
| 445 | - <td> </td> | |
| 446 | - </tr> | |
| 447 | - <tr> | |
| 448 | - <td colspan="3">进排歧管及排气管</td> | |
| 449 | - <td> </td> | |
| 450 | - <td> </td> | |
| 451 | - <td> </td> | |
| 452 | - <td colspan="3">内外车身及附件</td> | |
| 453 | - <td> </td> | |
| 454 | - <td> </td> | |
| 455 | - <td> </td> | |
| 456 | - </tr> | |
| 457 | - <tr> | |
| 458 | - <td colspan="14">1 首次出场,2 复使中途,3 某次进场。√正常,ⓧ报修,×尚未报修</td> | |
| 459 | - </tr> | |
| 460 | -</script> | |
| 461 | 369 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/forms/statement/waybillQp.html
| ... | ... | @@ -18,6 +18,7 @@ |
| 18 | 18 | |
| 19 | 19 | <div class="page-head"> |
| 20 | 20 | <div class="page-title"> |
| 21 | + <i class="fa fa-question-circle-o" aria-hidden="true"></i> | |
| 21 | 22 | <h1>行车路单</h1> |
| 22 | 23 | </div> |
| 23 | 24 | </div> |
| ... | ... | @@ -39,20 +40,18 @@ |
| 39 | 40 | <input class="btn btn-default" type="button" id="query" value="查询"/> |
| 40 | 41 | <input class="btn btn-default" type="button" id="export" value="导出"/> |
| 41 | 42 | <input class="btn btn-default" type="button" id="print" value="打印"/> |
| 42 | - <input class="btn btn-default" type="button" id="exportMore" value="批量导出"/> | |
| 43 | +<!-- <input class="btn btn-default" type="button" id="exportMore" value="批量导出"/> --> | |
| 43 | 44 | </div> |
| 44 | 45 | </form> |
| 45 | 46 | </div> |
| 46 | 47 | <div class="portlet-body"> |
| 47 | 48 | <div class="row"> |
| 48 | - <div class="col-md-3"> | |
| 49 | + <div class="col-md-2"> | |
| 49 | 50 | <div class="" style="margin-top: 10px;overflow:auto;height: 860px"> |
| 50 | 51 | <table class="table table-bordered table-hover table-checkable pre-scrollable" id="info"> |
| 51 | 52 | <thead> |
| 52 | 53 | <tr class="hidden"> |
| 53 | - <th>人员</th> | |
| 54 | 54 | <th>自编号</th> |
| 55 | - <th>路牌</th> | |
| 56 | 55 | </tr> |
| 57 | 56 | </thead> |
| 58 | 57 | <tbody> |
| ... | ... | @@ -102,7 +101,6 @@ |
| 102 | 101 | for(var code in result){ |
| 103 | 102 | data.push({id: code, text: result[code]}); |
| 104 | 103 | } |
| 105 | - console.log(data); | |
| 106 | 104 | initPinYinSelect2('#line',data,''); |
| 107 | 105 | |
| 108 | 106 | }) |
| ... | ... | @@ -148,8 +146,9 @@ |
| 148 | 146 | */ |
| 149 | 147 | |
| 150 | 148 | var date = ''; |
| 149 | + var line =''; | |
| 151 | 150 | $("#query").on("click",function(){ |
| 152 | - var line = $("#line").val(); | |
| 151 | + line= $("#line").val(); | |
| 153 | 152 | date = $("#date").val(); |
| 154 | 153 | $(".hidden").removeClass("hidden"); |
| 155 | 154 | $get('/realSchedule/queryUserInfo',{line:line,date:date,state:3},function(result){ |
| ... | ... | @@ -163,33 +162,32 @@ |
| 163 | 162 | var params = new Array(); |
| 164 | 163 | var jName = ''; |
| 165 | 164 | $("#info tbody").on("click","tr",function(){ |
| 166 | - if($(this).children().size() < 2){ | |
| 165 | + if($(this).children().size() < 1){ | |
| 167 | 166 | return; |
| 168 | 167 | } |
| 169 | - | |
| 170 | 168 | $(this).children().each(function(index){ |
| 171 | 169 | params[index] = $(this).text(); |
| 172 | 170 | }); |
| 173 | - console.log(params); | |
| 174 | - jName = params[0].split("\\")[0]; | |
| 175 | - var id = $("#"+params[1]).val(); | |
| 176 | - $get('/realSchedule/'+id,null,function(result){ | |
| 171 | + | |
| 172 | + var id = $("#"+params[0]).val(); | |
| 173 | + | |
| 174 | + $get('/realSchedule/MapById',{id:id},function(result){ | |
| 177 | 175 | console.log(result); |
| 178 | - result.scheduleDate = moment(result.scheduleDate).format("YYYY/MM/DD"); | |
| 179 | - var ludan_1 = template('ludan_1',result); | |
| 176 | +// result.scheduleDate = moment(result.scheduleDate).format("YYYY/MM/DD"); | |
| 177 | + var ludan_1 = template('ludan_1',{map:result}); | |
| 180 | 178 | //var ludan_4 = template('ludan_4',result); |
| 181 | 179 | // 把渲染好的模版html文本追加到表格中 |
| 182 | 180 | $('#forms .ludan_1').html(ludan_1); |
| 183 | 181 | //$('#forms .ludan_4').html(ludan_4); |
| 184 | 182 | }); |
| 185 | - $post('/realSchedule/queryListWaybillQp',{jName:jName,clZbh:params[1],lpName:params[2],date:date},function(result){ | |
| 183 | + $post('/realSchedule/queryListWaybillQp',{clZbh:params[0],date:date,line:line},function(result){ | |
| 186 | 184 | getTime(result); |
| 187 | 185 | var ludan_2 = template('ludan_2',{list:result}); |
| 188 | 186 | // 把渲染好的模版html文本追加到表格中 |
| 189 | 187 | $('#forms .ludan_2').html(ludan_2); |
| 190 | 188 | }); |
| 191 | - $post('/realSchedule/findKMBC',{jName:jName,clZbh:params[1],lpName:params[2],date:date},function(result){ | |
| 192 | - var ludan_3 = template('ludan_3',result); | |
| 189 | + $post('/realSchedule/findKMBCQp',{clZbh:params[0],date:date,line:line},function(result){ | |
| 190 | + var ludan_3 = template('ludan_3',{map:result}); | |
| 193 | 191 | $('#forms .ludan_3').html(ludan_3); |
| 194 | 192 | }); |
| 195 | 193 | |
| ... | ... | @@ -199,8 +197,8 @@ |
| 199 | 197 | if(params.length < 1){ |
| 200 | 198 | return; |
| 201 | 199 | } |
| 202 | - $post('/realSchedule/exportWaybill',{jName:jName,clZbh:params[1],lpName:params[2],date:date},function(result){ | |
| 203 | - window.open("/downloadFile/download?fileName="+jName); | |
| 200 | + $post('/realSchedule/exportWaybillQp',{clZbh:params[0],date:date,line:line},function(result){ | |
| 201 | + window.open("/downloadFile/download?fileName="+date+"-"+params[0]+"-行车路单"); | |
| 204 | 202 | }); |
| 205 | 203 | }); |
| 206 | 204 | |
| ... | ... | @@ -234,9 +232,7 @@ |
| 234 | 232 | <script type="text/html" id="list_info"> |
| 235 | 233 | {{each list as obj i}} |
| 236 | 234 | <tr> |
| 237 | - <td width="45%">{{obj[4]}}\{{obj[1]}}</td> | |
| 238 | - <td width="32%">{{obj[2]}}</td> | |
| 239 | - <td width="23%">{{obj[3]}}<input type="hidden" id="{{obj[2]}}" value="{{obj[0]}}"></td> | |
| 235 | + <td>{{obj[1]}}<input type="hidden" id="{{obj[1]}}" value="{{obj[0]}}"></td> | |
| 240 | 236 | </tr> |
| 241 | 237 | {{/each}} |
| 242 | 238 | {{if list.length == 0}} |
| ... | ... | @@ -247,43 +243,32 @@ |
| 247 | 243 | </script> |
| 248 | 244 | <script type="text/html" id="ludan_1"> |
| 249 | 245 | <tr> |
| 250 | - <td colspan="14">行车路单</td> | |
| 246 | + <td colspan="15">行车路单</td> | |
| 251 | 247 | </tr> |
| 252 | 248 | <tr> |
| 253 | - <td colspan="14">路别:{{xlName}} 路牌:{{lpName}} 车号:{{clZbh}} 出场时间:{{fcsjActual}} 到达站名:{{zdzName}} 当班调派: 日期:{{scheduleDate}}</td> | |
| 249 | + <td colspan="15">路别:{{map.xlName}} 车号:{{map.clZbh}} 出场时间:{{map.fcsjActual}} 到达站名:{{map.zdzName}} 日期:{{map.scheduleDate}}</td> | |
| 254 | 250 | </tr> |
| 255 | 251 | <tr> |
| 256 | 252 | <td colspan="2">出场存油 升</td> |
| 257 | - <td colspan="2">加注油量 升</td> | |
| 253 | + <td colspan="3">加注油量 升</td> | |
| 258 | 254 | <td colspan="2">进场存油 升</td> |
| 259 | 255 | <td colspan="4">加注机油 升</td> |
| 260 | 256 | <td colspan="4">本日耗油 升</td> |
| 261 | 257 | </tr> |
| 262 | 258 | <tr> |
| 263 | - <td rowspan="2">调度章</td> | |
| 264 | - <td colspan="1"> </td> | |
| 265 | - <td rowspan="2">早班</td> | |
| 266 | - <td colspan="1"> </td> | |
| 267 | - <td rowspan="2">夜班</td> | |
| 268 | - <td colspan="1"> </td> | |
| 269 | - <td rowspan="2" colspan="2">交叉</td> | |
| 259 | + <td colspan="2">调度员</td> | |
| 260 | + <td colspan="2">早班(职号)</td> | |
| 261 | + <td >{{map.zdp}}</td> | |
| 262 | + <td >中班(职号)</td> | |
| 263 | + <td >{{map.zwdp}}</td> | |
| 264 | + <td colspan="2">夜班(职号)</td> | |
| 265 | + <td colspan="2">{{map.wdp}}</td> | |
| 266 | + <td colspan="2">其他</td> | |
| 270 | 267 | <td colspan="2"> </td> |
| 271 | - <td rowspan="2">其他</td> | |
| 272 | - <td colspan="1"> </td> | |
| 273 | - <td colspan="1"> </td> | |
| 274 | - <td colspan="1"> </td> | |
| 275 | - </tr> | |
| 276 | - <tr> | |
| 277 | - <td colspan="1"> </td> | |
| 278 | - <td colspan="1"> </td> | |
| 279 | - <td colspan="1"> </td> | |
| 280 | - <td colspan="2"> </td> | |
| 281 | - <td colspan="1"> </td> | |
| 282 | - <td colspan="1"> </td> | |
| 283 | - <td colspan="1"> </td> | |
| 284 | 268 | </tr> |
| 285 | 269 | <tr> |
| 286 | 270 | <td rowspan="2">车次</td> |
| 271 | + <td rowspan="2">路牌</td> | |
| 287 | 272 | <td colspan="2">工号</td> |
| 288 | 273 | <td rowspan="2">公里耗油</td> |
| 289 | 274 | <td colspan="2">起讫站</td> |
| ... | ... | @@ -309,6 +294,7 @@ |
| 309 | 294 | {{each list as obj i}} |
| 310 | 295 | <tr> |
| 311 | 296 | <td>{{i+1}}</td> |
| 297 | + <td>{{obj.lpName}}</td> | |
| 312 | 298 | <td>{{obj.jName}}</td> |
| 313 | 299 | <td>{{obj.sName}}</td> |
| 314 | 300 | <td> </td> |
| ... | ... | @@ -321,7 +307,14 @@ |
| 321 | 307 | <td>{{obj.fast}}</td> |
| 322 | 308 | <td>{{obj.slow}}</td> |
| 323 | 309 | <td>{{obj.jhlc}}</td> |
| 324 | - <td>{{obj.remarks}}</td> | |
| 310 | + <td title={{obj.remarks}}> | |
| 311 | + {{if obj.remarks !=""}} | |
| 312 | + <div class="caption"> | |
| 313 | + <i class="fa fa-search"></i> | |
| 314 | + | |
| 315 | + </div> | |
| 316 | + {{/if}} | |
| 317 | + </td> | |
| 325 | 318 | </tr> |
| 326 | 319 | {{/each}} |
| 327 | 320 | {{if list.length == 0}} |
| ... | ... | @@ -333,134 +326,39 @@ |
| 333 | 326 | <script type="text/html" id="ludan_3"> |
| 334 | 327 | <tr> |
| 335 | 328 | <td colspan="2">计划公里</td> |
| 336 | - <td>{{jhlc}}</td> | |
| 337 | - <td colspan="2">营运公里</td> | |
| 338 | - <td >{{yygl}}</td> | |
| 329 | + <td>{{map.jhlc}}</td> | |
| 330 | + <td colspan="2">营运公里(计划)</td> | |
| 331 | + <td >{{map.yygljh}}</td> | |
| 332 | + <td >损失公里</td> | |
| 333 | + <td>{{map.ssgl}}</td> | |
| 339 | 334 | <td colspan="2">空驶公里</td> |
| 340 | - <td>{{ksgl}}</td> | |
| 341 | - <td colspan="3">烂班公里</td> | |
| 342 | - <td colspan="2">{{remMileage}}</td> | |
| 343 | - | |
| 335 | + <td colspan="1">{{map.ksgl}}</td> | |
| 336 | + <td colspan="3">营运公里(实际)</td> | |
| 337 | + <td colspan="1">{{map.yyglsj}}</td> | |
| 344 | 338 | |
| 345 | 339 | </tr> |
| 346 | 340 | <tr> |
| 347 | 341 | <td colspan="2">计划班次</td> |
| 348 | - <td>{{jhbc}}</td> | |
| 349 | - | |
| 342 | + <td>{{map.jhbc}}</td> | |
| 350 | 343 | <td colspan="2">进出场公里</td> |
| 351 | - <td>{{jcclc}}</td> | |
| 352 | - <td colspan="2">临加公里</td> | |
| 353 | - <td>{{addMileage}}</td> | |
| 354 | - <td colspan="3">烂班班次</td> | |
| 355 | - <td colspan="2">{{cjbc}}</td> | |
| 356 | - | |
| 344 | + <td>{{map.jcclc}}</td> | |
| 345 | + <td >加车公里</td> | |
| 346 | + <td>{{map.ljgl}}</td> | |
| 347 | + <td colspan="2">损失班次</td> | |
| 348 | + <td colspan="1">{{map.ssbc}}</td> | |
| 349 | + <td colspan="3">运送公里</td> | |
| 350 | + <td colspan="1">{{map.ysgl}}</td> | |
| 357 | 351 | </tr> |
| 358 | 352 | <tr> |
| 359 | 353 | |
| 360 | 354 | <td colspan="2">实际班次</td> |
| 361 | - <td>{{sjbc}}</td> | |
| 355 | + <td>{{map.sjbc}}</td> | |
| 362 | 356 | <td colspan="2">总公里</td> |
| 363 | - <td>{{realMileage}}</td> | |
| 364 | - <td colspan="2">临加班次</td> | |
| 365 | - <td>{{ljbc}}</td> | |
| 357 | + <td>{{map.zgl}}</td> | |
| 358 | + <td >加车班次</td> | |
| 359 | + <td>{{map.ljbc}}</td> | |
| 366 | 360 | |
| 367 | 361 | <td colspan="3"></td> |
| 368 | - <td colspan="2"></td> | |
| 362 | + <td colspan="4"></td> | |
| 369 | 363 | </tr> |
| 370 | 364 | </script> |
| 371 | -<script type="text/html" id="ludan_4"> | |
| 372 | - <tr> | |
| 373 | - <td colspan="12">认真做好终点项目的例保保修工作,杜绝机械火警事故!</td> | |
| 374 | - <td>轮胎</td> | |
| 375 | - <td> </td> | |
| 376 | - </tr> | |
| 377 | - <tr> | |
| 378 | - <td colspan="3">重点例保项目</td> | |
| 379 | - <td>1</td> | |
| 380 | - <td>2</td> | |
| 381 | - <td>3</td> | |
| 382 | - <td colspan="3">重点例保项目</td> | |
| 383 | - <td>1</td> | |
| 384 | - <td>2</td> | |
| 385 | - <td>3</td> | |
| 386 | - <td>灭火机</td> | |
| 387 | - <td> </td> | |
| 388 | - </tr> | |
| 389 | - <tr> | |
| 390 | - <td colspan="3">各类制动</td> | |
| 391 | - <td> </td> | |
| 392 | - <td> </td> | |
| 393 | - <td> </td> | |
| 394 | - <td colspan="3">各类灯光</td> | |
| 395 | - <td> </td> | |
| 396 | - <td> </td> | |
| 397 | - <td> </td> | |
| 398 | - <td colspan="2">出场路码表里程</td> | |
| 399 | - </tr> | |
| 400 | - <tr> | |
| 401 | - <td colspan="3">方向机</td> | |
| 402 | - <td> </td> | |
| 403 | - <td> </td> | |
| 404 | - <td> </td> | |
| 405 | - <td colspan="3">各类仪表</td> | |
| 406 | - <td> </td> | |
| 407 | - <td> </td> | |
| 408 | - <td> </td> | |
| 409 | - <td colspan="2" rowspan="2"> </td> | |
| 410 | - </tr> | |
| 411 | - <tr> | |
| 412 | - <td colspan="3">欠压报警器</td> | |
| 413 | - <td> </td> | |
| 414 | - <td> </td> | |
| 415 | - <td> </td> | |
| 416 | - <td colspan="3">各类皮带</td> | |
| 417 | - <td> </td> | |
| 418 | - <td> </td> | |
| 419 | - <td> </td> | |
| 420 | - </tr> | |
| 421 | - <tr> | |
| 422 | - <td colspan="3">发动机清洁及响声</td> | |
| 423 | - <td> </td> | |
| 424 | - <td> </td> | |
| 425 | - <td> </td> | |
| 426 | - <td colspan="3">油箱及托架</td> | |
| 427 | - <td> </td> | |
| 428 | - <td> </td> | |
| 429 | - <td> </td> | |
| 430 | - <td colspan="2">出场路码表里程</td> | |
| 431 | - </tr> | |
| 432 | - <tr> | |
| 433 | - <td colspan="3">地盘响声</td> | |
| 434 | - <td> </td> | |
| 435 | - <td> </td> | |
| 436 | - <td> </td> | |
| 437 | - <td colspan="3">轮胎、半轴螺栓螺母</td> | |
| 438 | - <td> </td> | |
| 439 | - <td> </td> | |
| 440 | - <td> </td> | |
| 441 | - <td colspan="2" rowspan="3"> </td> | |
| 442 | - </tr> | |
| 443 | - <tr> | |
| 444 | - <td colspan="3">化油器及油路</td> | |
| 445 | - <td> </td> | |
| 446 | - <td> </td> | |
| 447 | - <td> </td> | |
| 448 | - <td colspan="3">油、电、水、气</td> | |
| 449 | - <td> </td> | |
| 450 | - <td> </td> | |
| 451 | - <td> </td> | |
| 452 | - </tr> | |
| 453 | - <tr> | |
| 454 | - <td colspan="3">进排歧管及排气管</td> | |
| 455 | - <td> </td> | |
| 456 | - <td> </td> | |
| 457 | - <td> </td> | |
| 458 | - <td colspan="3">内外车身及附件</td> | |
| 459 | - <td> </td> | |
| 460 | - <td> </td> | |
| 461 | - <td> </td> | |
| 462 | - </tr> | |
| 463 | - <tr> | |
| 464 | - <td colspan="14">1 首次出场,2 复使中途,3 某次进场。√正常,ⓧ报修,×尚未报修</td> | |
| 465 | - </tr> | |
| 466 | -</script> | |
| 467 | 365 | \ No newline at end of file | ... | ... |
src/main/resources/static/pages/report/message/message.html
| ... | ... | @@ -41,7 +41,7 @@ |
| 41 | 41 | </div> |
| 42 | 42 | <div class="form-group" style="display: inline-block;margin-left: 15px;"> |
| 43 | 43 | <input class="btn btn-default" type="button" id="query" value="查询"/> |
| 44 | -<!-- <input class="btn btn-default" type="button" id="export" value="导出"/> --> | |
| 44 | + <input class="btn btn-default" type="button" id="export" value="导出"/> | |
| 45 | 45 | <input class="btn btn-default" type="button" id="print" value="打印"/> |
| 46 | 46 | <!-- <input class="btn btn-default" type="button" id="exportMore" value="批量导出"/> --> |
| 47 | 47 | </div> |
| ... | ... | @@ -73,7 +73,7 @@ |
| 73 | 73 | <tr class="hidden"> |
| 74 | 74 | <th>序号</th> |
| 75 | 75 | <th>线路</th> |
| 76 | - <th>路牌</th> | |
| 76 | +<!-- <th>路牌</th> --> | |
| 77 | 77 | <th>运营车辆</th> |
| 78 | 78 | <th>发送人</th> |
| 79 | 79 | <th>发送时间</th> |
| ... | ... | @@ -93,7 +93,11 @@ |
| 93 | 93 | </div> |
| 94 | 94 | |
| 95 | 95 | <script> |
| 96 | - $(function(){ | |
| 96 | + $(function(){ | |
| 97 | + $('#print').attr('disabled', "true"); | |
| 98 | + $('#export').attr('disabled', "true"); | |
| 99 | + $('#printArea').hide(); | |
| 100 | + | |
| 97 | 101 | // 关闭左侧栏 |
| 98 | 102 | if (!$('body').hasClass('page-sidebar-closed')) |
| 99 | 103 | $('.menu-toggler.sidebar-toggler').click(); |
| ... | ... | @@ -106,11 +110,11 @@ |
| 106 | 110 | var year = d.getFullYear(); |
| 107 | 111 | var month = d.getMonth() + 1; |
| 108 | 112 | var day = d.getDate(); |
| 109 | - if(month > 9){ | |
| 110 | - $("#date").val(year + "-" + month + "-" + day); | |
| 111 | - } else { | |
| 112 | - $("#date").val(year + "-0" + month + "-" + day); | |
| 113 | - } | |
| 113 | + if(month < 9) | |
| 114 | + month = "0" + month; | |
| 115 | + if(day < 9) | |
| 116 | + day = "0" + day; | |
| 117 | + $("#date").val(year + "-" + month + "-" + day); | |
| 114 | 118 | |
| 115 | 119 | $.get('/basic/lineCode2Name',function(result){ |
| 116 | 120 | var data=[]; |
| ... | ... | @@ -161,17 +165,23 @@ |
| 161 | 165 | } |
| 162 | 166 | }); |
| 163 | 167 | |
| 164 | - var date = ''; | |
| 168 | + var date = ''; | |
| 169 | + var line = $("#line").val(); | |
| 165 | 170 | $("#query").on("click",function(){ |
| 166 | - var line = $("#line").val(); | |
| 171 | + line = $("#line").val(); | |
| 167 | 172 | date = $("#date").val(); |
| 168 | - var code=$("#code").val(); | |
| 173 | + var code = $("#code").val(); | |
| 169 | 174 | $(".hidden").removeClass("hidden"); |
| 170 | 175 | $get('/report/historyMessageCount',{line:line,date:date,code:code},function(result){ |
| 171 | 176 | // 把数据填充到模版中 |
| 172 | 177 | var tbodyHtml = template('list_msg_info',{list:result}); |
| 173 | 178 | // 把渲染好的模版html文本追加到表格中 |
| 174 | - $('#info_msg tbody').html(tbodyHtml); | |
| 179 | + $('#info_msg tbody').html(tbodyHtml); | |
| 180 | + | |
| 181 | + $('#print').attr('disabled', "true"); | |
| 182 | + $('#export').attr('disabled', "true"); | |
| 183 | + $('#printArea').hide(); | |
| 184 | + | |
| 175 | 185 | }); |
| 176 | 186 | }); |
| 177 | 187 | |
| ... | ... | @@ -185,21 +195,28 @@ |
| 185 | 195 | params[index] = $(this).text(); |
| 186 | 196 | }); |
| 187 | 197 | jName = params[1]; |
| 188 | - var line = $("#line").val(); | |
| 198 | + line = $("#line").val(); | |
| 189 | 199 | date = $("#date").val(); |
| 190 | - $get('/realSchedule/historyMessage',{line:line,date:date,code:jName},function(result){ | |
| 200 | + $get('/realSchedule/historyMessage',{line:line,date:date,code:jName,type:"query"},function(result){ | |
| 191 | 201 | var list_history_msg = template('list_history_msg',{list:result}); |
| 192 | 202 | // 把渲染好的模版html文本追加到表格中 |
| 193 | - $('#forms tbody').html(list_history_msg); | |
| 203 | + $('#forms tbody').html(list_history_msg); | |
| 204 | + | |
| 205 | + if(result.length == 0){ | |
| 206 | + $('#export').attr('disabled', "true"); | |
| 207 | + $('#print').attr('disabled', "true"); | |
| 208 | + } else { | |
| 209 | + $("#export").removeAttr("disabled"); | |
| 210 | + $("#print").removeAttr("disabled"); | |
| 211 | + } | |
| 212 | + $('#printArea').show(); | |
| 213 | + | |
| 194 | 214 | }); |
| 195 | 215 | }); |
| 196 | 216 | |
| 197 | 217 | $("#export").on("click",function(){ |
| 198 | - if(params.length < 1){ | |
| 199 | - return; | |
| 200 | - } | |
| 201 | - $post('/realSchedule/exportWaybill',{jName:jName,clZbh:params[1],lpName:params[2],date:date},function(result){ | |
| 202 | - window.open("/downloadFile/download?fileName="+jName); | |
| 218 | + $get('/realSchedule/historyMessage',{line:line,date:date,code:jName,type:"export_msg"},function(result){ | |
| 219 | + window.open("/downloadFile/download?fileName=调度消息分析"+moment(date).format("YYYYMMDD")); | |
| 203 | 220 | }); |
| 204 | 221 | }); |
| 205 | 222 | |
| ... | ... | @@ -236,7 +253,7 @@ |
| 236 | 253 | <tr> |
| 237 | 254 | <td>{{i+1}}</td> |
| 238 | 255 | <td>{{obj[4]}}</td> |
| 239 | - <td>{{obj[6]}}</td> | |
| 256 | + <!--<td>{{obj[6]}}</td>--> | |
| 240 | 257 | <td>{{obj[0]}}</td> |
| 241 | 258 | <td>{{obj[1]}}</td> |
| 242 | 259 | <td>{{obj[3]}}</td> | ... | ... |
src/main/resources/static/real_control_v2/css/home.css
| ... | ... | @@ -39,7 +39,7 @@ |
| 39 | 39 | border: 1px solid #e6e6e6; |
| 40 | 40 | border-radius: 4px; |
| 41 | 41 | margin: 0 1px 4px 1px; |
| 42 | - min-height: 230px; | |
| 42 | + min-height: 240px; | |
| 43 | 43 | height: calc(100% / 3 - 12px); |
| 44 | 44 | padding: 3px; |
| 45 | 45 | } |
| ... | ... | @@ -75,30 +75,35 @@ |
| 75 | 75 | } |
| 76 | 76 | |
| 77 | 77 | .home-gps-table dl dt:nth-of-type(3), .home-gps-table dl dd:nth-of-type(3) { |
| 78 | - width: 11% | |
| 78 | + width: 10% | |
| 79 | 79 | } |
| 80 | 80 | |
| 81 | 81 | .home-gps-table dl dt:nth-of-type(4), .home-gps-table dl dd:nth-of-type(4) { |
| 82 | - width: 19% | |
| 82 | + width: 10% | |
| 83 | 83 | } |
| 84 | 84 | |
| 85 | 85 | .home-gps-table dl dt:nth-of-type(5), .home-gps-table dl dd:nth-of-type(5) { |
| 86 | - width: 18% | |
| 86 | + width: 19% | |
| 87 | 87 | } |
| 88 | 88 | |
| 89 | 89 | .home-gps-table dl dt:nth-of-type(6), .home-gps-table dl dd:nth-of-type(6) { |
| 90 | - width: 10% | |
| 90 | + width: 18% | |
| 91 | 91 | } |
| 92 | 92 | |
| 93 | 93 | .home-gps-table dl dt:nth-of-type(7), .home-gps-table dl dd:nth-of-type(7) { |
| 94 | - width: 9% | |
| 94 | + width: 10% | |
| 95 | 95 | } |
| 96 | 96 | |
| 97 | 97 | .home-gps-table dl dt:nth-of-type(8), .home-gps-table dl dd:nth-of-type(8) { |
| 98 | - width: 8%; | |
| 98 | + width: 9%; | |
| 99 | 99 | border-right: 0; |
| 100 | 100 | } |
| 101 | 101 | |
| 102 | +/*.home-gps-table dl dt:nth-of-type(9), .home-gps-table dl dd:nth-of-type(9) { | |
| 103 | + width: 8%; | |
| 104 | + border-right: 0; | |
| 105 | +}*/ | |
| 106 | + | |
| 102 | 107 | .data-wrap.up { |
| 103 | 108 | /*border-left: 1px solid #dadada;*/ |
| 104 | 109 | } |
| ... | ... | @@ -234,3 +239,30 @@ |
| 234 | 239 | .data-wrap.down::-webkit-scrollbar-thumb{ |
| 235 | 240 | box-shadow: 0 0 0 5px rgba(210, 103, 103, 0.44) inset; |
| 236 | 241 | }*/ |
| 242 | + | |
| 243 | +span.signal-state-outbounds{ | |
| 244 | + background: #f3ff00; | |
| 245 | + color: #d42727; | |
| 246 | + padding: 2px 3px; | |
| 247 | + border-radius: 3px; | |
| 248 | + font-size: 11px; | |
| 249 | +} | |
| 250 | + | |
| 251 | +.home-svg-edit-icon{ | |
| 252 | + position: absolute; | |
| 253 | + right: 10px; | |
| 254 | + top: 5px; | |
| 255 | + cursor: pointer; | |
| 256 | + z-index: 3; | |
| 257 | + opacity: 0; | |
| 258 | + transition: all .3s ease; | |
| 259 | +} | |
| 260 | + | |
| 261 | +.home-svg-edit-icon:hover{ | |
| 262 | + opacity: 1; | |
| 263 | +} | |
| 264 | + | |
| 265 | +.home-svg-edit-icon:before{ | |
| 266 | + font-family: FontAwesome; | |
| 267 | + content: "\f040"; | |
| 268 | +} | |
| 237 | 269 | \ No newline at end of file | ... | ... |
src/main/resources/static/real_control_v2/css/line_schedule.css
| ... | ... | @@ -151,13 +151,13 @@ |
| 151 | 151 | } |
| 152 | 152 | |
| 153 | 153 | .ct_table .uk-badge { |
| 154 | - padding: 0 1px 0 1px; | |
| 155 | - text-indent: 0; | |
| 156 | - font-family: 华文细黑; | |
| 154 | + padding: 0 1px 0 1px; | |
| 155 | + text-indent: 0; | |
| 156 | + font-family: 华文细黑; | |
| 157 | 157 | } |
| 158 | 158 | |
| 159 | 159 | .ct_table .uk-badge.uk-badge-notification{ |
| 160 | - text-indent: -1px; | |
| 160 | + text-indent: -1px; | |
| 161 | 161 | } |
| 162 | 162 | |
| 163 | 163 | .schedule-body .ct_table dl._active, .schedule-body .ct_table>.ct_table_body dl._active:hover { |
| ... | ... | @@ -200,7 +200,7 @@ |
| 200 | 200 | } |
| 201 | 201 | |
| 202 | 202 | .schedule-body .ct_table dl._search_hide{ |
| 203 | - display: none !important; | |
| 203 | + display: none !important; | |
| 204 | 204 | } |
| 205 | 205 | |
| 206 | 206 | .context-menu-list.schedule-ct-menu { |
| ... | ... | @@ -246,34 +246,34 @@ span.fcsj-diff { |
| 246 | 246 | /** 图例 */ |
| 247 | 247 | |
| 248 | 248 | .tl-yzx { |
| 249 | - background: #c1ddf0; | |
| 249 | + background: rgb( 192,192,255); | |
| 250 | 250 | border-top: 1px solid #ebebeb !important; |
| 251 | 251 | color: #444; |
| 252 | 252 | } |
| 253 | 253 | |
| 254 | 254 | .tl-xxfc{ |
| 255 | - background: #ff7878; | |
| 256 | - color: #f1f1f1; | |
| 255 | + background: rgb(0,255,255); | |
| 256 | + color: #484747; | |
| 257 | 257 | } |
| 258 | 258 | |
| 259 | 259 | .tl-wd{ |
| 260 | - background: #dede57; | |
| 260 | + background: rgb(255,255,0); | |
| 261 | 261 | color: #444; |
| 262 | 262 | } |
| 263 | 263 | |
| 264 | 264 | .tl-xxsd{ |
| 265 | - background: #e2de94; | |
| 266 | - color: #444; | |
| 265 | + background: rgb(205,133,63); | |
| 266 | + color: #f5f4f4; | |
| 267 | 267 | } |
| 268 | 268 | |
| 269 | 269 | .tl-xxrd{ |
| 270 | - background: #c1ddf0; | |
| 270 | + background: rgb(255,99,71); | |
| 271 | 271 | border-top: 1px solid #ebebeb !important; |
| 272 | - color: #444; | |
| 272 | + color: #fff; | |
| 273 | 273 | } |
| 274 | 274 | |
| 275 | 275 | .tl-qrlb { |
| 276 | - background: #7B6B24; | |
| 276 | + background: rgb( 128,128,0); | |
| 277 | 277 | color: #EAEBEC; |
| 278 | 278 | font-size: 13px; |
| 279 | 279 | } |
| ... | ... | @@ -283,7 +283,7 @@ span.fcsj-diff { |
| 283 | 283 | } |
| 284 | 284 | |
| 285 | 285 | .tl-zzzx { |
| 286 | - background: #96F396; | |
| 286 | + background: rgb(173,255,47); | |
| 287 | 287 | color: #444; |
| 288 | 288 | } |
| 289 | 289 | |
| ... | ... | @@ -370,8 +370,8 @@ span.fcsj-diff { |
| 370 | 370 | |
| 371 | 371 | .ct-form-modal span.uk-form-help-inline, |
| 372 | 372 | .ct-form-modal p.uk-form-help-block{ |
| 373 | - color: #888888; | |
| 374 | - font-size: 13px; | |
| 373 | + color: #888888; | |
| 374 | + font-size: 13px; | |
| 375 | 375 | } |
| 376 | 376 | |
| 377 | 377 | |
| ... | ... | @@ -532,8 +532,8 @@ dl.relevance-active dd:nth-child(n+2) { |
| 532 | 532 | } |
| 533 | 533 | |
| 534 | 534 | dl.relevance-active.intimity dd:nth-child(n+2) { |
| 535 | - background: #76a6c7 !important; | |
| 536 | - color: white; | |
| 535 | + background: #8baabf !important; | |
| 536 | + color: white; | |
| 537 | 537 | } |
| 538 | 538 | |
| 539 | 539 | dl.relevance-active.intimity dd:nth-child(n+2) a { |
| ... | ... | @@ -542,13 +542,24 @@ dl.relevance-active.intimity dd:nth-child(n+2) a { |
| 542 | 542 | |
| 543 | 543 | dl.relevance-active dd.tl-qrlb, |
| 544 | 544 | dl.relevance-active.intimity dd.tl-qrlb{ |
| 545 | - background: linear-gradient(to right, #7B6B24, #4992c3) !important; | |
| 545 | + background: linear-gradient(to right, #a9a911, #808000, #8baabf) !important; | |
| 546 | 546 | color: #f8e9cd; |
| 547 | 547 | } |
| 548 | 548 | |
| 549 | +dl.relevance-active dd.tl-wd, | |
| 550 | +dl.relevance-active.intimity dd.tl-wd{ | |
| 551 | + background: linear-gradient(to right, #ffff00, rgb(226, 226, 168), rgb(139, 170, 191)) !important; | |
| 552 | +} | |
| 553 | + | |
| 554 | +dl.relevance-active dd.tl-qrlb, | |
| 555 | +dl.relevance-active.intimity dd.tl-yzx{ | |
| 556 | + background: linear-gradient(to right, #dcdcfd, #c0c0ff, #8baabf) !important; | |
| 557 | + color: #272727; | |
| 558 | +} | |
| 559 | + | |
| 549 | 560 | dl.relevance-active dd.tl-zzzx, |
| 550 | 561 | dl.relevance-active.intimity dd.tl-zzzx { |
| 551 | - background: linear-gradient(to right, #96F396, #4992c3) !important; | |
| 562 | + background: linear-gradient(to right, #def5bb, #adff2f, #8baabf) !important; | |
| 552 | 563 | color: #565252; |
| 553 | 564 | } |
| 554 | 565 | |
| ... | ... | @@ -557,8 +568,23 @@ dl.relevance-active.intimity dd.tl-zzzx span.fcsj-diff { |
| 557 | 568 | color: #5e5a5a |
| 558 | 569 | } |
| 559 | 570 | |
| 571 | +dl.relevance-active dd.tl-xxsd, | |
| 572 | +dl.relevance-active.intimity dd.tl-xxsd { | |
| 573 | + background: linear-gradient(to right, #8baabf, #cd853f, #dc9958) !important; | |
| 574 | +} | |
| 575 | + | |
| 576 | +dl.relevance-active dd.tl-xxrd, | |
| 577 | +dl.relevance-active.intimity dd.tl-xxrd { | |
| 578 | + background: linear-gradient(to right, #8baabf, #ff6347, #ff8f7b) !important; | |
| 579 | +} | |
| 580 | + | |
| 581 | +dl.relevance-active dd.tl-xxfc, | |
| 582 | +dl.relevance-active.intimity dd.tl-xxfc { | |
| 583 | + background: linear-gradient(to right, #8baabf, rgb(43, 185, 185), rgb(0,255,255)) !important; | |
| 584 | +} | |
| 585 | + | |
| 560 | 586 | dl.relevance-active.intimity dd span.fcsj-diff { |
| 561 | - color: #d7d6d6; | |
| 587 | + color: #616060; | |
| 562 | 588 | } |
| 563 | 589 | |
| 564 | 590 | dl.relevance-active dd span.fcsj-diff{ |
| ... | ... | @@ -604,10 +630,10 @@ div.drop-rail.over { |
| 604 | 630 | } |
| 605 | 631 | |
| 606 | 632 | label.destroy-sch{ |
| 607 | - color: #928e8e; | |
| 633 | + color: #928e8e; | |
| 608 | 634 | } |
| 609 | 635 | label.destroy-sch small{ |
| 610 | - color: #e25e5e; | |
| 636 | + color: #e25e5e; | |
| 611 | 637 | } |
| 612 | 638 | |
| 613 | 639 | .main-schedule-table dl dt:nth-of-type(1), .main-schedule-table dl dd:nth-of-type(1) { |
| ... | ... | @@ -639,20 +665,20 @@ label.destroy-sch small{ |
| 639 | 665 | .main-schedule-table.ct_table dl.active, |
| 640 | 666 | .main-schedule-table.ct_table>.ct_table_body dl.active:hover, |
| 641 | 667 | .main-schedule-table.ct_table>.ct_table_body dl.context-menu-active{ |
| 642 | - background: #9393bf; | |
| 643 | - box-shadow: 0 0 4px #656c71; | |
| 644 | - color: white; | |
| 668 | + background: #9393bf; | |
| 669 | + box-shadow: 0 0 4px #656c71; | |
| 670 | + color: white; | |
| 645 | 671 | } |
| 646 | 672 | |
| 647 | 673 | .main-schedule-table span.sjfc-time{ |
| 648 | - color:#07d | |
| 674 | + color:#07d | |
| 649 | 675 | } |
| 650 | 676 | |
| 651 | 677 | .main-schedule-table dl.active span.sjfc-time{ |
| 652 | - background: white; | |
| 653 | - border-radius: 5px; | |
| 654 | - padding: 2px 1px; | |
| 655 | - vertical-align: middle; | |
| 678 | + background: white; | |
| 679 | + border-radius: 5px; | |
| 680 | + padding: 2px 1px; | |
| 681 | + vertical-align: middle; | |
| 656 | 682 | } |
| 657 | 683 | |
| 658 | 684 | .sub-task-table dl dt:nth-of-type(1), .sub-task-table dl dd:nth-of-type(1) { |
| ... | ... | @@ -682,7 +708,7 @@ label.destroy-sch small{ |
| 682 | 708 | } |
| 683 | 709 | |
| 684 | 710 | .sub-task-table>.ct_table_body>dl:last-child dd{ |
| 685 | - border-bottom: 0; | |
| 711 | + border-bottom: 0; | |
| 686 | 712 | } |
| 687 | 713 | |
| 688 | 714 | .add-temp-sch-icon{ |
| ... | ... | @@ -700,16 +726,16 @@ label.destroy-sch small{ |
| 700 | 726 | |
| 701 | 727 | |
| 702 | 728 | input.i-cbox[type=checkbox]{ |
| 703 | - width: 20px; | |
| 704 | - height: 18px; | |
| 705 | - vertical-align: middle; | |
| 706 | - margin-top: -3px; | |
| 729 | + width: 20px; | |
| 730 | + height: 18px; | |
| 731 | + vertical-align: middle; | |
| 732 | + margin-top: -3px; | |
| 707 | 733 | } |
| 708 | 734 | |
| 709 | 735 | .sys-note-80, |
| 710 | 736 | .sys-note-42{ |
| 711 | - width: calc(100% - 10px) !important; | |
| 712 | - margin: 5px !important; | |
| 737 | + width: calc(100% - 10px) !important; | |
| 738 | + margin: 5px !important; | |
| 713 | 739 | cursor: default; |
| 714 | 740 | } |
| 715 | 741 | |
| ... | ... | @@ -720,21 +746,21 @@ input.i-cbox[type=checkbox]{ |
| 720 | 746 | |
| 721 | 747 | .sys-note-80 .uk-panel-box, |
| 722 | 748 | .sys-note-42 .uk-panel-box{ |
| 723 | - padding: 10px; | |
| 749 | + padding: 10px; | |
| 724 | 750 | } |
| 725 | 751 | .sys-note-80 .uk-panel-title{ |
| 726 | - margin-bottom: 3px; | |
| 727 | - font-size: 15px; | |
| 752 | + margin-bottom: 3px; | |
| 753 | + font-size: 15px; | |
| 728 | 754 | } |
| 729 | 755 | |
| 730 | 756 | .sys-note-42 .title{ |
| 731 | - font-family: 微软雅黑; | |
| 732 | - margin-bottom: 3px; | |
| 757 | + font-family: 微软雅黑; | |
| 758 | + margin-bottom: 3px; | |
| 733 | 759 | } |
| 734 | 760 | .sys-note-80 .uk-button-group, |
| 735 | 761 | .sys-note-42 .uk-button-group{ |
| 736 | - display: block; | |
| 737 | - margin-top: 5px; | |
| 762 | + display: block; | |
| 763 | + margin-top: 5px; | |
| 738 | 764 | } |
| 739 | 765 | |
| 740 | 766 | |
| ... | ... | @@ -759,7 +785,7 @@ input.i-cbox[type=checkbox]{ |
| 759 | 785 | .sch-tzrc-table.ct_table dl.active, |
| 760 | 786 | .sch-tzrc-table.ct_table>.ct_table_body dl.active:hover, |
| 761 | 787 | .sch-tzrc-table.ct_table>.ct_table_body dl.context-menu-active{ |
| 762 | - background: #e6e6e6; | |
| 788 | + background: #e6e6e6; | |
| 763 | 789 | } |
| 764 | 790 | |
| 765 | 791 | .search_sch_panel{ |
| ... | ... | @@ -767,17 +793,17 @@ input.i-cbox[type=checkbox]{ |
| 767 | 793 | } |
| 768 | 794 | |
| 769 | 795 | .search_sch_panel .uk-form input[type=text]{ |
| 770 | - width: 80px; | |
| 771 | - background: #fafafa; | |
| 772 | - border: 0; | |
| 773 | - border-bottom: 1px solid #ddd; | |
| 774 | - font-size: 14px; | |
| 775 | - height: 20px; | |
| 776 | - transition: all .3s ease; | |
| 796 | + width: 80px; | |
| 797 | + background: #fafafa; | |
| 798 | + border: 0; | |
| 799 | + border-bottom: 1px solid #ddd; | |
| 800 | + font-size: 14px; | |
| 801 | + height: 20px; | |
| 802 | + transition: all .3s ease; | |
| 777 | 803 | } |
| 778 | 804 | |
| 779 | 805 | .search_sch_panel .uk-form div.uk-form-icon.active input[type=text]{ |
| 780 | - width: 145px; | |
| 806 | + width: 145px; | |
| 781 | 807 | } |
| 782 | 808 | |
| 783 | 809 | .search_sch_panel .uk-form div.uk-form-icon i.cancel{ |
| ... | ... | @@ -802,8 +828,8 @@ input.i-cbox[type=checkbox]{ |
| 802 | 828 | } |
| 803 | 829 | |
| 804 | 830 | .search_sch_panel .uk-form input[type=text]::-webkit-input-placeholder{ |
| 805 | - font-size: 12px; | |
| 806 | - color: #cecece; | |
| 831 | + font-size: 12px; | |
| 832 | + color: #cecece; | |
| 807 | 833 | } |
| 808 | 834 | .device_event_str{ |
| 809 | 835 | font-size: 10px; |
| ... | ... | @@ -1057,7 +1083,7 @@ i.signal_state_icon.uk-icon-reply{ |
| 1057 | 1083 | |
| 1058 | 1084 | .child-task-status.fail{ |
| 1059 | 1085 | color: red; |
| 1060 | - text-shadow: red 0px 0px 20px; | |
| 1086 | + /*text-shadow: red 0px 0px 20px;*/ | |
| 1061 | 1087 | } |
| 1062 | 1088 | |
| 1063 | 1089 | .child-task-status.fail span.calc-detail{ | ... | ... |
src/main/resources/static/real_control_v2/css/main.css
| ... | ... | @@ -139,6 +139,11 @@ svg.line-chart path.station_link.down { |
| 139 | 139 | stroke: #c92121; |
| 140 | 140 | } |
| 141 | 141 | |
| 142 | +svg.line-chart path.station_link.down.loop_line{ | |
| 143 | + stroke-dasharray: 4,3; | |
| 144 | + stroke-width: 1px; | |
| 145 | +} | |
| 146 | + | |
| 142 | 147 | svg.line-chart text.station_text { |
| 143 | 148 | writing-mode: tb; |
| 144 | 149 | fill: #3e3e3e; |
| ... | ... | @@ -147,26 +152,36 @@ svg.line-chart text.station_text { |
| 147 | 152 | } |
| 148 | 153 | |
| 149 | 154 | svg.line-chart text.station_text.up { |
| 150 | - fill: #5E96D2; | |
| 155 | + fill: #4556b6; | |
| 151 | 156 | } |
| 152 | 157 | |
| 153 | 158 | svg.line-chart text.station_text.down { |
| 154 | - fill: #C92121; | |
| 159 | + fill: #c94f21; | |
| 155 | 160 | } |
| 156 | 161 | |
| 157 | 162 | svg.line-chart g.item:first-child>text { |
| 158 | - stroke: #5E96D2; | |
| 163 | + stroke: #6f6e6e; | |
| 159 | 164 | fill: none; |
| 160 | 165 | } |
| 161 | 166 | |
| 162 | 167 | svg.line-chart g.item:nth-last-child(3)>text { |
| 163 | - stroke: #C92121; | |
| 168 | + stroke: #6f6e6e; | |
| 164 | 169 | fill: none; |
| 165 | 170 | } |
| 166 | 171 | |
| 172 | +svg.line-chart g.item:first-child>text.up , | |
| 173 | +svg.line-chart g.item:nth-last-child(3)>text.up { | |
| 174 | + stroke: #4556b6; | |
| 175 | +} | |
| 176 | + | |
| 177 | +svg.line-chart g.item:first-child>text.down , | |
| 178 | +svg.line-chart g.item:nth-last-child(3)>text.down { | |
| 179 | + stroke: #c94f21; | |
| 180 | +} | |
| 181 | + | |
| 167 | 182 | svg.line-chart g.gps-wrap>rect { |
| 168 | 183 | width: 34px; |
| 169 | - height: 18px; | |
| 184 | + height: 15px; | |
| 170 | 185 | /*fill: #fff;*/ |
| 171 | 186 | rx: 4px; |
| 172 | 187 | cursor: pointer; |
| ... | ... | @@ -188,7 +203,7 @@ svg.line-chart g.gps-wrap>rect.hover { |
| 188 | 203 | |
| 189 | 204 | svg.line-chart g.gps-wrap>text { |
| 190 | 205 | font-size: 13px; |
| 191 | - transform: translate(2px, 14px); | |
| 206 | + transform: translate(2px, 12px); | |
| 192 | 207 | pointer-events: none; |
| 193 | 208 | } |
| 194 | 209 | |
| ... | ... | @@ -201,7 +216,7 @@ svg.line-chart g.gps-wrap>text[updown="1"] { |
| 201 | 216 | } |
| 202 | 217 | |
| 203 | 218 | svg.line-chart .merge_hide { |
| 204 | - display: none; | |
| 219 | + display: none !important; | |
| 205 | 220 | } |
| 206 | 221 | |
| 207 | 222 | svg.line-chart g.merge-item rect { |
| ... | ... | @@ -506,3 +521,126 @@ li.map-panel{ |
| 506 | 521 | fill: #dd3829; |
| 507 | 522 | } |
| 508 | 523 | |
| 524 | + | |
| 525 | +.svg-edit-panel-wrap{ | |
| 526 | + width: 48%; | |
| 527 | + border: 1px solid #e1d3d3; | |
| 528 | + padding: 12px 0 0 0; | |
| 529 | + border-radius: 4px; | |
| 530 | + position: relative; | |
| 531 | + display: inline-block; | |
| 532 | + vertical-align: top; | |
| 533 | + height: 440px; | |
| 534 | +} | |
| 535 | + | |
| 536 | +.svg-edit-panel-wrap .title-badge{ | |
| 537 | + position: absolute; | |
| 538 | + top: -10px; | |
| 539 | + left: 7px; | |
| 540 | + font-size: 13px; | |
| 541 | + background: #fff; | |
| 542 | + padding: 0 3px; | |
| 543 | + color: #888888; | |
| 544 | +} | |
| 545 | + | |
| 546 | +.svg-edit-panel-wrap .rename-tools{ | |
| 547 | + height: 21px; | |
| 548 | + padding: 0 0 0 9px; | |
| 549 | +} | |
| 550 | + | |
| 551 | +.svg-edit-panel-wrap .rename-item-panel{ | |
| 552 | + border-bottom: 1px solid #ede5e5; | |
| 553 | + padding: 4px; | |
| 554 | +} | |
| 555 | + | |
| 556 | +.svg-edit-panel-wrap .rename-item-panel select{ | |
| 557 | + width: 150px; | |
| 558 | +} | |
| 559 | + | |
| 560 | +.svg-edit-panel-wrap .rename-item-panel input{ | |
| 561 | + margin-left: 7px; | |
| 562 | +} | |
| 563 | + | |
| 564 | +.svg-edit-panel-wrap .rename-item-panel input[type=checkbox]{ | |
| 565 | + margin-top: 2px; | |
| 566 | + margin-right: 4px; | |
| 567 | +} | |
| 568 | + | |
| 569 | +.svg-edit-panel-wrap .rename-item-panel.active{ | |
| 570 | + background: #65c9f8; | |
| 571 | + box-shadow: 0px 3px 7px 0 rgba(101, 201, 248, 0.48), 0px 1px 4px 0 rgba(101, 201, 248, 0.32); | |
| 572 | +} | |
| 573 | + | |
| 574 | +.svg-edit-panel-wrap .rename-item-panel.active select, | |
| 575 | +.svg-edit-panel-wrap .rename-item-panel.active input{ | |
| 576 | + background: #65c9f8; | |
| 577 | + color: #fff; | |
| 578 | +} | |
| 579 | + | |
| 580 | +.svg-edit-panel-wrap .rename-item-panel.active i{ | |
| 581 | + color: #e4f6ff; | |
| 582 | +} | |
| 583 | + | |
| 584 | +.svg-edit-panel-wrap .rename-item-panel.active input[type=checkbox]{ | |
| 585 | + border:none; | |
| 586 | +} | |
| 587 | + | |
| 588 | +.svg-edit-panel-wrap .rename-item-panel.active input[type=checkbox]:before{ | |
| 589 | + color: #fff; | |
| 590 | +} | |
| 591 | + | |
| 592 | +.svg-edit-panel-wrap .rename-tools a{ | |
| 593 | + font-size: 14px; | |
| 594 | + padding: 5px; | |
| 595 | +} | |
| 596 | +.svg-edit-panel-wrap .rename-tools a:hover{ | |
| 597 | + background: #e8edef; | |
| 598 | + border-radius: 5px; | |
| 599 | +} | |
| 600 | + | |
| 601 | +.station-list{ | |
| 602 | + width: 190px; | |
| 603 | + padding: 2px 7px; | |
| 604 | + height: 100%; | |
| 605 | + overflow: auto; | |
| 606 | + display: inline-block; | |
| 607 | +} | |
| 608 | + | |
| 609 | +.station-list .station-item{ | |
| 610 | + padding: 3px 0; | |
| 611 | + margin: 5px 0; | |
| 612 | + border-radius: 3px; | |
| 613 | + font-size: 13px; | |
| 614 | + text-indent: 7px; | |
| 615 | + cursor: pointer; | |
| 616 | + white-space: nowrap; | |
| 617 | + overflow: hidden; | |
| 618 | + text-overflow: ellipsis; | |
| 619 | +} | |
| 620 | + | |
| 621 | +.station-list .station-item.disable, | |
| 622 | +.station-list .station-item.disable:hover{ | |
| 623 | + background: #d5c9c9 !important; | |
| 624 | + color: #686565 !important; | |
| 625 | +} | |
| 626 | + | |
| 627 | +.station-list.up .station-item{ | |
| 628 | + background: #5364c3; | |
| 629 | + color: white; | |
| 630 | +} | |
| 631 | + | |
| 632 | +.station-list.up .station-item:hover{ | |
| 633 | + box-shadow: 0px 3px 6px 0 rgba(0, 0, 0, 0.2), 0px 1px 4px 0 rgba(0, 0, 0, 0.19); | |
| 634 | + background: #4556b6; | |
| 635 | +} | |
| 636 | + | |
| 637 | + | |
| 638 | +.station-list.down .station-item{ | |
| 639 | + background: #f95858; | |
| 640 | + color: white; | |
| 641 | +} | |
| 642 | + | |
| 643 | +.station-list.down .station-item:hover{ | |
| 644 | + box-shadow: 0px 3px 6px 0 rgba(0, 0, 0, 0.2), 0px 1px 4px 0 rgba(0, 0, 0, 0.19); | |
| 645 | + background: #e95151; | |
| 646 | +} | |
| 509 | 647 | \ No newline at end of file | ... | ... |
src/main/resources/static/real_control_v2/fragments/home/layout.html
| ... | ... | @@ -22,6 +22,7 @@ |
| 22 | 22 | <div class="uk-grid home-line-card" data-line-code="{{line.lineCode}}"> |
| 23 | 23 | <div class="uk-width-medium-1-5 data-wrap up" id="home_{{line.lineCode}}_0"></div> |
| 24 | 24 | <div class="uk-width-medium-3-5 svg-chart-wrap"> |
| 25 | + <div class="home-svg-edit-icon" data-line-code="{{line.lineCode}}"></div> | |
| 25 | 26 | <div class="top-center-big-text"> |
| 26 | 27 | {{line.name}} |
| 27 | 28 | </div> | ... | ... |
src/main/resources/static/real_control_v2/fragments/home/line_panel.html
| ... | ... | @@ -10,12 +10,12 @@ |
| 10 | 10 | <dl> |
| 11 | 11 | <dt>车辆编码</dt> |
| 12 | 12 | <dt>速度</dt> |
| 13 | - <dt>终点时间</dt> | |
| 13 | + <dt>终点</dt> | |
| 14 | + <dt>状态</dt> | |
| 14 | 15 | <dt>当前站点</dt> |
| 15 | 16 | <dt>终点站</dt> |
| 16 | 17 | <dt>计划到达</dt> |
| 17 | 18 | <dt>驾驶员</dt> |
| 18 | - <dt>售票员</dt> | |
| 19 | 19 | </dl> |
| 20 | 20 | </div> |
| 21 | 21 | <div class="ct_table_body"></div> |
| ... | ... | @@ -29,11 +29,29 @@ |
| 29 | 29 | <dd title="{{nbbm}}"><a>{{nbbm}}</a></dd> |
| 30 | 30 | <dd>{{speed}}</dd> |
| 31 | 31 | <dd>{{expectStopTime}}</dd> |
| 32 | + <dd> | |
| 33 | + {{if abnormal != null}} | |
| 34 | + {{if abnormal == 'outBounds'}} | |
| 35 | + 越界 | |
| 36 | + {{/if}} | |
| 37 | + {{else}} | |
| 38 | + 正常 | |
| 39 | + {{/if}} | |
| 40 | + </dd> | |
| 32 | 41 | <dd title="{{stationName}}">{{stationName}}</dd> |
| 33 | 42 | <dd></dd> |
| 34 | 43 | <dd></dd> |
| 35 | 44 | <dd></dd> |
| 36 | - <dd></dd> | |
| 37 | 45 | </dl> |
| 38 | -</script> | |
| 46 | + </script> | |
| 47 | + | |
| 48 | + <script id="home-gps-abnormal-temp" type="text/html"> | |
| 49 | + {{if abnormal != null}} | |
| 50 | + {{if abnormal == 'outBounds'}} | |
| 51 | + <span class="signal-state-outbounds">越界</span> | |
| 52 | + {{/if}} | |
| 53 | + {{else}} | |
| 54 | + 正常 | |
| 55 | + {{/if}} | |
| 56 | + </script> | |
| 39 | 57 | </div> | ... | ... |
src/main/resources/static/real_control_v2/fragments/home/svg_edit.html
0 → 100644
| 1 | +<div class="uk-modal" id="home-svg-edit-modal"> | |
| 2 | + <div class="uk-modal-dialog" style="width: 930px;"> | |
| 3 | + <a href="" class="uk-modal-close uk-close"></a> | |
| 4 | + <div class="uk-modal-header"> | |
| 5 | + <h2>主页模拟图数据编辑</h2></div> | |
| 6 | + | |
| 7 | + <div class="svg-edit-panel-wrap station-list-wrap"> | |
| 8 | + <span class="title-badge">站点缩略</span> | |
| 9 | + </div> | |
| 10 | + | |
| 11 | + | |
| 12 | + <div class="svg-edit-panel-wrap" style="margin-left: 25px;"> | |
| 13 | + <span class="title-badge">站点重命名</span> | |
| 14 | + <div style="height: 100%;"> | |
| 15 | + <div style="height: calc(100% - 25px);"> | |
| 16 | + <form class="uk-form rename-list-form"> | |
| 17 | + </form> | |
| 18 | + </div> | |
| 19 | + | |
| 20 | + <div class="rename-tools" style="height: 21px;"> | |
| 21 | + <a class="uk-icon-small uk-icon-hover uk-icon-plus add"></a> | |
| 22 | + <a class="uk-icon-small uk-icon-hover uk-icon-minus minus"></a> | |
| 23 | + </div> | |
| 24 | + </div> | |
| 25 | + </div> | |
| 26 | + | |
| 27 | + | |
| 28 | + <div class="uk-modal-footer uk-text-right"> | |
| 29 | + <button type="button" class="uk-button uk-modal-close">取消</button> | |
| 30 | + <button type="button" class="uk-button uk-button-primary submitBtn"><i class="uk-icon-check"></i> 保存 | |
| 31 | + </button> | |
| 32 | + </div> | |
| 33 | + </div> | |
| 34 | + | |
| 35 | + <script id="svg-edit-station-list-temp" type="text/html"> | |
| 36 | + <div class="station-list up"> | |
| 37 | + {{each list[0] as s i}} | |
| 38 | + <div class="station-item" data-code="{{s.stationCode}}">{{s.stationName}}</div> | |
| 39 | + {{/each}} | |
| 40 | + </div> | |
| 41 | + | |
| 42 | + <div class="station-list down" style="margin-left: 8px;"> | |
| 43 | + {{each list[1] as s i}} | |
| 44 | + <div class="station-item" data-code="{{s.stationCode}}">{{s.stationName}}</div> | |
| 45 | + {{/each}} | |
| 46 | + </div> | |
| 47 | + </script> | |
| 48 | + | |
| 49 | + <script id="svg-edit-rename-item-temp" type="text/html"> | |
| 50 | + <div class="rename-item-panel"> | |
| 51 | + <input type="checkbox"> | |
| 52 | + <select name="renames[{{no}}][name]"> | |
| 53 | + {{each names as n i}} | |
| 54 | + <option value="{{n}}">{{n}}</option> | |
| 55 | + {{/each}} | |
| 56 | + </select> | |
| 57 | + <i class="uk-icon-arrows-h"></i> | |
| 58 | + <input type="text" value="{{names[0]}}" name="renames[{{no}}][nickname]"> | |
| 59 | + </div> | |
| 60 | + </script> | |
| 61 | + | |
| 62 | + <script> | |
| 63 | + (function () { | |
| 64 | + var modal = '#home-svg-edit-modal', | |
| 65 | + lineCode, names = [], no = 0; | |
| 66 | + | |
| 67 | + $(modal).on('init', function (e, data) { | |
| 68 | + lineCode = data.lineCode; | |
| 69 | + var allStationList = gb_data_basic.stationRoutes(lineCode); | |
| 70 | + //站点路由 | |
| 71 | + var routeArray = gb_common.groupBy(allStationList, 'directions'); | |
| 72 | + //下行倒序 | |
| 73 | + routeArray[1].sort(function (a, b) { | |
| 74 | + return b.stationRouteCode - a.stationRouteCode; | |
| 75 | + }); | |
| 76 | + $('.station-list-wrap', modal).append(template('svg-edit-station-list-temp', {list: routeArray})); | |
| 77 | + | |
| 78 | + $('.station-item', modal).on('click', function () { | |
| 79 | + if ($(this).hasClass('disable')) { | |
| 80 | + $(this).removeClass('disable'); | |
| 81 | + } | |
| 82 | + else | |
| 83 | + $(this).addClass('disable'); | |
| 84 | + }); | |
| 85 | + | |
| 86 | + //上下行所有的站点名称 | |
| 87 | + var nameMap = {}; | |
| 88 | + $.each(allStationList, function () { | |
| 89 | + nameMap[this.stationName] = 1; | |
| 90 | + }); | |
| 91 | + names = gb_common.get_keys(nameMap).sort(function (a, b) { | |
| 92 | + return a.localeCompare(b); | |
| 93 | + }); | |
| 94 | + | |
| 95 | + //获取配置信息 | |
| 96 | + var svgAttr = gb_data_basic.getSvgAttr(lineCode); | |
| 97 | + var hideStations = svgAttr.hideStations; | |
| 98 | + //disable | |
| 99 | + $('.station-list-wrap .station-item', modal).each(function () { | |
| 100 | + var code = $(this).data('code'); | |
| 101 | + if (hideStations.indexOf(code) != -1) { | |
| 102 | + $(this).addClass('disable'); | |
| 103 | + } | |
| 104 | + }); | |
| 105 | + //rename items | |
| 106 | + var nicknames = svgAttr.nicknames; | |
| 107 | + for (var n in nicknames) { | |
| 108 | + addRenameItem(function ($e) { | |
| 109 | + $e.find('select').val(n); | |
| 110 | + $e.find('input[type=text]').val(nicknames[n]); | |
| 111 | + }); | |
| 112 | + } | |
| 113 | + }); | |
| 114 | + | |
| 115 | + var addRenameItem = function (cb) { | |
| 116 | + var htmlStr = template('svg-edit-rename-item-temp', {names: names, no: no}); | |
| 117 | + var $e = $(htmlStr); | |
| 118 | + $('.rename-list-form', modal).append($e); | |
| 119 | + no++; | |
| 120 | + cb && cb($e); | |
| 121 | + }; | |
| 122 | + | |
| 123 | + //add rename item | |
| 124 | + $('.rename-tools .add', modal).on('click', addRenameItem); | |
| 125 | + | |
| 126 | + //remove rename item | |
| 127 | + $('.rename-tools .minus', modal).on('click', function () { | |
| 128 | + $('.rename-item-panel.active', modal).remove(); | |
| 129 | + }); | |
| 130 | + | |
| 131 | + //check | |
| 132 | + $(modal).on('click', '.rename-item-panel input[type=checkbox]', function () { | |
| 133 | + if ($(this)[0].checked) { | |
| 134 | + $(this).parent().addClass('active'); | |
| 135 | + } | |
| 136 | + else { | |
| 137 | + $(this).parent().removeClass('active'); | |
| 138 | + } | |
| 139 | + }); | |
| 140 | + | |
| 141 | + //select | |
| 142 | + $(modal).on('change', '.rename-item-panel select', function () { | |
| 143 | + $(this).nextAll('input').val($(this).val()); | |
| 144 | + }); | |
| 145 | + | |
| 146 | + | |
| 147 | + //提交 | |
| 148 | + $(modal).on('click', '.submitBtn', function () { | |
| 149 | + //重命名数据 | |
| 150 | + var tempData = $('.rename-list-form', modal).serializeJSON().renames; | |
| 151 | + var renameData = {}; | |
| 152 | + $.each(gb_common.get_vals(tempData), function () { | |
| 153 | + if (!$.trim(this.nickname) || this.name == this.nickname) | |
| 154 | + return true; | |
| 155 | + renameData[this.name] = this.nickname; | |
| 156 | + }); | |
| 157 | + | |
| 158 | + //被禁选的站点 | |
| 159 | + var disableStation = []; | |
| 160 | + $('.station-list-wrap .station-item.disable', modal).each(function () { | |
| 161 | + disableStation.push($(this).data('code')); | |
| 162 | + }); | |
| 163 | + | |
| 164 | + var data = { | |
| 165 | + lineCode: lineCode, | |
| 166 | + hideStations: disableStation, | |
| 167 | + nicknames: renameData | |
| 168 | + }; | |
| 169 | + | |
| 170 | + gb_common.$post('/realSchedule/svgAttr', {jsonStr: JSON.stringify(data)}, function (rs) { | |
| 171 | + if (rs.t) { | |
| 172 | + gb_data_basic.setSvgAttr(rs.t); | |
| 173 | + //重新绘制模拟图 | |
| 174 | + var lineCode = rs.t.lineCode; | |
| 175 | + var wrap = $('#home-main-content .home-line-card[data-line-code='+lineCode+'] .svg-chart-wrap'); | |
| 176 | + wrap.find('svg.line-chart').remove(); | |
| 177 | + gb_svg_chart.draw_line(lineCode, wrap, true); | |
| 178 | + | |
| 179 | + UIkit.modal(modal).hide(); | |
| 180 | + } | |
| 181 | + }); | |
| 182 | + }); | |
| 183 | + })(); | |
| 184 | + </script> | |
| 185 | +</div> | ... | ... |
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/bc_type_major.html
| ... | ... | @@ -35,6 +35,19 @@ |
| 35 | 35 | </div> |
| 36 | 36 | </div> |
| 37 | 37 | </div> |
| 38 | + | |
| 39 | + <div class="uk-grid"> | |
| 40 | + <div class="uk-width-1-2"> | |
| 41 | + <div class="uk-form-row"> | |
| 42 | + <div class="uk-form-controls" style="margin-left: 0;"> | |
| 43 | + <label style="color: #827f7f;font-size: 13px;"> | |
| 44 | + <input class="i-cbox" type="checkbox" name="sendDirective" checked> | |
| 45 | + 下发调度指令 | |
| 46 | + </label> | |
| 47 | + </div> | |
| 48 | + </div> | |
| 49 | + </div> | |
| 50 | + </div> | |
| 38 | 51 | <div class="uk-modal-footer uk-text-right" style="margin-bottom: -20px;"> |
| 39 | 52 | <button type="button" class="uk-button uk-modal-close">取消</button> |
| 40 | 53 | <button type="submit" class="uk-button uk-button-primary"><i class="uk-icon-send"></i> 确认调整并下发指令 |
| ... | ... | @@ -48,10 +61,19 @@ |
| 48 | 61 | var modal = '#bctype-major-modal' |
| 49 | 62 | , sch, stationRoutes, parentModal; |
| 50 | 63 | |
| 64 | + $('[name=sendDirective]', modal).on('click', function () { | |
| 65 | + if ($(this)[0].checked) | |
| 66 | + $('[type=submit]', modal).html('<i class="uk-icon-send"></i> 确认调整并下发指令'); | |
| 67 | + else | |
| 68 | + $('[type=submit]', modal).html('<i class="uk-icon-check"></i> 确认调整'); | |
| 69 | + }); | |
| 70 | + | |
| 71 | + | |
| 51 | 72 | $('[name=startStation],[name=endStation]', modal).on('change', refreshDirectiveStr); |
| 52 | 73 | |
| 53 | 74 | |
| 54 | 75 | var remarks; |
| 76 | + | |
| 55 | 77 | function refreshDirectiveStr() { |
| 56 | 78 | |
| 57 | 79 | var $qdz = $('[name=startStation]') |
| ... | ... | @@ -61,20 +83,20 @@ |
| 61 | 83 | , zdzName = $zdz.find("option:selected").text(); |
| 62 | 84 | |
| 63 | 85 | //只修改起点 |
| 64 | - if(sch.qdzCode != $qdz.val() && sch.zdzCode == $zdz.val()){ | |
| 65 | - remarks = ' 从 '+ sch.qdzName +' 待客至 ' + qdzName + ' ,放站至 ' + zdzName; | |
| 86 | + if (sch.qdzCode != $qdz.val() && sch.zdzCode == $zdz.val()) { | |
| 87 | + remarks = ' 从 ' + sch.qdzName + ' 待客至 ' + qdzName + ' ,放站至 ' + zdzName; | |
| 66 | 88 | } |
| 67 | 89 | //只修改终点 |
| 68 | - else if(sch.qdzCode == $qdz.val() && sch.zdzCode != $zdz.val()){ | |
| 69 | - remarks = ' 从 '+ sch.qdzName +' 放站至 ' + zdzName + ' 开始待客'; | |
| 90 | + else if (sch.qdzCode == $qdz.val() && sch.zdzCode != $zdz.val()) { | |
| 91 | + remarks = ' 从 ' + sch.qdzName + ' 放站至 ' + zdzName + ' 开始待客'; | |
| 70 | 92 | } |
| 71 | 93 | //起终点都改变 |
| 72 | - else if(sch.qdzCode != $qdz.val() && sch.zdzCode != $zdz.val()){ | |
| 73 | - remarks = ' 从 '+ qdzName +' 放站至 ' + zdzName + ' 开始待客'; | |
| 94 | + else if (sch.qdzCode != $qdz.val() && sch.zdzCode != $zdz.val()) { | |
| 95 | + remarks = ' 从 ' + qdzName + ' 放站至 ' + zdzName + ' 开始待客'; | |
| 74 | 96 | } |
| 75 | 97 | //起终点都不改变 |
| 76 | - else if(sch.qdzCode == $qdz.val() && sch.zdzCode == $zdz.val()){ | |
| 77 | - remarks = ' 从 '+ qdzName +' 放站至 ' + zdzName; | |
| 98 | + else if (sch.qdzCode == $qdz.val() && sch.zdzCode == $zdz.val()) { | |
| 99 | + remarks = ' 从 ' + qdzName + ' 放站至 ' + zdzName; | |
| 78 | 100 | } |
| 79 | 101 | |
| 80 | 102 | $('[name=directiveStr]', modal).text('班次:' + sch.dfsj + remarks).trigger('input'); |
| ... | ... | @@ -117,16 +139,21 @@ |
| 117 | 139 | f.on('success.form.fv', function (e) { |
| 118 | 140 | e.preventDefault(); |
| 119 | 141 | var data = $(this).serializeJSON(); |
| 120 | - // notify_wait('准备下发指令') | |
| 121 | - //下发指令 | |
| 122 | - $.post('/directive/phrase', {nbbm: sch.clZbh, text: data.directiveStr}, function (rs) { | |
| 123 | - if (rs == 0) { | |
| 124 | - notify_succ('指令下发成功'); | |
| 125 | - changeBcType(); | |
| 126 | - } | |
| 127 | - else | |
| 128 | - notify_err('指令下发失败'); | |
| 129 | - }); | |
| 142 | + | |
| 143 | + var isSend = $('[name=sendDirective]', modal)[0].checked; | |
| 144 | + if (isSend) { | |
| 145 | + //下发指令 | |
| 146 | + $.post('/directive/phrase', {nbbm: sch.clZbh, text: data.directiveStr}, function (rs) { | |
| 147 | + if (rs == 0) { | |
| 148 | + notify_succ('指令下发成功'); | |
| 149 | + changeBcType(); | |
| 150 | + } | |
| 151 | + else | |
| 152 | + notify_err('指令下发失败'); | |
| 153 | + }); | |
| 154 | + } | |
| 155 | + else | |
| 156 | + changeBcType(); | |
| 130 | 157 | }); |
| 131 | 158 | |
| 132 | 159 | //站点路由 |
| ... | ... | @@ -146,7 +173,10 @@ |
| 146 | 173 | |
| 147 | 174 | function changeBcType() { |
| 148 | 175 | //将班次类型调整为放站 |
| 149 | - gb_common.$post('/realSchedule/changeBcType/'+sch.id, {bcType: 'major', remarks: remarks}, function(rs){ | |
| 176 | + gb_common.$post('/realSchedule/changeBcType/' + sch.id, { | |
| 177 | + bcType: 'major', | |
| 178 | + remarks: remarks | |
| 179 | + }, function (rs) { | |
| 150 | 180 | UIkit.modal(modal).hide(); |
| 151 | 181 | gb_schedule_table.updateSchedule(rs.t); |
| 152 | 182 | //触发父容器刷新事件 | ... | ... |
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/bc_type_venting.html
| ... | ... | @@ -23,6 +23,7 @@ |
| 23 | 23 | </div> |
| 24 | 24 | </div> |
| 25 | 25 | </div> |
| 26 | + | |
| 26 | 27 | <div class="uk-grid"> |
| 27 | 28 | <div class="uk-width-1-1"> |
| 28 | 29 | <div class="uk-form-row ct-stacked"> |
| ... | ... | @@ -35,6 +36,18 @@ |
| 35 | 36 | </div> |
| 36 | 37 | </div> |
| 37 | 38 | </div> |
| 39 | + <div class="uk-grid"> | |
| 40 | + <div class="uk-width-1-2"> | |
| 41 | + <div class="uk-form-row"> | |
| 42 | + <div class="uk-form-controls" style="margin-left: 0;"> | |
| 43 | + <label style="color: #827f7f;font-size: 13px;"> | |
| 44 | + <input class="i-cbox" type="checkbox" name="sendDirective" checked> | |
| 45 | + 下发调度指令 | |
| 46 | + </label> | |
| 47 | + </div> | |
| 48 | + </div> | |
| 49 | + </div> | |
| 50 | + </div> | |
| 38 | 51 | <div class="uk-modal-footer uk-text-right" style="margin-bottom: -20px;"> |
| 39 | 52 | <button type="button" class="uk-button uk-modal-close">取消</button> |
| 40 | 53 | <button type="submit" class="uk-button uk-button-primary"><i class="uk-icon-send"></i> 确认调整并下发指令 |
| ... | ... | @@ -48,6 +61,13 @@ |
| 48 | 61 | var modal = '#bctype-venting-modal' |
| 49 | 62 | , sch, stationRoutes, parentModal; |
| 50 | 63 | |
| 64 | + $('[name=sendDirective]', modal).on('click', function () { | |
| 65 | + if ($(this)[0].checked) | |
| 66 | + $('[type=submit]', modal).html('<i class="uk-icon-send"></i> 确认调整并下发指令'); | |
| 67 | + else | |
| 68 | + $('[type=submit]', modal).html('<i class="uk-icon-check"></i> 确认调整'); | |
| 69 | + }); | |
| 70 | + | |
| 51 | 71 | $('[name=startStation],[name=endStation]', modal).on('change', refreshDirectiveStr); |
| 52 | 72 | |
| 53 | 73 | |
| ... | ... | @@ -116,16 +136,20 @@ |
| 116 | 136 | f.on('success.form.fv', function (e) { |
| 117 | 137 | e.preventDefault(); |
| 118 | 138 | var data = $(this).serializeJSON(); |
| 119 | - // notify_wait('准备下发指令') | |
| 120 | - //下发指令 | |
| 121 | - $.post('/directive/phrase', {nbbm: sch.clZbh, text: data.directiveStr}, function (rs) { | |
| 122 | - if (rs == 0) { | |
| 123 | - notify_succ('指令下发成功'); | |
| 124 | - changeBcType(); | |
| 125 | - } | |
| 126 | - else | |
| 127 | - notify_err('指令下发失败'); | |
| 128 | - }); | |
| 139 | + var isSend = $('[name=sendDirective]', modal)[0].checked; | |
| 140 | + if (isSend) { | |
| 141 | + //下发指令 | |
| 142 | + $.post('/directive/phrase', {nbbm: sch.clZbh, text: data.directiveStr}, function (rs) { | |
| 143 | + if (rs == 0) { | |
| 144 | + notify_succ('指令下发成功'); | |
| 145 | + changeBcType(); | |
| 146 | + } | |
| 147 | + else | |
| 148 | + notify_err('指令下发失败'); | |
| 149 | + }); | |
| 150 | + } | |
| 151 | + else | |
| 152 | + changeBcType(); | |
| 129 | 153 | }); |
| 130 | 154 | |
| 131 | 155 | ... | ... |
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/dftz.html
| ... | ... | @@ -122,24 +122,26 @@ |
| 122 | 122 | |
| 123 | 123 | //班次类型字典 |
| 124 | 124 | var bctypes=dictionaryUtils.getByGroup('ScheduleType') |
| 125 | - ,opts='<option value="'+sch.bcType+'">'+bctypes[sch.bcType]+'</option>'; | |
| 126 | - if(sch.bcType!='normal') | |
| 127 | - $('select[name=bcType]', modal).attr('disabled','disabled'); | |
| 125 | + ,opts=''; | |
| 126 | + | |
| 127 | + if(sch.bcType == 'out' || sch.bcType == 'in'){ | |
| 128 | + $('[name=bcType]', modal).html('<option value="'+sch.bcType+'">'+bctypes[sch.bcType]+'</option>'); | |
| 129 | + } | |
| 128 | 130 | else{ |
| 129 | 131 | for(var code in bctypes){ |
| 130 | - if(code!='venting' && code!='major') | |
| 132 | + if(code!='venting' && code!='major' && code != 'normal') | |
| 131 | 133 | continue; |
| 132 | 134 | opts+='<option value="'+code+'">'+bctypes[code]+'</option>'; |
| 133 | 135 | } |
| 136 | + $('[name=bcType]', modal).html(opts).val(sch.bcType); | |
| 134 | 137 | } |
| 135 | - $('[name=bcType]', modal).html(opts); | |
| 136 | 138 | |
| 137 | 139 | //submit |
| 138 | 140 | var f = $('form', modal).formValidation(gb_form_validation_opts); |
| 139 | 141 | f.on('success.form.fv', function(e) { |
| 140 | 142 | e.preventDefault(); |
| 141 | 143 | var data = $(this).serializeJSON(); |
| 142 | - if(data.dfsj==sch.dfsj && data.remarks==''){ | |
| 144 | + if(data.dfsj==sch.dfsj && data.remarks=='' && data.bcType == sch.bcType){ | |
| 143 | 145 | return; |
| 144 | 146 | } |
| 145 | 147 | gb_common.$post('/realSchedule/outgoAdjust', data, function(rs){ | ... | ... |
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/fcxxwt.html
| ... | ... | @@ -129,6 +129,28 @@ |
| 129 | 129 | </div> |
| 130 | 130 | </div> |
| 131 | 131 | |
| 132 | + <hr style="height: 1px;border: none;border-top: 1px dashed #d1d1d1;width: calc(100% + 40px);margin-left: -20px;"> | |
| 133 | + <div class="uk-grid"> | |
| 134 | + <div class="uk-width-1-2"> | |
| 135 | + <div class="uk-form-row"> | |
| 136 | + <label class="uk-form-label" >里程</label> | |
| 137 | + <div class="uk-form-controls"> | |
| 138 | + <input type="text" value="{{if sch.status==-1}}0{{else}}{{sch.jhlc}}{{/if}}" name="jhlc" readonly> | |
| 139 | + </div> | |
| 140 | + </div> | |
| 141 | + </div> | |
| 142 | + <div class="uk-width-1-2"> | |
| 143 | + <div class="uk-form-row"> | |
| 144 | + <div class="uk-form-controls" style="margin-left: 0;margin-top: 9px;"> | |
| 145 | + <label> | |
| 146 | + <input class="i-cbox destroy-box" type="checkbox" name="status" value="-1" {{if sch.status==-1}}checked disabled{{/if}}> | |
| 147 | + 是否烂班 | |
| 148 | + </label> | |
| 149 | + </div> | |
| 150 | + </div> | |
| 151 | + </div> | |
| 152 | + </div> | |
| 153 | + | |
| 132 | 154 | <div class="uk-modal-footer uk-text-right" style="margin-bottom: -20px;"> |
| 133 | 155 | <button type="button" class="uk-button uk-modal-close">取消</button> |
| 134 | 156 | <button type="submit" class="uk-button uk-button-primary"><i class="uk-icon-check"></i> 保存</button> |
| ... | ... | @@ -153,6 +175,11 @@ |
| 153 | 175 | e.preventDefault(); |
| 154 | 176 | var data = $(this).serializeJSON(); |
| 155 | 177 | |
| 178 | + if(data.status==-1 && !data.adjustExps){ | |
| 179 | + notify_err("烂班需要选择调整原因!"); | |
| 180 | + return; | |
| 181 | + } | |
| 182 | + | |
| 156 | 183 | gb_common.$post('/realSchedule/schInfoFineTune', data, function(rs){ |
| 157 | 184 | gb_schedule_table.updateSchedule(rs.ts); |
| 158 | 185 | UIkit.modal(modal).hide(); |
| ... | ... | @@ -163,17 +190,23 @@ |
| 163 | 190 | }); |
| 164 | 191 | |
| 165 | 192 | //班次类型 |
| 166 | - if(sch.bcType!='normal') | |
| 167 | - $('select[name=bcType]', f).attr('disabled','disabled'); | |
| 168 | - else { | |
| 169 | - //正常班次只能改为直放 和 放大站 | |
| 170 | - $('select[name=bcType] option', f).each(function(){ | |
| 171 | - var whiteList=['venting', 'major', sch.bcType]; | |
| 172 | - if(whiteList.indexOf($(this).val()) == -1) | |
| 173 | - $(this).remove(); | |
| 174 | - }); | |
| 193 | + $('select[name=bcType] option', f).each(function(){ | |
| 194 | + var whiteList=['venting', 'major', 'normal', sch.bcType]; | |
| 195 | + if(whiteList.indexOf($(this).val()) == -1) | |
| 196 | + $(this).remove(); | |
| 197 | + }); | |
| 198 | + if(sch.bcType == 'out' || sch.bcType == 'in'){ | |
| 199 | + $('[name=bcType]', f).attr('disabled', 'disabled'); | |
| 175 | 200 | } |
| 176 | 201 | |
| 202 | + //是否烂班 | |
| 203 | + $('.destroy-box', f).on('click', function () { | |
| 204 | + if($(this)[0].checked) | |
| 205 | + $('input[name=jhlc]', f).val(0); | |
| 206 | + else | |
| 207 | + $('input[name=jhlc]', f).val(sch.jhlc); | |
| 208 | + }); | |
| 209 | + | |
| 177 | 210 | $('[name=adjustExps]', f).on('change', function(){ |
| 178 | 211 | var rem=$('[name=remarks]', f); |
| 179 | 212 | rem.val(rem.val() + $(this).val() + ',').trigger('input'); | ... | ... |
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/lj_zrw.html
| ... | ... | @@ -320,6 +320,16 @@ |
| 320 | 320 | }, modal_opts); |
| 321 | 321 | }; |
| 322 | 322 | |
| 323 | + //出场子任务 | |
| 324 | + var add_sub_task_out = function () { | |
| 325 | + var sch = getActiveSch(); | |
| 326 | + if (!sch) | |
| 327 | + return notify_err('无法获取到主任务信息!'); | |
| 328 | + open_modal(folder + '/sub_task/add_sub_task_outpark.html', { | |
| 329 | + sch: sch | |
| 330 | + }, modal_opts); | |
| 331 | + }; | |
| 332 | + | |
| 323 | 333 | //删除子任务 |
| 324 | 334 | var remove_sub_task = function () { |
| 325 | 335 | var activeDl = $(s_t_body, modal).find('dl.context-menu-active'); |
| ... | ... | @@ -347,7 +357,8 @@ |
| 347 | 357 | remove_sch: remove_sch, |
| 348 | 358 | add_sub_task_other: add_sub_task_other, |
| 349 | 359 | add_sub_task_in: add_sub_task_in, |
| 350 | - remove_sub_task: remove_sub_task | |
| 360 | + remove_sub_task: remove_sub_task, | |
| 361 | + add_sub_task_out: add_sub_task_out | |
| 351 | 362 | }; |
| 352 | 363 | |
| 353 | 364 | //右键菜单 |
| ... | ... | @@ -368,7 +379,10 @@ |
| 368 | 379 | name: '回场' |
| 369 | 380 | }, |
| 370 | 381 | 'add_sub_task_out': { |
| 371 | - name: '出场', | |
| 382 | + name: '出场' | |
| 383 | + }, | |
| 384 | + 'add_sub_task_range_turn': { | |
| 385 | + name: '区间掉头', | |
| 372 | 386 | disabled: true |
| 373 | 387 | }, |
| 374 | 388 | 'add_sub_task_other': { | ... | ... |
src/main/resources/static/real_control_v2/fragments/line_schedule/context_menu/sub_task/add_sub_task_outpark.html
0 → 100644
| 1 | +<div class="uk-modal" id="add-sub-task-inpark-modal"> | |
| 2 | + <div class="uk-modal-dialog"> | |
| 3 | + <a href="" class="uk-modal-close uk-close"></a> | |
| 4 | + <div class="uk-modal-header"> | |
| 5 | + <h2>出场子任务</h2></div> | |
| 6 | + | |
| 7 | + <div style="width: 100%;padding-left: 1%;"> | |
| 8 | + <div class="sub-task-card"> | |
| 9 | + <div class="uk-panel uk-panel-box uk-panel-box-secondary"> | |
| 10 | + <div class="uk-panel-badge uk-badge uk-badge-default">空驶</div> | |
| 11 | + <h3 class="uk-panel-title">出场</h3> | |
| 12 | + <form class="uk-form uk-form-horizontal inpark_form" empty_form> | |
| 13 | + <input type="hidden" name="type2" value="3"> | |
| 14 | + <input type="hidden" name="mileageType" value="empty"> | |
| 15 | + <div class="uk-grid"> | |
| 16 | + <div class="uk-width-3-10"> | |
| 17 | + <div class="uk-form-row"> | |
| 18 | + <label class="uk-form-label">班次类型 </label> | |
| 19 | + </div> | |
| 20 | + </div> | |
| 21 | + <div class="uk-width-7-10 pl5"> | |
| 22 | + <select name="type1" class="ct_focus"> | |
| 23 | + <option value="正常">正常</option> | |
| 24 | + <option value="临加">临加</option> | |
| 25 | + </select> | |
| 26 | + </div> | |
| 27 | + </div> | |
| 28 | + <div class="uk-grid"> | |
| 29 | + <div class="uk-width-3-10"> | |
| 30 | + <div class="uk-form-row"> | |
| 31 | + <label class="uk-form-label">起点 </label> | |
| 32 | + </div> | |
| 33 | + </div> | |
| 34 | + <div class="uk-width-7-10 pl5"> | |
| 35 | + <select name="startStation"></select> | |
| 36 | + </div> | |
| 37 | + </div> | |
| 38 | + <div class="uk-grid"> | |
| 39 | + <div class="uk-width-3-10"> | |
| 40 | + <div class="uk-form-row"> | |
| 41 | + <label class="uk-form-label" disabled>终点 </label> | |
| 42 | + </div> | |
| 43 | + </div> | |
| 44 | + <div class="uk-width-7-10 pl5"> | |
| 45 | + <select name="endStation" class="ct_focus" disabled></select> | |
| 46 | + </div> | |
| 47 | + </div> | |
| 48 | + <div class="uk-grid"> | |
| 49 | + <div class="uk-width-3-10"> | |
| 50 | + <div class="uk-form-row"> | |
| 51 | + <label class="uk-form-label">空驶里程</label> | |
| 52 | + </div> | |
| 53 | + </div> | |
| 54 | + <div class="uk-width-7-10 pl5"> | |
| 55 | + <input type="text" name="mileage" required style="width: calc(100% - 62px);"> | |
| 56 | + <a style="font-size: 12px;color: grey;cursor: default;" target="_blank" | |
| 57 | + class="linkToLineInfo">线路标准</a> | |
| 58 | + </div> | |
| 59 | + </div> | |
| 60 | + <div class="uk-grid"> | |
| 61 | + <div class="uk-width-3-10"> | |
| 62 | + <div class="uk-form-row"> | |
| 63 | + <label class="uk-form-label">开始时间</label> | |
| 64 | + </div> | |
| 65 | + </div> | |
| 66 | + <div class="uk-width-7-10 pl5"> | |
| 67 | + <input type="time" name="startDate" required> | |
| 68 | + </div> | |
| 69 | + </div> | |
| 70 | + <div class="uk-grid"> | |
| 71 | + <div class="uk-width-3-10"> | |
| 72 | + <div class="uk-form-row"> | |
| 73 | + <label class="uk-form-label">结束时间</label> | |
| 74 | + </div> | |
| 75 | + </div> | |
| 76 | + <div class="uk-width-7-10 pl5"> | |
| 77 | + <input type="time" name="endDate" required> | |
| 78 | + </div> | |
| 79 | + </div> | |
| 80 | + </form> | |
| 81 | + </div> | |
| 82 | + </div> | |
| 83 | + | |
| 84 | + <div class="sub-task-card"> | |
| 85 | + <div class="uk-panel uk-panel-box uk-panel-box-primary"> | |
| 86 | + <div class="uk-panel-badge uk-badge">营运</div> | |
| 87 | + <h3 class="uk-panel-title">线路上站点间</h3> | |
| 88 | + <form class="uk-form uk-form-horizontal inpark_form" service_form> | |
| 89 | + <input type="hidden" name="type2" value="1"> | |
| 90 | + <input type="hidden" name="mileageType" value="service"> | |
| 91 | + <div class="uk-grid"> | |
| 92 | + <div class="uk-width-3-10"> | |
| 93 | + <div class="uk-form-row"> | |
| 94 | + <label class="uk-form-label">班次类型 </label> | |
| 95 | + </div> | |
| 96 | + </div> | |
| 97 | + <div class="uk-width-7-10 pl5"> | |
| 98 | + <select name="type1" class="ct_focus" disabled> | |
| 99 | + <option value="正常">正常</option> | |
| 100 | + <option value="临加">临加</option> | |
| 101 | + </select> | |
| 102 | + </div> | |
| 103 | + </div> | |
| 104 | + <div class="uk-grid"> | |
| 105 | + <div class="uk-width-3-10"> | |
| 106 | + <div class="uk-form-row"> | |
| 107 | + <label class="uk-form-label">起点 </label> | |
| 108 | + </div> | |
| 109 | + </div> | |
| 110 | + <div class="uk-width-7-10 pl5"> | |
| 111 | + <select name="startStation" disabled></select> | |
| 112 | + </div> | |
| 113 | + </div> | |
| 114 | + <div class="uk-grid"> | |
| 115 | + <div class="uk-width-3-10"> | |
| 116 | + <div class="uk-form-row"> | |
| 117 | + <label class="uk-form-label">终点 </label> | |
| 118 | + </div> | |
| 119 | + </div> | |
| 120 | + <div class="uk-width-7-10 pl5"> | |
| 121 | + <select name="endStation" class="ct_focus" disabled></select> | |
| 122 | + </div> | |
| 123 | + </div> | |
| 124 | + <div class="uk-grid"> | |
| 125 | + <div class="uk-width-3-10"> | |
| 126 | + <div class="uk-form-row"> | |
| 127 | + <label class="uk-form-label">营运里程</label> | |
| 128 | + </div> | |
| 129 | + </div> | |
| 130 | + <div class="uk-width-7-10 pl5"> | |
| 131 | + <input type="text" name="mileage" disabled> | |
| 132 | + </div> | |
| 133 | + </div> | |
| 134 | + <div class="uk-grid"> | |
| 135 | + <div class="uk-width-3-10"> | |
| 136 | + <div class="uk-form-row"> | |
| 137 | + <label class="uk-form-label">开始时间</label> | |
| 138 | + </div> | |
| 139 | + </div> | |
| 140 | + <div class="uk-width-7-10 pl5"> | |
| 141 | + <input type="time" name="startDate" disabled> | |
| 142 | + </div> | |
| 143 | + </div> | |
| 144 | + <div class="uk-grid"> | |
| 145 | + <div class="uk-width-3-10"> | |
| 146 | + <div class="uk-form-row"> | |
| 147 | + <label class="uk-form-label">结束时间</label> | |
| 148 | + </div> | |
| 149 | + </div> | |
| 150 | + <div class="uk-width-7-10 pl5"> | |
| 151 | + <input type="time" name="endDate" disabled> | |
| 152 | + </div> | |
| 153 | + </div> | |
| 154 | + </form> | |
| 155 | + </div> | |
| 156 | + </div> | |
| 157 | + | |
| 158 | + <form class="uk-form" style="margin-top: 15px; padding: 0 10px 0 0;"> | |
| 159 | + <textarea placeholder="备注" style="width: 100%;height: 70px;" id="globalRemarks"></textarea> | |
| 160 | + </form> | |
| 161 | + </div> | |
| 162 | + | |
| 163 | + <div class="uk-modal-footer uk-text-right"> | |
| 164 | + <button type="button" class="uk-button uk-modal-close">取消</button> | |
| 165 | + <button type="button" class="uk-button uk-button-primary" id="submitChildTaskBtn">提交子任务</button> | |
| 166 | + </div> | |
| 167 | + </div> | |
| 168 | + | |
| 169 | + <div class="ct-bottom-drawer"> | |
| 170 | + <div class="ct-bottom-drawer-body"></div> | |
| 171 | + </div> | |
| 172 | + | |
| 173 | + <script id="sub-task-inpark-form-temp" type="text/html"> | |
| 174 | + </script> | |
| 175 | + | |
| 176 | + <script> | |
| 177 | + (function () { | |
| 178 | + var modal = '#add-sub-task-inpark-modal', | |
| 179 | + serviceForm = $('form[service_form]', modal), | |
| 180 | + emptyForm = $('form[empty_form]', modal), | |
| 181 | + sch, stationRoutes, parks, information, esCode; | |
| 182 | + $(modal).on('init', function (e, data) { | |
| 183 | + sch = data.sch; | |
| 184 | + $('.linkToLineInfo', modal).attr('href', '/pages/base/lineinformation/list.html?no=' + gb_data_basic.codeToLine[sch.xlBm].id); | |
| 185 | + | |
| 186 | + //站点路由 | |
| 187 | + stationRoutes = gb_common.groupBy(gb_data_basic.stationRoutes(sch.xlBm).sort(function (a, b) { | |
| 188 | + return a.stationRouteCode - b.stationRouteCode; | |
| 189 | + }), 'directions')[sch.xlDir]; | |
| 190 | + //空驶起点(停车场) | |
| 191 | + $.get('/basic/parks', function (rs) { | |
| 192 | + parks = rs; | |
| 193 | + var opts = ''; | |
| 194 | + for (var code in parks) { | |
| 195 | + opts += '<option value="' + code + '">' + parks[code] + '</option>'; | |
| 196 | + } | |
| 197 | + $('select[name=startStation]', emptyForm).html(opts).val(information.carPark); | |
| 198 | + | |
| 199 | + //设置默认值 | |
| 200 | + setDefaultVal(); | |
| 201 | + }); | |
| 202 | + //线路标准 | |
| 203 | + information = gb_data_basic.getLineInformation(sch.xlBm); | |
| 204 | + | |
| 205 | + //出场开始时间改变 | |
| 206 | + $('input[name=startDate]', emptyForm).on('change input', function () { | |
| 207 | + var st = moment($(this).val(), 'HH:mm') | |
| 208 | + , time = getOutTime(); | |
| 209 | + if (!time) | |
| 210 | + return; | |
| 211 | + | |
| 212 | + var ets = st.add(time, 'minute').format('HH:mm'); | |
| 213 | + $('input[name=endDate]', emptyForm).val(ets); | |
| 214 | + }); | |
| 215 | + //出场结束时间改变 | |
| 216 | + $('input[name=endDate]', emptyForm).on('change input', function () { | |
| 217 | + var et = moment($(this).val(), 'HH:mm'), time = getOutTime(); | |
| 218 | + if (!time) | |
| 219 | + return; | |
| 220 | + | |
| 221 | + var ets = et.subtract(time, 'minute').format('HH:mm'); | |
| 222 | + $('input[name=startDate]', emptyForm).val(ets); | |
| 223 | + }); | |
| 224 | + | |
| 225 | + var dataArray = []; | |
| 226 | + var fs = $('form.inpark_form', modal).formValidation({ | |
| 227 | + framework: 'uikit', | |
| 228 | + locale: 'zh_CN' | |
| 229 | + }); | |
| 230 | + fs.on('success.form.fv', function (e) { | |
| 231 | + e.preventDefault(); | |
| 232 | + if ($(this).is(':hidden')) | |
| 233 | + return; | |
| 234 | + dataArray.push($.extend($(this).serializeJSON(), getDisabledVal(this) | |
| 235 | + , {remarks: $('#globalRemarks', modal).val(), 'schedule.id': sch.id})); | |
| 236 | + $(this).data('valid', true); | |
| 237 | + | |
| 238 | + if (allValidSuccess()) { | |
| 239 | + var i = 0; | |
| 240 | + (function () { | |
| 241 | + var f = arguments.callee; | |
| 242 | + if (i >= dataArray.length) { | |
| 243 | + UIkit.modal(modal).hide(); | |
| 244 | + $('#schedule-lj_zrw-modal .main-schedule-table').trigger('refresh', {sch: sch}); | |
| 245 | + return; | |
| 246 | + } | |
| 247 | + var data = dataArray[i]; | |
| 248 | + gb_common.$post('/childTask', data, function (rs) { | |
| 249 | + notify_succ('子任务添加成功'); | |
| 250 | + gb_schedule_table.updateSchedule(rs.t); | |
| 251 | + i++; | |
| 252 | + f(); | |
| 253 | + }); | |
| 254 | + })(); | |
| 255 | + } | |
| 256 | + }); | |
| 257 | + | |
| 258 | + //校验不过 | |
| 259 | + fs.on('err.field.fv', function () { | |
| 260 | + $('#submitChildTaskBtn', modal).removeClass('disabled').removeAttr('disabled'); | |
| 261 | + }); | |
| 262 | + | |
| 263 | + //submit | |
| 264 | + $('#submitChildTaskBtn', modal).on('click', function () { | |
| 265 | + $(this).addClass('disabled').attr('disabled', 'disabled'); | |
| 266 | + dataArray = []; | |
| 267 | + fs.data('valid', false); | |
| 268 | + fs.formValidation('validate'); | |
| 269 | + //fs.submit(); | |
| 270 | + }); | |
| 271 | + }); | |
| 272 | + | |
| 273 | + /* function outUpOrDown() { | |
| 274 | + if (information.carPark != $('select[name=startStation]', emptyForm).val()) | |
| 275 | + return -1; | |
| 276 | + | |
| 277 | + return sch.xlDir; | |
| 278 | + }*/ | |
| 279 | + | |
| 280 | + function getOutTime() { | |
| 281 | + if (information.carPark != $('select[name=startStation]', emptyForm).val()) | |
| 282 | + return null; | |
| 283 | + | |
| 284 | + if (sch.xlDir == 0) | |
| 285 | + return information.upOutTimer; | |
| 286 | + else if (sch.xlDir == 1) | |
| 287 | + return information.downOutTimer; | |
| 288 | + } | |
| 289 | + | |
| 290 | + function allValidSuccess() { | |
| 291 | + var flag = true; | |
| 292 | + $('form.inpark_form:visible', modal).each(function (i, f) { | |
| 293 | + if (!$(f).data('valid')) { | |
| 294 | + flag = false; | |
| 295 | + return false; | |
| 296 | + } | |
| 297 | + }); | |
| 298 | + return flag; | |
| 299 | + } | |
| 300 | + | |
| 301 | + //获取表单disabled 项的值 | |
| 302 | + function getDisabledVal(f) { | |
| 303 | + var rs = {}; | |
| 304 | + $('input,select', f).each(function () { | |
| 305 | + if ($(this).attr('disabled')) { | |
| 306 | + rs[$(this).attr('name')] = $(this).val(); | |
| 307 | + } | |
| 308 | + }); | |
| 309 | + return rs; | |
| 310 | + } | |
| 311 | + | |
| 312 | + function setDefaultVal() { | |
| 313 | + var routeOpts = ''; | |
| 314 | + $.each(stationRoutes, function () { | |
| 315 | + routeOpts += '<option value="' + this.stationCode + '">' + this.stationName + '</option>'; | |
| 316 | + }); | |
| 317 | + esCode = stationRoutes[stationRoutes.length - 1].stationCode; | |
| 318 | + | |
| 319 | + //营运起终点 | |
| 320 | + $('select[name=startStation]', serviceForm).html(routeOpts).val(sch.qdzCode); | |
| 321 | + $('select[name=endStation]', serviceForm).html(routeOpts).val(sch.zdzCode); | |
| 322 | + //营运开始结束时间 | |
| 323 | + $('input[name=startDate]', serviceForm).val(sch.dfsj); | |
| 324 | + $('input[name=endDate]', serviceForm).val(sch.zdsj); | |
| 325 | + //营运里程 | |
| 326 | + $('input[name=mileage]', serviceForm).val(sch.jhlc); | |
| 327 | + //营运班次类型 | |
| 328 | + $('select[name=type1]', serviceForm).val(sch['sflj'] ? '临加' : '正常'); | |
| 329 | + | |
| 330 | + | |
| 331 | + //空驶终点 | |
| 332 | + $('select[name=endStation]', emptyForm).html(routeOpts).val(sch.qdzCode); | |
| 333 | + //出场结束时间 | |
| 334 | + var eDate = moment(sch.dfsj, 'HH:mm').subtract(5, 'minute').format('HH:mm'); | |
| 335 | + $('input[name=endDate]', emptyForm).val(eDate).trigger('change'); | |
| 336 | + //空驶里程 | |
| 337 | + $('input[name=mileage]', emptyForm).val(sch.xlDir == 0 ? information.upOutMileage : information.downOutMileage); | |
| 338 | + } | |
| 339 | + })(); | |
| 340 | + </script> | |
| 341 | +</div> | |
| 0 | 342 | \ No newline at end of file | ... | ... |
src/main/resources/static/real_control_v2/js/data/data_basic.js
| ... | ... | @@ -2,14 +2,15 @@ |
| 2 | 2 | |
| 3 | 3 | var gb_data_basic = (function () { |
| 4 | 4 | |
| 5 | - var stationRoutes, lineCode2NameAll, lineInformations, nbbm2deviceMap, allPersonnel; | |
| 6 | - var ep = EventProxy.create("stationRoutes", "lineCode2Name", "lineInformations", "nbbm2deviceId", "all_personnel" | |
| 7 | - , function (routes, code2Name, informations, nbbm2device, all_personnel) { | |
| 5 | + var stationRoutes, lineCode2NameAll, lineInformations, nbbm2deviceMap, allPersonnel, svgAttrs; | |
| 6 | + var ep = EventProxy.create("stationRoutes", "lineCode2Name", "lineInformations", "nbbm2deviceId", "all_personnel", "svg_attrs" | |
| 7 | + , function (routes, code2Name, informations, nbbm2device, all_personnel, svgAttrMap) { | |
| 8 | 8 | stationRoutes = routes; |
| 9 | 9 | lineCode2NameAll = code2Name; |
| 10 | 10 | lineInformations = informations; |
| 11 | 11 | nbbm2deviceMap = nbbm2device; |
| 12 | 12 | allPersonnel = all_personnel; |
| 13 | + svgAttrs = svgAttrMap; | |
| 13 | 14 | gb_main_ep.emitLater('data-basic'); |
| 14 | 15 | }); |
| 15 | 16 | |
| ... | ... | @@ -30,8 +31,13 @@ var gb_data_basic = (function () { |
| 30 | 31 | |
| 31 | 32 | //站点路由 |
| 32 | 33 | gb_common.$get('/stationroute/multiLine', {lineIds: line_idx}, function (rs) { |
| 33 | - var list = JSON.parse(rs.list); | |
| 34 | - ep.emit('stationRoutes', gb_common.groupBy(list, 'lineCode')); | |
| 34 | + var list = rs.list;//JSON.parse(rs.list); | |
| 35 | + var routeData = gb_common.groupBy(list, 'lineCode'); | |
| 36 | + //排序 | |
| 37 | + for (var lineCode in routeData) { | |
| 38 | + routeData[lineCode].sort(stationRouteSort); | |
| 39 | + } | |
| 40 | + ep.emit('stationRoutes', routeData); | |
| 35 | 41 | }); |
| 36 | 42 | |
| 37 | 43 | //线路标准信息 |
| ... | ... | @@ -47,13 +53,13 @@ var gb_data_basic = (function () { |
| 47 | 53 | //人员信息 |
| 48 | 54 | $.get('/basic/all_personnel', function (rs) { |
| 49 | 55 | //转换成自动补全组件需要的数据 |
| 50 | - var data=[],name; | |
| 51 | - for(var jobCode in rs){ | |
| 52 | - name=rs[jobCode]; | |
| 56 | + var data = [], name; | |
| 57 | + for (var jobCode in rs) { | |
| 58 | + name = rs[jobCode]; | |
| 53 | 59 | /*if(jobCode.indexOf("-")!=-1) |
| 54 | - jobCode=jobCode.split('-')[1];*/ | |
| 60 | + jobCode=jobCode.split('-')[1];*/ | |
| 55 | 61 | data.push({ |
| 56 | - value: jobCode+'/'+name, | |
| 62 | + value: jobCode + '/' + name, | |
| 57 | 63 | fullChars: pinyin.getFullChars(name).toUpperCase(), |
| 58 | 64 | camelChars: pinyin.getCamelChars(name) |
| 59 | 65 | }); |
| ... | ... | @@ -61,7 +67,7 @@ var gb_data_basic = (function () { |
| 61 | 67 | ep.emit('all_personnel', data); |
| 62 | 68 | }); |
| 63 | 69 | |
| 64 | - var carparks={}; | |
| 70 | + var carparks = {}; | |
| 65 | 71 | //停车场数据 |
| 66 | 72 | gb_common.$get('/realMap/carParkSpatialData', {}, function (rs) { |
| 67 | 73 | $.each(rs.list, function () { |
| ... | ... | @@ -71,7 +77,7 @@ var gb_data_basic = (function () { |
| 71 | 77 | |
| 72 | 78 | var getCarparkByCode = function (code) { |
| 73 | 79 | return carparks[code]; |
| 74 | - } | |
| 80 | + }; | |
| 75 | 81 | |
| 76 | 82 | //line code to name |
| 77 | 83 | $.get('/basic/lineCode2Name', function (rs) { |
| ... | ... | @@ -83,6 +89,17 @@ var gb_data_basic = (function () { |
| 83 | 89 | ep.emit('nbbm2deviceId', rs); |
| 84 | 90 | }); |
| 85 | 91 | |
| 92 | + //模拟图属性数据 | |
| 93 | + gb_common.$get('/realSchedule/svgAttr', {idx: line_idx}, function (rs) { | |
| 94 | + var data = {}; | |
| 95 | + $.each(rs.list, function () { | |
| 96 | + this.hideStations = JSON.parse(this.hideStations); | |
| 97 | + this.nicknames = JSON.parse(this.nicknames); | |
| 98 | + data[this.lineCode] = this; | |
| 99 | + }); | |
| 100 | + ep.emit('svg_attrs', data); | |
| 101 | + }); | |
| 102 | + | |
| 86 | 103 | function findLineByCodes(codeArr) { |
| 87 | 104 | var rs = []; |
| 88 | 105 | $.each(codeArr, function () { |
| ... | ... | @@ -98,11 +115,15 @@ var gb_data_basic = (function () { |
| 98 | 115 | } |
| 99 | 116 | |
| 100 | 117 | return null; |
| 101 | - } | |
| 118 | + }; | |
| 102 | 119 | |
| 103 | 120 | var getLineInformation = function (lineCode) { |
| 104 | 121 | return lineInformations[lineCode]; |
| 105 | - } | |
| 122 | + }; | |
| 123 | + | |
| 124 | + var stationRouteSort = function (a, b) { | |
| 125 | + return a.stationRouteCode - b.stationRouteCode; | |
| 126 | + }; | |
| 106 | 127 | //文件载入完毕 |
| 107 | 128 | res_load_ep.emitLater('load_data_basic'); |
| 108 | 129 | |
| ... | ... | @@ -125,6 +146,36 @@ var gb_data_basic = (function () { |
| 125 | 146 | return allPersonnel; |
| 126 | 147 | }, |
| 127 | 148 | findCodeByLinename: findCodeByLinename, |
| 128 | - getCarparkByCode: getCarparkByCode | |
| 149 | + getCarparkByCode: getCarparkByCode, | |
| 150 | + getSvgAttr: function (lineCode) { | |
| 151 | + return svgAttrs[lineCode]; | |
| 152 | + }, | |
| 153 | + setSvgAttr: function (attr) { | |
| 154 | + attr.hideStations = JSON.parse(attr.hideStations); | |
| 155 | + attr.nicknames = JSON.parse(attr.nicknames); | |
| 156 | + svgAttrs[attr.lineCode] = attr; | |
| 157 | + }, | |
| 158 | + //是否是环线 | |
| 159 | + isLoopLine: function (lineCode) { | |
| 160 | + var data = gb_common.groupBy(stationRoutes[lineCode], 'directions'); | |
| 161 | + //如果上行起终点名称相同,并且距离50米内 | |
| 162 | + var len = data[0].length; | |
| 163 | + if(len > 0){ | |
| 164 | + var first = data[0][0], | |
| 165 | + end = data[0][len - 1]; | |
| 166 | + | |
| 167 | + if(first.stationName != end.stationName) | |
| 168 | + return false; | |
| 169 | + | |
| 170 | + var fPoint = {latitude: first.station.gLaty, longitude: first.station.gLonx} | |
| 171 | + ,ePoint = {latitude: end.station.gLaty, longitude: end.station.gLonx}; | |
| 172 | + | |
| 173 | + if(geolib.getDistance(fPoint, ePoint) < 40){ | |
| 174 | + return true; | |
| 175 | + } | |
| 176 | + } | |
| 177 | + | |
| 178 | + return false; | |
| 179 | + } | |
| 129 | 180 | }; |
| 130 | 181 | })(); | ... | ... |
src/main/resources/static/real_control_v2/js/data/data_gps.js
| ... | ... | @@ -3,7 +3,7 @@ |
| 3 | 3 | var gb_data_gps = (function() { |
| 4 | 4 | |
| 5 | 5 | //fixed time refresh delay |
| 6 | - var delay = 1000 * 6; | |
| 6 | + var delay = 1000 * 5; | |
| 7 | 7 | //deviceId ——> gps |
| 8 | 8 | var realData = {}; |
| 9 | 9 | //refresh after callback |
| ... | ... | @@ -34,6 +34,7 @@ var gb_data_gps = (function() { |
| 34 | 34 | upArr = [], |
| 35 | 35 | upDownChange = []; |
| 36 | 36 | |
| 37 | + var schArray; | |
| 37 | 38 | $.each(rs, function() { |
| 38 | 39 | old = realData[this.deviceId]; |
| 39 | 40 | if (old) { |
| ... | ... | @@ -45,16 +46,26 @@ var gb_data_gps = (function() { |
| 45 | 46 | } else |
| 46 | 47 | addArr.push(this); |
| 47 | 48 | |
| 49 | + //班次信息 | |
| 50 | + if(this.schId){ | |
| 51 | + schArray=gb_schedule_table.findScheduleByLine(this.lineId); | |
| 52 | + if(schArray) | |
| 53 | + this.sch = schArray[this.schId]; | |
| 54 | + } | |
| 55 | + | |
| 48 | 56 | //时间格式化 |
| 49 | 57 | this.dateStr = moment(this.timestamp).format('YYYY-MM-DD HH:mm:ss'); |
| 58 | + //异常检测 | |
| 59 | + gb_gps_abnormal.check(this); | |
| 50 | 60 | realData[this.deviceId] = this; |
| 51 | 61 | }); |
| 52 | 62 | |
| 53 | - console.log('add array size: ' + addArr.length, 'up array size: ' + upArr.length); | |
| 63 | + //console.log('add array size: ' + addArr.length, 'up array size: ' + upArr.length); | |
| 54 | 64 | //CCCallFuncN |
| 55 | 65 | $.each(refreshEventCallbacks, function(i, cb) { |
| 56 | 66 | cb(addArr, upArr, upDownChange); |
| 57 | 67 | }); |
| 68 | + | |
| 58 | 69 | }; |
| 59 | 70 | |
| 60 | 71 | var startFixedTime; |
| ... | ... | @@ -81,11 +92,11 @@ var gb_data_gps = (function() { |
| 81 | 92 | }; |
| 82 | 93 | |
| 83 | 94 | var findOne = function(deviceId){ |
| 84 | - return realData[deviceId]; | |
| 95 | + return realData[deviceId]; | |
| 85 | 96 | }; |
| 86 | 97 | |
| 87 | 98 | var findGpsByNbbm = function(nbbm){ |
| 88 | - return realData[gb_data_basic.nbbm2deviceMap()[nbbm]]; | |
| 99 | + return realData[gb_data_basic.nbbm2deviceMap()[nbbm]]; | |
| 89 | 100 | }; |
| 90 | 101 | |
| 91 | 102 | return { | ... | ... |
src/main/resources/static/real_control_v2/js/data/gps_abnormal.js
| ... | ... | @@ -20,11 +20,20 @@ var gb_gps_abnormal = (function () { |
| 20 | 20 | var min, distance; |
| 21 | 21 | $.each(roads, function () { |
| 22 | 22 | distance = minDistanceFromRoad(this.pos, gps); |
| 23 | - if(!min || min > distance) | |
| 23 | + if (!min || min > distance) | |
| 24 | 24 | min = distance; |
| 25 | 25 | }); |
| 26 | 26 | |
| 27 | - //console.log('最短距离', min, gps); | |
| 27 | + //越界阈值 120米 | |
| 28 | + var threshold = 120; | |
| 29 | + if (gps.sch && gps.sch.bcType == 'in') | |
| 30 | + return; | |
| 31 | + | |
| 32 | + if (min > threshold) { | |
| 33 | + gps.abnormal = 'outBounds'; | |
| 34 | + gps.outBoundsDistance = min; | |
| 35 | + } | |
| 36 | + //console.log('最短距离', min, gps.nbbm); | |
| 28 | 37 | }; |
| 29 | 38 | |
| 30 | 39 | /** |
| ... | ... | @@ -46,20 +55,19 @@ var gb_gps_abnormal = (function () { |
| 46 | 55 | }); |
| 47 | 56 | //按线路_走向 分组数据 |
| 48 | 57 | allRoads = groupByLineAndUpdown(list); |
| 49 | - console.log('路段数据', allRoads); | |
| 50 | 58 | }); |
| 51 | 59 | }; |
| 52 | 60 | |
| 53 | - function minDistanceFromRoad(pos, gps){ | |
| 61 | + function minDistanceFromRoad(pos, gps) { | |
| 54 | 62 | var distance, min; |
| 55 | 63 | var len = pos.length - 1; |
| 56 | - for(var i = 0; i < len; i ++){ | |
| 64 | + for (var i = 0; i < len; i++) { | |
| 57 | 65 | distance = geolib.getDistanceFromLine({ |
| 58 | 66 | latitude: gps.lat, |
| 59 | 67 | longitude: gps.lon |
| 60 | 68 | }, pos[i], pos[i + 1]); |
| 61 | 69 | |
| 62 | - if(!min || min > distance) | |
| 70 | + if (!min || min > distance) | |
| 63 | 71 | min = distance; |
| 64 | 72 | } |
| 65 | 73 | |
| ... | ... | @@ -96,7 +104,7 @@ var gb_gps_abnormal = (function () { |
| 96 | 104 | return { |
| 97 | 105 | initData: initData, |
| 98 | 106 | check: function (gps) { |
| 99 | - if(!allRoads){ | |
| 107 | + if (!allRoads) { | |
| 100 | 108 | return; |
| 101 | 109 | } |
| 102 | 110 | ... | ... |
src/main/resources/static/real_control_v2/js/home/layout.js
| 1 | 1 | /* home js */ |
| 2 | 2 | |
| 3 | -var gb_home_layout = (function() { | |
| 3 | +var gb_home_layout = (function () { | |
| 4 | 4 | |
| 5 | 5 | var temps; |
| 6 | 6 | |
| 7 | - var layout = function(cb) { | |
| 7 | + var layout = function (cb) { | |
| 8 | 8 | //footer line name tabs |
| 9 | 9 | var codeArray = gb_data_basic.line_idx.split(','), |
| 10 | 10 | tabsArray = [], |
| 11 | 11 | len = codeArray.length; |
| 12 | 12 | for (var i = 0; i < len;) { |
| 13 | - tabsArray.push(connectArr(codeArray.slice(i, i += 3), ',', function(item) { | |
| 13 | + tabsArray.push(connectArr(codeArray.slice(i, i += 3), ',', function (item) { | |
| 14 | 14 | return gb_data_basic.codeToLine[item].name; |
| 15 | 15 | })); |
| 16 | 16 | } |
| 17 | 17 | //load template |
| 18 | - $.get('/real_control_v2/fragments/home/layout.html', function(dom) { | |
| 18 | + $.get('/real_control_v2/fragments/home/layout.html', function (dom) { | |
| 19 | 19 | temps = gb_common.compileTempByDom(dom); |
| 20 | 20 | |
| 21 | 21 | var htmlStr = temps['home-layout-tab-temp']({ |
| ... | ... | @@ -26,7 +26,7 @@ var gb_home_layout = (function() { |
| 26 | 26 | //render line panel |
| 27 | 27 | var i = 0, |
| 28 | 28 | data, renderFun = temps['home-layout-line-temp']; |
| 29 | - $('ul#home-main-content li').each(function() { | |
| 29 | + $('ul#home-main-content li').each(function () { | |
| 30 | 30 | data = gb_data_basic.findLineByCodes(codeArray.slice(i, i += 3)); |
| 31 | 31 | |
| 32 | 32 | $(this).html(renderFun({list: data})); |
| ... | ... | @@ -36,7 +36,12 @@ var gb_home_layout = (function() { |
| 36 | 36 | |
| 37 | 37 | cb && cb(); |
| 38 | 38 | }); |
| 39 | - } | |
| 39 | + }; | |
| 40 | + | |
| 41 | + //click svg edit icon | |
| 42 | + $(document).on('click', '.home-svg-edit-icon', function () { | |
| 43 | + open_modal('/real_control_v2/fragments/home/svg_edit.html', {lineCode: $(this).data('line-code')}); | |
| 44 | + }); | |
| 40 | 45 | |
| 41 | 46 | //文件载入完毕 |
| 42 | 47 | res_load_ep.emitLater('load_home_layout'); | ... | ... |
src/main/resources/static/real_control_v2/js/home/line_panel.js
| ... | ... | @@ -20,7 +20,7 @@ var gb_home_line_panel = (function() { |
| 20 | 20 | })); |
| 21 | 21 | |
| 22 | 22 | //draw svg |
| 23 | - gb_svg_chart.draw_line(line.lineCode, $('.svg-chart-wrap', this)); | |
| 23 | + gb_svg_chart.draw_line(line.lineCode, $('.svg-chart-wrap', this), true); | |
| 24 | 24 | }); |
| 25 | 25 | |
| 26 | 26 | //fixed table head |
| ... | ... | @@ -83,21 +83,18 @@ var gb_home_line_panel = (function() { |
| 83 | 83 | $(cells[1]).text(t.speed); |
| 84 | 84 | $(cells[2]).html(t.expectStopTime == null ? '' : t.expectStopTime); |
| 85 | 85 | |
| 86 | + //状态 | |
| 87 | + $(cells[3]).html(temps['home-gps-abnormal-temp'](t)); | |
| 88 | + | |
| 86 | 89 | if(!t.stationName) |
| 87 | 90 | t.stationName=''; |
| 88 | - $(cells[3]).text(t.stationName).attr('title', t.stationName); | |
| 91 | + $(cells[4]).text(t.stationName).attr('title', t.stationName); | |
| 89 | 92 | |
| 90 | 93 | //班次信息 |
| 91 | - if(t.schId){ | |
| 92 | - var sch=gb_schedule_table.findScheduleByLine(t.lineId)[t.schId]; | |
| 93 | - if(!sch) | |
| 94 | - return; | |
| 95 | - | |
| 96 | - $(cells[4]).text(sch.zdzName); | |
| 97 | - $(cells[5]).text(sch.zdsj); | |
| 98 | - $(cells[6]).text(sch.jName); | |
| 99 | - if(sch.sName) | |
| 100 | - $(cells[7]).text(sch.sName); | |
| 94 | + if(t.sch){ | |
| 95 | + $(cells[5]).text(t.sch.zdzName); | |
| 96 | + $(cells[6]).text(t.sch.zdsj); | |
| 97 | + $(cells[7]).text(t.sch.jName); | |
| 101 | 98 | } |
| 102 | 99 | }; |
| 103 | 100 | ... | ... |
src/main/resources/static/real_control_v2/js/main.js
| ... | ... | @@ -43,12 +43,12 @@ var gb_main_ep = new EventProxy(), |
| 43 | 43 | }); |
| 44 | 44 | |
| 45 | 45 | //初始化gps异常判定 |
| 46 | - //gb_gps_abnormal.initData(); | |
| 46 | + gb_gps_abnormal.initData(); | |
| 47 | 47 | |
| 48 | 48 | //嵌入地图页面 |
| 49 | 49 | $('li.map-panel', '#main-tab-content').load('/real_control_v2/mapmonitor/real.html'); |
| 50 | 50 | //弹出更新说明 |
| 51 | - //showUpdateDescription(); | |
| 51 | + showUpdateDescription(); | |
| 52 | 52 | }); |
| 53 | 53 | |
| 54 | 54 | function g_emit(id) { |
| ... | ... | @@ -177,8 +177,8 @@ var open_modal = function (pageUrl, data, opt) { |
| 177 | 177 | function showUpdateDescription() { |
| 178 | 178 | //更新说明 |
| 179 | 179 | var updateDescription = { |
| 180 | - date: '2016-12-20', | |
| 181 | - text: '<h5>1、回场子任务开放使用。</h5>' | |
| 180 | + date: '2017-01-07', | |
| 181 | + text: '<h5>1、出场子任务开放使用。</h5><h5>2、班次直放调整后可再次修改班次类型。</h5><h5>3、双击实发,可打开发车信息微调,发车信息微调界面可以直接烂班。</h5><h5>4、主页模拟图可以省略、重命名站点。</h5>' | |
| 182 | 182 | }; |
| 183 | 183 | |
| 184 | 184 | var storage = window.localStorage | ... | ... |
src/main/resources/static/real_control_v2/js/utils/svg_chart.js
| ... | ... | @@ -3,9 +3,11 @@ |
| 3 | 3 | var gb_svg_chart = (function () { |
| 4 | 4 | |
| 5 | 5 | //chart height |
| 6 | - var chart_height = 123; | |
| 6 | + var chart_height = 122; | |
| 7 | 7 | //left right padding |
| 8 | 8 | var x_padd = 30; |
| 9 | + //上空白部分 | |
| 10 | + var y_top_padd = 4; | |
| 9 | 11 | //text max size |
| 10 | 12 | var t_max_size = 7; |
| 11 | 13 | //svg namespace |
| ... | ... | @@ -24,11 +26,20 @@ var gb_svg_chart = (function () { |
| 24 | 26 | var h = wrap.actual('outerHeight'); |
| 25 | 27 | //隐藏元素取最外层的高度 |
| 26 | 28 | return h < 20 ? wrap.parent().actual('outerHeight') - 2 : h; |
| 27 | - } | |
| 28 | - | |
| 29 | - var draw_line = function (lineCode, wrap) { | |
| 29 | + }; | |
| 30 | 30 | |
| 31 | - var data = gb_svg_data_convert.mergeRoute(gb_data_basic.stationRoutes(lineCode)), | |
| 31 | + /** | |
| 32 | + * 绘制线路模拟图 | |
| 33 | + * @param lineCode 线路编码 | |
| 34 | + * @param wrap dom容器 | |
| 35 | + * @param enableAttr 是否启用配置 | |
| 36 | + */ | |
| 37 | + var draw_line = function (lineCode, wrap, enableAttr) { | |
| 38 | + //环线 | |
| 39 | + var loopLine = gb_data_basic.isLoopLine(lineCode); | |
| 40 | + | |
| 41 | + var routes = gb_data_basic.stationRoutes(lineCode); | |
| 42 | + var data = gb_svg_data_convert.mergeRoute(JSON.parse(JSON.stringify(routes)), enableAttr, lineCode), | |
| 32 | 43 | len = data.length; |
| 33 | 44 | |
| 34 | 45 | var w = get_width(wrap), |
| ... | ... | @@ -40,7 +51,7 @@ var gb_svg_chart = (function () { |
| 40 | 51 | return xScale(i); |
| 41 | 52 | }, |
| 42 | 53 | cy = function () { |
| 43 | - return (h - chart_height) / 2; | |
| 54 | + return (h - chart_height) / 2 + y_top_padd; | |
| 44 | 55 | }, |
| 45 | 56 | ty = function (d) { |
| 46 | 57 | return cy() + calc_text_y(cat_text(d.name[0])); |
| ... | ... | @@ -62,7 +73,7 @@ var gb_svg_chart = (function () { |
| 62 | 73 | |
| 63 | 74 | $(that).after(dText); |
| 64 | 75 | return cx(d, i) - 8; |
| 65 | - } | |
| 76 | + }; | |
| 66 | 77 | |
| 67 | 78 | //add svg dom |
| 68 | 79 | var svg = d3.select(wrap[0]).append('svg') |
| ... | ... | @@ -88,6 +99,7 @@ var gb_svg_chart = (function () { |
| 88 | 99 | |
| 89 | 100 | //down station link path |
| 90 | 101 | p_clzz.down = true; |
| 102 | + p_clzz.loop_line = loopLine; | |
| 91 | 103 | items.append('path').classed(p_clzz) |
| 92 | 104 | .attr('d', function (d, i) { |
| 93 | 105 | return i < len - 1 ? downLine([i, i + 1]) : ''; |
| ... | ... | @@ -125,7 +137,10 @@ var gb_svg_chart = (function () { |
| 125 | 137 | items.append('text').classed({ |
| 126 | 138 | 'station_text': true, |
| 127 | 139 | 'up': function (d) { |
| 128 | - return d.type == 3 ? true : false; | |
| 140 | + return d.type == 3 || d.type == 0 ? true : false; | |
| 141 | + }, | |
| 142 | + 'down': function (d) { | |
| 143 | + return d.type == 1 ? true : false; | |
| 129 | 144 | } |
| 130 | 145 | }) |
| 131 | 146 | .text(function (d) { |
| ... | ... | @@ -168,7 +183,7 @@ var gb_svg_chart = (function () { |
| 168 | 183 | var circle = get_circle(gps.stopNo + '_' + gps.upDown, svg); |
| 169 | 184 | if (!circle) return -100; |
| 170 | 185 | |
| 171 | - return circle.attr('cx') - 14; | |
| 186 | + return circle.attr('cx') - 17.5; | |
| 172 | 187 | }, |
| 173 | 188 | gy = function (gps, svg) { |
| 174 | 189 | var circle = get_circle(gps.stopNo + '_' + gps.upDown, svg); |
| ... | ... | @@ -177,7 +192,7 @@ var gb_svg_chart = (function () { |
| 177 | 192 | var cy = parseInt(circle.attr('cy')), |
| 178 | 193 | index = line_gps_index[gps.lineId][gps.stopNo + '_' + gps.upDown][gps.deviceId]; |
| 179 | 194 | |
| 180 | - return gps.upDown == 0 ? cy - 25 - (index * 21) : cy + 7 + (index * 21); | |
| 195 | + return gps.upDown == 0 ? cy - 22 - (index * 17) : cy + 6 + (index * 19); | |
| 181 | 196 | }, |
| 182 | 197 | ups_gps = function (d) { |
| 183 | 198 | return d.gpsUps; |
| ... | ... | @@ -209,8 +224,15 @@ var gb_svg_chart = (function () { |
| 209 | 224 | return d.deviceId; |
| 210 | 225 | }, |
| 211 | 226 | gps_update_point = function (e, svg) { |
| 227 | + var x; | |
| 212 | 228 | e.transition().attr('x', function (d) { |
| 213 | - return gx(d, svg); | |
| 229 | + x = gx(d, svg); | |
| 230 | + //找不到停靠点,直接隐藏 | |
| 231 | + if(x == -100) | |
| 232 | + $(this).hide(); | |
| 233 | + else | |
| 234 | + $(this).show(); | |
| 235 | + return x; | |
| 214 | 236 | }) |
| 215 | 237 | .attr('y', function (d) { |
| 216 | 238 | return gy(d, svg); |
| ... | ... | @@ -226,7 +248,7 @@ var gb_svg_chart = (function () { |
| 226 | 248 | }, |
| 227 | 249 | tx_id = function (d) { |
| 228 | 250 | return 'tx_' + d.deviceId; |
| 229 | - } | |
| 251 | + }; | |
| 230 | 252 | |
| 231 | 253 | var setGps = function (lineCode) { |
| 232 | 254 | var svgs = $('.line-chart[data-code=' + lineCode + ']'), |
| ... | ... | @@ -278,7 +300,7 @@ var gb_svg_chart = (function () { |
| 278 | 300 | |
| 279 | 301 | marker_clusterer_merge(svg, stopNo, gpsArr); |
| 280 | 302 | } |
| 281 | - } | |
| 303 | + }; | |
| 282 | 304 | |
| 283 | 305 | var marker_clusterer_merge = function (svg, stopNo, gpsArr) { |
| 284 | 306 | //stop circle |
| ... | ... | @@ -309,7 +331,7 @@ var gb_svg_chart = (function () { |
| 309 | 331 | mergerG.append('text').text(len) |
| 310 | 332 | .attr('x', x - ((len + '').length * 4)) |
| 311 | 333 | .attr('y', isDown ? y + 24 : y - 14); |
| 312 | - } | |
| 334 | + }; | |
| 313 | 335 | |
| 314 | 336 | return { |
| 315 | 337 | draw_line: draw_line, | ... | ... |
src/main/resources/static/real_control_v2/js/utils/svg_data_convert.js
| 1 | -var gb_svg_data_convert = (function() { | |
| 1 | +var gb_svg_data_convert = (function () { | |
| 2 | 2 | |
| 3 | 3 | /** |
| 4 | 4 | * 合并上下行路由 |
| 5 | 5 | * type 0 上行 1 下行 2 同名合并 3 异名合并 |
| 6 | + * | |
| 7 | + * 有时间再重写一些这块代码!!!!! | |
| 8 | + * | |
| 9 | + * enableAttr: 是否启用配置信息 | |
| 6 | 10 | */ |
| 7 | - function mergeRoute(routes) { | |
| 11 | + function mergeRoute(routes, enableAttr, lineCode) { | |
| 8 | 12 | //按上下行拆分 |
| 9 | 13 | routes = gb_common.groupBy(routes, 'directions'); |
| 10 | 14 | var up = routes[0], |
| ... | ... | @@ -13,6 +17,15 @@ var gb_svg_data_convert = (function() { |
| 13 | 17 | up.sort(upSort); |
| 14 | 18 | down.sort(downSort); |
| 15 | 19 | |
| 20 | + //根据配置处理一下数据 | |
| 21 | + if (enableAttr) { | |
| 22 | + var svgAttr = gb_data_basic.getSvgAttr(lineCode); | |
| 23 | + if (svgAttr) { | |
| 24 | + up = filterByAttrs(svgAttr, up); | |
| 25 | + down = filterByAttrs(svgAttr, down); | |
| 26 | + } | |
| 27 | + } | |
| 28 | + | |
| 16 | 29 | //同名站点合并 |
| 17 | 30 | var data = []; |
| 18 | 31 | for (var j = 0; j < up.length; j++) { |
| ... | ... | @@ -26,12 +39,21 @@ var gb_svg_data_convert = (function() { |
| 26 | 39 | }; |
| 27 | 40 | |
| 28 | 41 | if (upS.stationName != downS.stationName) { |
| 42 | + //下行站点在上行路由中是否存在 | |
| 29 | 43 | var dIndex = station_indexof(down, upS, j); |
| 44 | + //上行站点在下行路由中是否存在 | |
| 45 | + var uIndex = station_indexof(up, downS, j); | |
| 30 | 46 | if (dIndex == -1) { |
| 31 | - op.type = 0; | |
| 32 | - op.id = [get_station_code(upS), -1]; | |
| 33 | - //占位 | |
| 34 | - down.splice(j, 0, {}); | |
| 47 | + if (uIndex == -1) { | |
| 48 | + op.type = 3; | |
| 49 | + op.name = [upS.stationName, downS.stationName]; | |
| 50 | + } | |
| 51 | + else { | |
| 52 | + op.type = 0; | |
| 53 | + op.id = [get_station_code(upS), -1]; | |
| 54 | + //占位 | |
| 55 | + down.splice(j, 0, {}); | |
| 56 | + } | |
| 35 | 57 | } else { |
| 36 | 58 | for (var t = j; t < dIndex - 1; t++) { |
| 37 | 59 | var temp = down[t]; |
| ... | ... | @@ -76,22 +98,49 @@ var gb_svg_data_convert = (function() { |
| 76 | 98 | } |
| 77 | 99 | |
| 78 | 100 | //上下行GPS容器 |
| 79 | - $.each(data, function(){ | |
| 80 | - this.gpsUps= []; | |
| 81 | - this.gpsDowns= []; | |
| 101 | + $.each(data, function () { | |
| 102 | + this.gpsUps = []; | |
| 103 | + this.gpsDowns = []; | |
| 82 | 104 | }); |
| 83 | 105 | return data; |
| 84 | - } | |
| 106 | + }; | |
| 107 | + | |
| 108 | + var filterByAttrs = function (svgAttr, routes) { | |
| 109 | + var hideStations = svgAttr.hideStations ? svgAttr.hideStations : []; | |
| 110 | + var nicknames = svgAttr.nicknames ? svgAttr.nicknames : {}; | |
| 111 | + var stationCode; | |
| 112 | + $.each(routes, function (i) { | |
| 113 | + stationCode = this.stationCode | |
| 114 | + //要隐藏的站点 | |
| 115 | + $.each(hideStations, function (j, hide) { | |
| 116 | + if (stationCode == hide) | |
| 117 | + delete routes[i]; | |
| 118 | + }); | |
| 119 | + | |
| 120 | + //要重命名的站点 | |
| 121 | + if (nicknames[this.stationName]) { | |
| 122 | + this.stationName = nicknames[this.stationName]; | |
| 123 | + } | |
| 124 | + }); | |
| 125 | + | |
| 126 | + var newRoutes = []; | |
| 127 | + $.each(routes, function (i, station) { | |
| 128 | + if(station) | |
| 129 | + newRoutes.push(station); | |
| 130 | + }); | |
| 131 | + | |
| 132 | + return newRoutes; | |
| 133 | + }; | |
| 85 | 134 | |
| 86 | - var upSort = function(a, b) { | |
| 135 | + var upSort = function (a, b) { | |
| 87 | 136 | return a.stationRouteCode - b.stationRouteCode; |
| 88 | 137 | }; |
| 89 | 138 | |
| 90 | - var downSort = function(a, b) { | |
| 139 | + var downSort = function (a, b) { | |
| 91 | 140 | return b.stationRouteCode - a.stationRouteCode; |
| 92 | 141 | }; |
| 93 | 142 | |
| 94 | - var station_indexof = function(array, station, start) { | |
| 143 | + var station_indexof = function (array, station, start) { | |
| 95 | 144 | var res = -1; |
| 96 | 145 | for (var i = start, obj; obj = array[i++];) { |
| 97 | 146 | if (obj.stationName == station.stationName) { |
| ... | ... | @@ -102,15 +151,11 @@ var gb_svg_data_convert = (function() { |
| 102 | 151 | return res; |
| 103 | 152 | }; |
| 104 | 153 | |
| 105 | - var get_station_code=function (station) { | |
| 106 | - /*if(station.stationMark=='B' || station.stationMark=='E') | |
| 107 | - return station.stationCode+'_'+station.directions; | |
| 108 | - else | |
| 109 | - return station.stationCode;*/ | |
| 110 | - return station.stationCode+'_'+station.directions; | |
| 154 | + var get_station_code = function (station) { | |
| 155 | + return station.stationCode + '_' + station.directions; | |
| 111 | 156 | }; |
| 112 | 157 | |
| 113 | - var nvl_get = function(list, index) { | |
| 158 | + var nvl_get = function (list, index) { | |
| 114 | 159 | return list[index] == null ? {} : list[index]; |
| 115 | 160 | }; |
| 116 | 161 | ... | ... |