Commit 41d3f986fc9ee20af53c78fc1ade0bd8939ed34a

Authored by 王通
1 parent 5254b154

1.

src/main/java/com/bsth/XDApplication.java
1   -package com.bsth;
2   -
3   -import com.bsth.data.BasicData;
4   -import com.bsth.data.LineVersionsData;
5   -import com.bsth.data.ThreadMonotor;
6   -import com.bsth.data.car_out_info.UpdateDBThread;
7   -import com.bsth.data.directive.DirectivesPstThread;
8   -import com.bsth.data.forecast.SampleTimeDataLoader;
9   -import com.bsth.data.gpsdata_v2.thread.GpsDataLoaderThread;
10   -import com.bsth.data.gpsdata_v2.thread.OfflineMonitorThread;
11   -import com.bsth.data.msg_queue.DirectivePushQueue;
12   -import com.bsth.data.msg_queue.WebSocketPushQueue;
13   -import com.bsth.data.safe_driv.SafeDrivDataLoadThread;
14   -import com.bsth.data.schedule.DayOfSchedule;
15   -import com.bsth.data.schedule.auto_exec.AutoExecScanThread;
16   -import com.bsth.data.schedule.e_state_check.thread.FixedCheckStationCodeThread;
17   -import com.bsth.data.schedule.edit_logs.SeiPstThread;
18   -import com.bsth.data.schedule.late_adjust.ScheduleLateThread;
19   -import com.bsth.data.schedule.signal.SchSiginUpdateDBThread;
20   -import com.bsth.data.schedule.thread.CalcOilThread;
21   -import com.bsth.data.schedule.thread.SchedulePstThread;
22   -import com.bsth.data.schedule.thread.ScheduleRefreshThread;
23   -import com.bsth.data.schedule.thread.SubmitToTrafficManage;
24   -import com.bsth.util.DateUtils;
25   -import com.bsth.util.Tools;
26   -import org.slf4j.Logger;
27   -import org.slf4j.LoggerFactory;
28   -import org.springframework.beans.factory.annotation.Autowired;
29   -import org.springframework.boot.CommandLineRunner;
30   -import org.springframework.stereotype.Component;
31   -
32   -import java.util.concurrent.ScheduledExecutorService;
33   -import java.util.concurrent.TimeUnit;
34   -
35   -/**
36   - * 线调大部分服务都在这里启动
37   - * Created by panzhao on 2017/5/14.
38   - */
39   -@Component
40   -public class XDApplication implements CommandLineRunner {
41   -
42   - Logger log = LoggerFactory.getLogger(this.getClass());
43   -
44   - @Autowired
45   - BasicData.BasicDataLoader basicDataLoader;
46   - @Autowired
47   - UpdateDBThread fcxxUpdateThread;
48   - @Autowired
49   - ScheduleRefreshThread scheduleRefreshThread;
50   - @Autowired
51   - SchedulePstThread schedulePstThread;
52   - @Autowired
53   - ScheduleLateThread scheduleLateThread;
54   - @Autowired
55   - SubmitToTrafficManage submitToTrafficManage;
56   - @Autowired
57   - CalcOilThread calcOilThread;
58   - @Autowired
59   - DirectivesPstThread directivesPstThread;
60   - @Autowired
61   - ThreadMonotor threadMonotor;
62   - @Autowired
63   - SeiPstThread seiPstThread;
64   - @Autowired
65   - SampleTimeDataLoader sampleTimeDataLoader;
66   - @Autowired
67   - SchSiginUpdateDBThread schSiginUpdateDBThread;
68   - @Autowired
69   - AutoExecScanThread autoExecScanThread;
70   -
71   - @Autowired
72   - GpsDataLoaderThread gpsDataLoader;
73   -
74   - @Autowired
75   - OfflineMonitorThread offlineMonitorThread;
76   -
77   - @Autowired
78   - LineVersionsData lineVersionsData;
79   -
80   - /*@Autowired
81   - FixedEnableVerionsThread fixedEnableVerionsThread;*/
82   -
83   - @Autowired
84   - SafeDrivDataLoadThread safeDrivDataLoadThread;
85   -
86   - @Autowired
87   - FixedCheckStationCodeThread fixedCheckStationCodeThread;
88   -
89   - private static long timeDiff;
90   - private static long timeDiffTraffic;
91   -
92   - static {
93   - // 早上2:20
94   - timeDiff = (DateUtils.getTimestamp() + 1000 * 60 * 140) - System.currentTimeMillis();
95   - if (timeDiff < 0)
96   - timeDiff += (1000 * 60 * 60 * 24);
97   - // 早上07:00
98   - timeDiffTraffic = (DateUtils.getTimestamp() + 1000 * 60 * 60 * 7) - System.currentTimeMillis();
99   - if (timeDiffTraffic < 0)
100   - timeDiffTraffic += (1000 * 60 * 60 * 24);
101   - }
102   -
103   - @Override
104   - public void run(String... strings) throws Exception {
105   - try {
106   - Tools tools = new Tools("application.properties");
107   - String environment = tools.getValue("spring.profiles.active");
108   - //预先加载基础的对照数据
109   - basicDataLoader.loadAllData();
110   - switch (environment){
111   - case "dev":
112   - devInit();
113   - break;
114   - case "prod":
115   - prodInit();
116   - break;
117   - }
118   - }catch (Exception e){
119   - log.error("线调后台启动出现异常!!", e);
120   - System.exit(1);
121   - }
122   - }
123   -
124   - @Autowired
125   - DayOfSchedule dayOfSchedule;
126   - public void devInit(){
127   - log.info("devInit...");
128   - ScheduledExecutorService sexec = Application.mainServices;
129   - //抓取GPS数据
130   - GpsDataLoaderThread.setFlag(-1);
131   - //dayOfSchedule.dataRecovery();
132   - //sexec.scheduleWithFixedDelay(gpsDataLoader, 60, 4, TimeUnit.SECONDS);
133   - //实际排班更新线程
134   - //sexec.scheduleWithFixedDelay(scheduleRefreshThread, 15, 240, TimeUnit.SECONDS);
135   - //sexec.scheduleWithFixedDelay(scheduleLateThread, 140, 30, TimeUnit.SECONDS);//检查班次误点
136   - //sexec.scheduleWithFixedDelay(autoExecScanThread, 100, 50, TimeUnit.SECONDS);//班次自动执行
137   - //WebSocketPushQueue.start();//消息队列 -webSocket ,推送至线调web页面的
138   -
139   - //sexec.scheduleWithFixedDelay(fixedCheckStationCodeThread, 50, 60 * 5, TimeUnit.SECONDS);//检查班次站点编码
140   - //实际排班延迟入库线程
141   - //sexec.scheduleWithFixedDelay(schedulePstThread, 60, 15, TimeUnit.SECONDS);
142   - //班次修正日志延迟入库
143   - //sexec.scheduleWithFixedDelay(seiPstThread, 60, 30, TimeUnit.SECONDS);
144   - //调度指令延迟入库
145   - //sexec.scheduleWithFixedDelay(directivesPstThread, 180, 180, TimeUnit.SECONDS);
146   - //线程监听(防止重要的线程阻塞、异常结束。以及部分主备切换工作)
147   - //sexec.scheduleWithFixedDelay(threadMonotor, 240, 60, TimeUnit.SECONDS);
148   -
149   - //安全驾驶
150   - //sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 40, 30, TimeUnit.SECONDS);
151   -
152   - //sexec.scheduleWithFixedDelay(fixedEnableVerionsThread, 20, 60 * 2 , TimeUnit.SECONDS);
153   - }
154   -
155   - public void prodInit(){
156   - log.info("prodInit...");
157   - ScheduledExecutorService sexec = Application.mainServices;
158   - //安全驾驶
159   - //sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS);
160   -
161   - /** 线调业务 */
162   - sexec.scheduleWithFixedDelay(scheduleRefreshThread, 10, 120, TimeUnit.SECONDS);//班次更新线程
163   - sexec.scheduleWithFixedDelay(scheduleLateThread, 140, 20, TimeUnit.SECONDS);//检查班次误点
164   - GpsDataLoaderThread.setFlag(-1);
165   - sexec.scheduleWithFixedDelay(gpsDataLoader, 100, 2, TimeUnit.SECONDS);//抓取GPS数据
166   - sexec.scheduleWithFixedDelay(fixedCheckStationCodeThread, 60, 60 * 5, TimeUnit.SECONDS);//检查班次站点编码
167   -
168   - sexec.scheduleWithFixedDelay(offlineMonitorThread, 120, 60, TimeUnit.SECONDS);//GPS设备掉离线
169   - sexec.scheduleWithFixedDelay(schedulePstThread, 180, 10, TimeUnit.SECONDS);//班次延迟入库线程
170   - sexec.scheduleWithFixedDelay(seiPstThread, 180, 60, TimeUnit.SECONDS);//班次修正日志入库
171   - sexec.scheduleWithFixedDelay(directivesPstThread, 120, 60, TimeUnit.SECONDS);//调度指令延迟入库
172   - //sexec.scheduleWithFixedDelay(threadMonotor, 240, 60, TimeUnit.SECONDS);//线程监听(防止重要的线程阻塞、异常结束。以及部分主备切换工作)
173   - sexec.scheduleWithFixedDelay(sampleTimeDataLoader, 140, 120 * 60, TimeUnit.SECONDS);//到离站预测需要的站点间耗时数据
174   - sexec.scheduleWithFixedDelay(basicDataLoader, 1, 1, TimeUnit.HOURS);//基础数据更新
175   - sexec.scheduleWithFixedDelay(autoExecScanThread, 180, 50, TimeUnit.SECONDS);//班次自动执行
176   - DirectivePushQueue.start();//消息队列 -指令,系统下发的
177   - WebSocketPushQueue.start();//消息队列 -webSocket ,推送至线调web页面的
178   -
179   - /** 线调为其他程序提供的数据 --写入数据库 */
180   - sexec.scheduleWithFixedDelay(fcxxUpdateThread, 160, 30, TimeUnit.SECONDS);//发车信息(发车屏、信息发布)
181   - //线路首末班数据(网关用,班次更新时写入)
182   - //com.bsth.data.schedule.f_a_l.FirstAndLastHandler
183   - sexec.scheduleWithFixedDelay(schSiginUpdateDBThread, 160, 60 * 30, TimeUnit.SECONDS);//无法自动完成的班次信息(网关用,补信号)
184   -
185   - //运管处静态数据提交
186   - log.info(timeDiff / 1000 / 60 + "分钟之后提交到运管处");
187   - sexec.scheduleAtFixedRate(submitToTrafficManage, timeDiffTraffic / 1000, 60 * 60 * 24, TimeUnit.SECONDS);
188   - //计算油、公里加注
189   - sexec.scheduleAtFixedRate(calcOilThread, timeDiff / 1000, 60 * 60 * 24, TimeUnit.SECONDS);
190   -
191   - //线路版本更新
192   - sexec.scheduleWithFixedDelay(lineVersionsData, 60 * 5, 60 * 15, TimeUnit.SECONDS);
193   -
194   - //线路版本更新
195   - //sexec.scheduleWithFixedDelay(fixedEnableVerionsThread, 60 * 4, 60 * 2 , TimeUnit.SECONDS);
196   - }
197   -}
  1 +package com.bsth;
  2 +
  3 +import com.bsth.data.BasicData;
  4 +import com.bsth.data.LineVersionsData;
  5 +import com.bsth.data.ThreadMonotor;
  6 +import com.bsth.data.car_out_info.UpdateDBThread;
  7 +import com.bsth.data.directive.DirectivesPstThread;
  8 +import com.bsth.data.forecast.SampleTimeDataLoader;
  9 +import com.bsth.data.gpsdata_v2.thread.GpsDataLoaderThread;
  10 +import com.bsth.data.gpsdata_v2.thread.OfflineMonitorThread;
  11 +import com.bsth.data.msg_queue.DirectivePushQueue;
  12 +import com.bsth.data.msg_queue.WebSocketPushQueue;
  13 +import com.bsth.data.safe_driv.SafeDrivDataLoadThread;
  14 +import com.bsth.data.schedule.DayOfSchedule;
  15 +import com.bsth.data.schedule.auto_exec.AutoExecScanThread;
  16 +import com.bsth.data.schedule.e_state_check.thread.FixedCheckStationCodeThread;
  17 +import com.bsth.data.schedule.edit_logs.SeiPstThread;
  18 +import com.bsth.data.schedule.late_adjust.ScheduleLateThread;
  19 +import com.bsth.data.schedule.signal.SchSiginUpdateDBThread;
  20 +import com.bsth.data.schedule.thread.CalcOilThread;
  21 +import com.bsth.data.schedule.thread.SchedulePstThread;
  22 +import com.bsth.data.schedule.thread.ScheduleRefreshThread;
  23 +import com.bsth.data.schedule.thread.SubmitToTrafficManage;
  24 +import com.bsth.util.DateUtils;
  25 +import com.bsth.util.Tools;
  26 +import org.slf4j.Logger;
  27 +import org.slf4j.LoggerFactory;
  28 +import org.springframework.beans.factory.annotation.Autowired;
  29 +import org.springframework.boot.CommandLineRunner;
  30 +import org.springframework.stereotype.Component;
  31 +
  32 +import java.util.concurrent.ScheduledExecutorService;
  33 +import java.util.concurrent.TimeUnit;
  34 +
  35 +/**
  36 + * 线调大部分服务都在这里启动
  37 + * Created by panzhao on 2017/5/14.
  38 + */
  39 +@Component
  40 +public class XDApplication implements CommandLineRunner {
  41 +
  42 + Logger log = LoggerFactory.getLogger(this.getClass());
  43 +
  44 + @Autowired
  45 + BasicData.BasicDataLoader basicDataLoader;
  46 + @Autowired
  47 + UpdateDBThread fcxxUpdateThread;
  48 + @Autowired
  49 + ScheduleRefreshThread scheduleRefreshThread;
  50 + @Autowired
  51 + SchedulePstThread schedulePstThread;
  52 + @Autowired
  53 + ScheduleLateThread scheduleLateThread;
  54 + @Autowired
  55 + SubmitToTrafficManage submitToTrafficManage;
  56 + @Autowired
  57 + CalcOilThread calcOilThread;
  58 + @Autowired
  59 + DirectivesPstThread directivesPstThread;
  60 + @Autowired
  61 + ThreadMonotor threadMonotor;
  62 + @Autowired
  63 + SeiPstThread seiPstThread;
  64 + @Autowired
  65 + SampleTimeDataLoader sampleTimeDataLoader;
  66 + @Autowired
  67 + SchSiginUpdateDBThread schSiginUpdateDBThread;
  68 + @Autowired
  69 + AutoExecScanThread autoExecScanThread;
  70 +
  71 + @Autowired
  72 + GpsDataLoaderThread gpsDataLoader;
  73 +
  74 + @Autowired
  75 + OfflineMonitorThread offlineMonitorThread;
  76 +
  77 + @Autowired
  78 + LineVersionsData lineVersionsData;
  79 +
  80 + /*@Autowired
  81 + FixedEnableVerionsThread fixedEnableVerionsThread;*/
  82 +
  83 + @Autowired
  84 + SafeDrivDataLoadThread safeDrivDataLoadThread;
  85 +
  86 + @Autowired
  87 + FixedCheckStationCodeThread fixedCheckStationCodeThread;
  88 +
  89 + private static long timeDiff;
  90 + private static long timeDiffTraffic;
  91 +
  92 + static {
  93 + // 早上2:20
  94 + timeDiff = (DateUtils.getTimestamp() + 1000 * 60 * 140) - System.currentTimeMillis();
  95 + if (timeDiff < 0)
  96 + timeDiff += (1000 * 60 * 60 * 24);
  97 + // 早上07:00
  98 + timeDiffTraffic = (DateUtils.getTimestamp() + 1000 * 60 * 60 * 7) - System.currentTimeMillis();
  99 + if (timeDiffTraffic < 0)
  100 + timeDiffTraffic += (1000 * 60 * 60 * 24);
  101 + }
  102 +
  103 + @Override
  104 + public void run(String... strings) throws Exception {
  105 + try {
  106 + Tools tools = new Tools("application.properties");
  107 + String environment = tools.getValue("spring.profiles.active");
  108 + //预先加载基础的对照数据
  109 + basicDataLoader.loadAllData();
  110 + switch (environment){
  111 + case "dev":
  112 + devInit();
  113 + break;
  114 + case "prod":
  115 + prodInit();
  116 + break;
  117 + }
  118 + }catch (Exception e){
  119 + log.error("线调后台启动出现异常!!", e);
  120 + System.exit(1);
  121 + }
  122 + }
  123 +
  124 + @Autowired
  125 + DayOfSchedule dayOfSchedule;
  126 + public void devInit(){
  127 + log.info("devInit...");
  128 + ScheduledExecutorService sexec = Application.mainServices;
  129 + //抓取GPS数据
  130 + GpsDataLoaderThread.setFlag(-1);
  131 + //dayOfSchedule.dataRecovery();
  132 + //sexec.scheduleWithFixedDelay(gpsDataLoader, 60, 4, TimeUnit.SECONDS);
  133 + //实际排班更新线程
  134 + //sexec.scheduleWithFixedDelay(scheduleRefreshThread, 15, 240, TimeUnit.SECONDS);
  135 + //sexec.scheduleWithFixedDelay(scheduleLateThread, 140, 30, TimeUnit.SECONDS);//检查班次误点
  136 + //sexec.scheduleWithFixedDelay(autoExecScanThread, 100, 50, TimeUnit.SECONDS);//班次自动执行
  137 + //WebSocketPushQueue.start();//消息队列 -webSocket ,推送至线调web页面的
  138 +
  139 + //sexec.scheduleWithFixedDelay(fixedCheckStationCodeThread, 50, 60 * 5, TimeUnit.SECONDS);//检查班次站点编码
  140 + //实际排班延迟入库线程
  141 + //sexec.scheduleWithFixedDelay(schedulePstThread, 60, 15, TimeUnit.SECONDS);
  142 + //班次修正日志延迟入库
  143 + //sexec.scheduleWithFixedDelay(seiPstThread, 60, 30, TimeUnit.SECONDS);
  144 + //调度指令延迟入库
  145 + //sexec.scheduleWithFixedDelay(directivesPstThread, 180, 180, TimeUnit.SECONDS);
  146 + //线程监听(防止重要的线程阻塞、异常结束。以及部分主备切换工作)
  147 + //sexec.scheduleWithFixedDelay(threadMonotor, 240, 60, TimeUnit.SECONDS);
  148 +
  149 + //安全驾驶
  150 + //sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 40, 30, TimeUnit.SECONDS);
  151 +
  152 + //sexec.scheduleWithFixedDelay(fixedEnableVerionsThread, 20, 60 * 2 , TimeUnit.SECONDS);
  153 + }
  154 +
  155 + public void prodInit(){
  156 + log.info("prodInit...");
  157 + ScheduledExecutorService sexec = Application.mainServices;
  158 + //安全驾驶
  159 + //sexec.scheduleWithFixedDelay(safeDrivDataLoadThread, 180, 10, TimeUnit.SECONDS);
  160 +
  161 + /** 线调业务 */
  162 + sexec.scheduleWithFixedDelay(scheduleRefreshThread, 10, 120, TimeUnit.SECONDS);//班次更新线程
  163 + sexec.scheduleWithFixedDelay(scheduleLateThread, 140, 20, TimeUnit.SECONDS);//检查班次误点
  164 + GpsDataLoaderThread.setFlag(-1);
  165 + sexec.scheduleWithFixedDelay(gpsDataLoader, 100, 2, TimeUnit.SECONDS);//抓取GPS数据
  166 + sexec.scheduleWithFixedDelay(fixedCheckStationCodeThread, 60, 60 * 5, TimeUnit.SECONDS);//检查班次站点编码
  167 +
  168 + sexec.scheduleWithFixedDelay(offlineMonitorThread, 120, 60, TimeUnit.SECONDS);//GPS设备掉离线
  169 + sexec.scheduleWithFixedDelay(schedulePstThread, 180, 10, TimeUnit.SECONDS);//班次延迟入库线程
  170 + sexec.scheduleWithFixedDelay(seiPstThread, 180, 60, TimeUnit.SECONDS);//班次修正日志入库
  171 + sexec.scheduleWithFixedDelay(directivesPstThread, 120, 60, TimeUnit.SECONDS);//调度指令延迟入库
  172 + //sexec.scheduleWithFixedDelay(threadMonotor, 240, 60, TimeUnit.SECONDS);//线程监听(防止重要的线程阻塞、异常结束。以及部分主备切换工作)
  173 + sexec.scheduleWithFixedDelay(sampleTimeDataLoader, 140, 120 * 60, TimeUnit.SECONDS);//到离站预测需要的站点间耗时数据
  174 + sexec.scheduleWithFixedDelay(basicDataLoader, 1, 1, TimeUnit.HOURS);//基础数据更新
  175 + sexec.scheduleWithFixedDelay(autoExecScanThread, 180, 50, TimeUnit.SECONDS);//班次自动执行
  176 + DirectivePushQueue.start();//消息队列 -指令,系统下发的
  177 + WebSocketPushQueue.start();//消息队列 -webSocket ,推送至线调web页面的
  178 +
  179 + /** 线调为其他程序提供的数据 --写入数据库 */
  180 + sexec.scheduleWithFixedDelay(fcxxUpdateThread, 160, 30, TimeUnit.SECONDS);//发车信息(发车屏、信息发布)
  181 + //线路首末班数据(网关用,班次更新时写入)
  182 + //com.bsth.data.schedule.f_a_l.FirstAndLastHandler
  183 + sexec.scheduleWithFixedDelay(schSiginUpdateDBThread, 160, 60 * 30, TimeUnit.SECONDS);//无法自动完成的班次信息(网关用,补信号)
  184 +
  185 + //运管处静态数据提交
  186 + log.info(timeDiff / 1000 / 60 + "分钟之后提交到运管处");
  187 + //sexec.scheduleAtFixedRate(submitToTrafficManage, timeDiffTraffic / 1000, 60 * 60 * 24, TimeUnit.SECONDS);
  188 + //计算油、公里加注
  189 + sexec.scheduleAtFixedRate(calcOilThread, timeDiff / 1000, 60 * 60 * 24, TimeUnit.SECONDS);
  190 +
  191 + //线路版本更新
  192 + //sexec.scheduleWithFixedDelay(lineVersionsData, 60 * 5, 60 * 15, TimeUnit.SECONDS);
  193 +
  194 + //线路版本更新
  195 + //sexec.scheduleWithFixedDelay(fixedEnableVerionsThread, 60 * 4, 60 * 2 , TimeUnit.SECONDS);
  196 + }
  197 +}
... ...
src/main/resources/static/pages/base/section/js/section-list-table_sut.js
... ... @@ -13,7 +13,6 @@
13 13 */
14 14  
15 15 (function(){
16   - alert(1)
17 16 function getComp(cb) {
18 17 $.get('/user/companyData',null,function(rs) {
19 18 return cb && cb(rs);
... ...
src/main/resources/static/pages/base/stationroute/editsection_inout.html
... ... @@ -59,26 +59,25 @@
59 59 </div>
60 60 </div>
61 61 <script type="text/javascript">
62   -debugger;
63 62 $('#edit_section_mobal').on('editSectionMobal_show', function(e, map_,ajaxd,p,fun){
64 63 function setSectionFormValue(section) {
65 64 $('#edit_section_form input').each(function() {
66 65 $(this).val(eval('section.' + this.id));
67 66 });
68 67 }
69   - let section = p.data;
70   - let lineId = section.lineCode, version = section.versions, start = section.start, end = section.end;
  68 + var section = p.data;
  69 + var lineId = section.lineCode, version = section.versions, start = section.start, end = section.end;
71 70 setSectionFormValue(section);
72 71 // 获取路段号元素,并添加下拉属性值
73 72 ajaxd.getRouteByStartEnd(lineId,version,start, end,function(result) {
74   - let routes = result.data.routes,paramsD =new Array();
  73 + var routes = result.data.routes,paramsD =new Array();
75 74 var eq_scetionRouteCode = section.sectionrouteCode;
76 75 paramsD.push({'id':'请选择...','text':'将此路段设置位第一个路段'});
77 76 // 遍历
78 77 $.each(routes, function(i, g){
79 78 // 判断.
80 79 if(g.section.sectionName) {
81   - let ptions_v = g.sectionrouteCode;
  80 + var ptions_v = g.sectionrouteCode;
82 81 if(eq_scetionRouteCode != ptions_v) {
83 82 // 添加拼音检索下拉框格式数据数组.
84 83 paramsD.push({'id':ptions_v,
... ...
src/main/resources/static/pages/base/stationroute/js/stationroute-list-function.js
... ... @@ -118,7 +118,7 @@ var PublicFunctions = function () {
118 118 $('#inout_carpark_tree').show();
119 119 $('#InoutCarparktreeMobal .table-toolbar').show();
120 120  
121   - GetAjaxData.getRouteByStartEnd(id, version, start[0], end[0], (result1) => {
  121 + GetAjaxData.getRouteByStartEnd(id, version, start[0], end[0], function (result1) {
122 122 var routes = result1.data.routes, rootNode;
123 123 WorldsBMap.clearMarkAndOverlays();
124 124 var startPoint = mapData[start.join('_')], endPoint = mapData[end.join('_')], point, points;
... ... @@ -144,7 +144,7 @@ var PublicFunctions = function () {
144 144  
145 145 rootNode = {id: -1, pId: null, name: '路段', text: '路段', icon: null, groupType: 2, container : 'pjax-container', enable : true, children: routes};
146 146 if (routes.length > 0) {
147   - for (let i = 0,route;i < routes.length;i++) {
  147 + for (var i = 0,route;i < routes.length;i++) {
148 148 route = routes[i];
149 149 route.pId = 1;
150 150 route.name = route.section.sectionName;
... ...
src/main/resources/static/pages/base/stationroute/js/stationroute-list-map.js
... ... @@ -31,7 +31,7 @@ window.WorldsBMap = function () {
31 31 sectionArray = [], stationArray = new Map(),
32 32 map_status = 0,drawingManager,topOverlay;
33 33  
34   - let currentSection = {};
  34 + var currentSection = {};
35 35  
36 36 /**
37 37 * 编辑缓冲区
... ... @@ -1497,16 +1497,16 @@ window.WorldsBMap = function () {
1497 1497 * isMark 是否加站名
1498 1498 */
1499 1499 drawCircle: function (point, radius, stationName, isMark) {
1500   - let center = new BMap.Point(point.lng, point.lat);
1501   - let circle = new BMap.Circle(center, radius ,{strokeColor:"blue", strokeWeight:2, strokeOpacity:0.5});
  1500 + var center = new BMap.Point(point.lng, point.lat);
  1501 + var circle = new BMap.Circle(center, radius ,{strokeColor:"blue", strokeWeight:2, strokeOpacity:0.5});
1502 1502 mapBValue.addOverlay(circle);
1503 1503 if (isMark) {
1504   - let html = '<div style="position: absolute; margin: 0pt; padding: 0pt; width: 160px; height: 26px; left: -3px; top: -30px; overflow: hidden;">'
  1504 + var html = '<div style="position: absolute; margin: 0pt; padding: 0pt; width: 160px; height: 26px; left: -3px; top: -30px; overflow: hidden;">'
1505 1505 + '<img class="rm3_image" style="border:none;left:0px; top:0px; position:absolute;" src="/pages/base/stationroute/css/img/back160.png">'
1506 1506 + '</div>'
1507 1507 + '<label class=" BMapLabel" unselectable="on" style="position: absolute; -moz-user-select: none; display: inline; cursor: inherit; border: 0px none; padding: 2px 1px 1px; white-space: nowrap; font: 12px arial,simsun; z-index: 80; color: rgb(255, 102, 0); left: 20px; top: -30px;">' + stationName + '</label>';
1508 1508  
1509   - let myRichMarker = new BMapLib.RichMarker(html, center, {
  1509 + var myRichMarker = new BMapLib.RichMarker(html, center, {
1510 1510 "title": stationName,
1511 1511 "anchor": new BMap.Size(-10, 8),
1512 1512 "enableDragging": true
... ... @@ -1522,20 +1522,20 @@ window.WorldsBMap = function () {
1522 1522 * points 点数组
1523 1523 */
1524 1524 drawPolygon: function (points, stationName, isMark) {
1525   - let bdPoints = new Array(), i = 0, point;
  1525 + var bdPoints = new Array(), i = 0, point;
1526 1526 for (i = 0;i < points.length;i++) {
1527 1527 point = points[i].split(' ');
1528 1528 bdPoints.push(new BMap.Point(point[0], point[1]));
1529 1529 }
1530   - let polygon = new BMap.Polygon(bdPoints), center = bdPoints[0];
  1530 + var polygon = new BMap.Polygon(bdPoints), center = bdPoints[0];
1531 1531 mapBValue.addOverlay(polygon);
1532 1532 if (isMark) {
1533   - let html = '<div style="position: absolute; margin: 0pt; padding: 0pt; width: 160px; height: 26px; left: -3px; top: -30px; overflow: hidden;">'
  1533 + var html = '<div style="position: absolute; margin: 0pt; padding: 0pt; width: 160px; height: 26px; left: -3px; top: -30px; overflow: hidden;">'
1534 1534 + '<img class="rm3_image" style="border:none;left:0px; top:0px; position:absolute;" src="/pages/base/stationroute/css/img/back160.png">'
1535 1535 + '</div>'
1536 1536 + '<label class=" BMapLabel" unselectable="on" style="position: absolute; -moz-user-select: none; display: inline; cursor: inherit; border: 0px none; padding: 2px 1px 1px; white-space: nowrap; font: 12px arial,simsun; z-index: 80; color: rgb(255, 102, 0); left: 20px; top: -30px;">' + stationName + '</label>';
1537 1537  
1538   - let myRichMarker = new BMapLib.RichMarker(html, center, {
  1538 + var myRichMarker = new BMapLib.RichMarker(html, center, {
1539 1539 "title": stationName,
1540 1540 "anchor": new BMap.Size(-10, 8),
1541 1541 "enableDragging": true
... ... @@ -1547,7 +1547,7 @@ window.WorldsBMap = function () {
1547 1547 },
1548 1548  
1549 1549 drawPolyLine: function (points, data, start, end) {
1550   - let bdPoints = new Array(), i = 0, point, polyline;
  1550 + var bdPoints = new Array(), i = 0, point, polyline;
1551 1551 for (i = 0;i < points.length;i++) {
1552 1552 point = points[i].split(' ');
1553 1553 bdPoints.push(new BMap.Point(point[0], point[1]));
... ...