Commit 450417eddf457236f500e6a15e6afc9300ec1fb4

Authored by fxy
1 parent f1bd53e3

运管处

src/main/java/com/bsth/util/ReportUtils.java
@@ -15,9 +15,7 @@ import org.apache.poi.hssf.usermodel.HSSFWorkbook; @@ -15,9 +15,7 @@ import org.apache.poi.hssf.usermodel.HSSFWorkbook;
15 import org.apache.poi.poifs.filesystem.POIFSFileSystem; 15 import org.apache.poi.poifs.filesystem.POIFSFileSystem;
16 import org.apache.poi.ss.usermodel.Cell; 16 import org.apache.poi.ss.usermodel.Cell;
17 17
18 -import com.bsth.entity.Cars;  
19 import com.bsth.entity.Line; 18 import com.bsth.entity.Line;
20 -import com.bsth.entity.Section;  
21 import com.bsth.entity.realcontrol.ScheduleRealInfo; 19 import com.bsth.entity.realcontrol.ScheduleRealInfo;
22 20
23 public class ReportUtils { 21 public class ReportUtils {
@@ -191,56 +189,33 @@ public class ReportUtils { @@ -191,56 +189,33 @@ public class ReportUtils {
191 */ 189 */
192 private void getValueAndSetCellValue(HSSFCell cell, String key, Object obj) { 190 private void getValueAndSetCellValue(HSSFCell cell, String key, Object obj) {
193 try { 191 try {
  192 + // 保有存单元格的内容
194 String cellValue = key = key.replace("\\n", ""); 193 String cellValue = key = key.replace("\\n", "");
195 - String tmpKey ;  
196 - while(key.indexOf("$") != -1){  
197 - key = key.substring(key.indexOf("$")+1);  
198 - tmpKey = key.substring(0,key.indexOf("$"));  
199 - key = key.substring(key.indexOf("$")+1); 194 + String tmpKey;
  195 + // 循环截取两个$中间的内容,反射出值
  196 + while (key.indexOf("$") != -1) {
  197 + key = key.substring(key.indexOf("$") + 1);
  198 + // 取两个$中间的内容
  199 + tmpKey = key.substring(0, key.indexOf("$"));
  200 + key = key.substring(key.indexOf("$") + 1);
  201 + // 如果内容是如下格式Cars.id,则从obj中值得相应的对象的值
200 if (tmpKey.indexOf(".") != -1) { 202 if (tmpKey.indexOf(".") != -1) {
201 String className = tmpKey.substring(0, tmpKey.indexOf(".")); 203 String className = tmpKey.substring(0, tmpKey.indexOf("."));
  204 + // 取得类的全限定名
202 String classWholeName = packaegName + className; 205 String classWholeName = packaegName + className;
203 String fieldName = tmpKey.substring(tmpKey.indexOf(".") + 1); 206 String fieldName = tmpKey.substring(tmpKey.indexOf(".") + 1);
204 - if (obj.getClass().getName().equals(classWholeName)) {  
205 - cellValue = cellValue.replace("$"+tmpKey+"$", getKeyValue(obj,fieldName)+"");  
206 - }  
207 - }  
208 - }  
209 - cell.setCellValue(cellValue);  
210 - } catch (Exception e) {  
211 - e.printStackTrace();  
212 - }  
213 -  
214 - }  
215 -  
216 - /**  
217 - * 取到相应的值并填入相应的列中  
218 - *  
219 - * @param cell  
220 - * 列  
221 - * @param key  
222 - * 列内容  
223 - * @param tArray  
224 - * 数据源对象  
225 - */  
226 - private void getValueAndSetCellValue(HSSFCell cell, String key,  
227 - Object[] tArray) {  
228 - try {  
229 - String cellValue = key = key.replace("\\n", "");  
230 - String tmpKey ;  
231 - while(key.indexOf("$") != -1){  
232 - key = key.substring(key.indexOf("$")+1);  
233 - tmpKey = key.substring(0,key.indexOf("$"));  
234 - key = key.substring(key.indexOf("$")+1);  
235 - if (tmpKey.indexOf(".") != -1) {  
236 - String className = tmpKey.substring(0, tmpKey.indexOf("."));  
237 - String classWholeName = packaegName + className;  
238 - String fieldName = tmpKey.substring(tmpKey.indexOf(".") + 1);  
239 - for (int k = 0; k < tArray.length; k++) {  
240 - if (tArray[k].getClass().getName()  
241 - .equals(classWholeName)) {  
242 - cellValue = cellValue.replace("$"+tmpKey+"$", getKeyValue(tArray[k],fieldName)+""); 207 + // 如果obj是数组,循环判断哪个对象是对应的
  208 + if (obj instanceof Object[]) {
  209 + Object[] objs = (Object[]) obj;
  210 + for (int k = 0; k < objs.length; k++) {
  211 + if (objs[k].getClass().getName().equals(classWholeName)) {
  212 + cellValue = cellValue.replace("$" + tmpKey
  213 + + "$", getKeyValue(objs[k], fieldName)
  214 + + "");
  215 + }
243 } 216 }
  217 + } else if (obj.getClass().getName().equals(classWholeName)) {
  218 + cellValue = cellValue.replace("$" + tmpKey + "$",getKeyValue(obj, fieldName) + "");
244 } 219 }
245 } 220 }
246 } 221 }
@@ -266,8 +241,7 @@ public class ReportUtils { @@ -266,8 +241,7 @@ public class ReportUtils {
266 try { 241 try {
267 if (obj != null) { 242 if (obj != null) {
268 ReportRelatedUtils test = new ReportRelatedUtils(); 243 ReportRelatedUtils test = new ReportRelatedUtils();
269 - value = test.getValue(obj, fieldName) == null ? "" : test  
270 - .getValue(obj, fieldName); 244 + value = test.getValue(obj, fieldName) == null ? "" : test .getValue(obj, fieldName);
271 } 245 }
272 } catch (Exception e) { 246 } catch (Exception e) {
273 e.printStackTrace(); 247 e.printStackTrace();
@@ -285,49 +259,13 @@ public class ReportUtils { @@ -285,49 +259,13 @@ public class ReportUtils {
285 line.setName("line1"); 259 line.setName("line1");
286 260
287 List<Object> dataList = new ArrayList<Object>(); 261 List<Object> dataList = new ArrayList<Object>();
288 -// Cars cars = new Cars();  
289 -// cars.setId(111);  
290 -// cars.setCompany("111car");  
291 -// dataList.add(cars);  
292 -// cars = new Cars();  
293 -// cars.setId(222);  
294 -// cars.setCompany("222car");  
295 -// dataList.add(cars);  
296 -// cars = new Cars();  
297 -// cars.setId(101);  
298 -// cars.setCompany("101car");  
299 -// dataList.add(cars);  
300 -// cars = new Cars();  
301 -// cars.setId(101);  
302 -// cars.setCompany("101car");  
303 -// dataList.add(cars);  
304 -// cars = new Cars();  
305 -// cars.setId(101);  
306 -// cars.setCompany("101car");  
307 -// dataList.add(cars);  
308 -// cars = new Cars();  
309 -// cars.setId(101);  
310 -// cars.setCompany("101car");  
311 -// dataList.add(cars);  
312 -// cars = new Cars();  
313 -// cars.setId(101);  
314 -// cars.setCompany("101car");  
315 -// dataList.add(cars);  
316 -// cars = new Cars();  
317 -// cars.setId(101);  
318 -// cars.setCompany("101car");  
319 -// dataList.add(cars);  
320 -// cars = new Cars();  
321 -// cars.setId(101);  
322 -// cars.setCompany("101car");  
323 -// dataList.add(cars);  
324 -// list.add(dataList.iterator()); 262 +
325 263
326 - ScheduleRealInfo sr = new ScheduleRealInfo();  
327 - sr.setId((long) 111);  
328 - sr.setXlName("abc"); 264 + ScheduleRealInfo srr = new ScheduleRealInfo();
  265 + srr.setId((long) 111);
  266 + srr.setXlName("abc11");
329 267
330 - sr = new ScheduleRealInfo(); 268 + ScheduleRealInfo sr = new ScheduleRealInfo();
331 sr.setId((long) 22); 269 sr.setId((long) 22);
332 sr.setXlName("abc22"); 270 sr.setXlName("abc22");
333 dataList.add(sr); 271 dataList.add(sr);
@@ -336,63 +274,15 @@ public class ReportUtils { @@ -336,63 +274,15 @@ public class ReportUtils {
336 sr.setXlName("abc33"); 274 sr.setXlName("abc33");
337 dataList.add(sr); 275 dataList.add(sr);
338 list.add(dataList.iterator()); 276 list.add(dataList.iterator());
339 - // dataList = new ArrayList<Object>();  
340 - // Section section = new Section();  
341 - // section.setId(333);  
342 - // section.setSectionName("333section");  
343 - // dataList.add(section);  
344 - // section = new Section();  
345 - // section.setId(444);  
346 - // section.setSectionName("444section");  
347 - // dataList.add(section);  
348 - // section = new Section();  
349 - // section.setId(555);  
350 - // section.setSectionName("555section");  
351 - // dataList.add(section);  
352 - // section = new Section();  
353 - // section.setId(666);  
354 - // section.setSectionName("666section");  
355 - // dataList.add(section);  
356 - // section = new Section();  
357 - // section.setId(777);  
358 - // section.setSectionName("777section");  
359 - // dataList.add(section);  
360 - // section = new Section();  
361 - // section.setId(888);  
362 - // section.setSectionName("888section");  
363 - // // dataList.add(section);  
364 - // list.add(dataList.iterator());  
365 - ee.excelReplace(list, new Object[] { sr }, "D:\\55.xls", 277 +
  278 + ee.excelReplace(list, new Object[] { srr }, "D:\\55.xls",
366 "D:\\22.xls"); 279 "D:\\22.xls");
367 - // ee.test(line);  
368 - // ee.shiftRow();  
369 System.out.println("ok"); 280 System.out.println("ok");
370 } catch (Exception e) { 281 } catch (Exception e) {
371 e.printStackTrace(); 282 e.printStackTrace();
372 } 283 }
373 } 284 }
374 285
375 - private void shiftRow() {  
376 - try {  
377 - String targetPath = "D:\\22.xls";  
378 - // 把源文件放入流中  
379 - POIFSFileSystem fs = new POIFSFileSystem(new FileInputStream(  
380 - "D:\\44.xls"));  
381 - HSSFWorkbook wb = new HSSFWorkbook(fs);  
382 - HSSFSheet sheet = wb.getSheetAt(0);  
383 - sheet.shiftRows(1, 2, 4);  
384 - // 创建目标文件夹  
385 - createFolder(targetPath);  
386 - // 输出文件  
387 - FileOutputStream fileOut = new FileOutputStream(targetPath);  
388 - wb.write(fileOut);  
389 - fileOut.close();  
390 - } catch (Exception e) {  
391 - e.printStackTrace();  
392 - }  
393 -  
394 - }  
395 -  
396 /** 286 /**
397 * 行复制功能 287 * 行复制功能
398 * 288 *
src/main/resources/static/pages/trafficManage/css/autocompleter.css
1 -/**  
2 - * Simplecomplete  
3 - */  
4 -  
5 -.autocompleter {  
6 - width: 20%;  
7 - background: #ffffff;  
8 - position: relative;  
9 - z-index: 100;  
10 -}  
11 -  
12 -.autocompleter,  
13 -.autocompleter-hint {  
14 - position: absolute;  
15 -}  
16 -  
17 -.autocompleter-list {  
18 - box-shadow: inset 0px 0px 6px rgba(0,0,0,0.1);  
19 - list-style: none;  
20 - margin: 0;  
21 - padding: 0;  
22 - text-align: left;  
23 -}  
24 -  
25 -.autocompleter-item-selected {  
26 - background: #ffffff;  
27 -}  
28 -  
29 -.autocompleter-item {  
30 - padding: 6px 12px;  
31 - color: #444444;  
32 - font-size: 14px;  
33 - cursor: pointer;  
34 -}  
35 -  
36 -.autocompleter-item:hover {  
37 - background: #ddd;  
38 -}  
39 -  
40 -.autocompleter-item strong {  
41 - background: #f9de8f;  
42 - text-shadow: 0 1px 0 #ffffff;  
43 -}  
44 -  
45 -.autocompleter-item span {  
46 - color: #bbbbbb;  
47 -}  
48 -  
49 -.autocompleter-hint {  
50 - color: #ccc;  
51 - text-align: left;  
52 - top: -56px;  
53 - font-weight: 400;  
54 - left: 0;  
55 - width: 100%;  
56 - padding: 12px 12px 12px 13px;  
57 - font-size: 24px;  
58 - display: none;  
59 -}  
60 -  
61 -.autocompleter-hint span {  
62 - color: transparent;  
63 -}  
64 -  
65 -  
66 -.autocompleter-closed {  
67 - display: none;  
68 -} 1 +/**
  2 + * Simplecomplete
  3 + */
  4 +
  5 +.autocompleter {
  6 + width: 20%;
  7 + background: #ffffff;
  8 + position: relative;
  9 + z-index: 100;
  10 +}
  11 +
  12 +.autocompleter,
  13 +.autocompleter-hint {
  14 + position: absolute;
  15 +}
  16 +
  17 +.autocompleter-list {
  18 + box-shadow: inset 0px 0px 6px rgba(0,0,0,0.1);
  19 + list-style: none;
  20 + margin: 0;
  21 + padding: 0;
  22 + text-align: left;
  23 +}
  24 +
  25 +.autocompleter-item-selected {
  26 + background: #ffffff;
  27 +}
  28 +
  29 +.autocompleter-item {
  30 + padding: 6px 12px;
  31 + color: #444444;
  32 + font-size: 14px;
  33 + cursor: pointer;
  34 +}
  35 +
  36 +.autocompleter-item:hover {
  37 + background: #ddd;
  38 +}
  39 +
  40 +.autocompleter-item strong {
  41 + background: #f9de8f;
  42 + text-shadow: 0 1px 0 #ffffff;
  43 +}
  44 +
  45 +.autocompleter-item span {
  46 + color: #bbbbbb;
  47 +}
  48 +
  49 +.autocompleter-hint {
  50 + color: #ccc;
  51 + text-align: left;
  52 + top: -56px;
  53 + font-weight: 400;
  54 + left: 0;
  55 + width: 100%;
  56 + padding: 12px 12px 12px 13px;
  57 + font-size: 24px;
  58 + display: none;
  59 +}
  60 +
  61 +.autocompleter-hint span {
  62 + color: transparent;
  63 +}
  64 +
  65 +
  66 +.autocompleter-closed {
  67 + display: none;
  68 +}
src/main/resources/static/pages/trafficManage/css/trafficManage.css
1 -  
2 -.tab_line{  
3 - background-color: #ffffff;  
4 - height: 800px;  
5 - padding-left: 3px;  
6 - padding-right: 3px;  
7 -}  
8 -.tab_line .breadcrumb{  
9 - color: #3f444a;  
10 - padding-top:10px;  
11 -}  
12 -.tab_line .panel-wrap{  
13 - height: 100%;  
14 - padding-left: 3px;  
15 - padding-right: 3px;  
16 -}  
17 -  
18 -.tab_line .panel-wrap ._panel{  
19 - border: 1px solid #ddd;  
20 - box-shadow: 0 2px 5px 0 rgba(221, 221, 221, 0.32),0 2px 10px 0 rgba(221, 221, 221, 0.32);  
21 - width: 100%;  
22 - height: 100%;  
23 - position: relative;  
24 - /* overflow: auto; */  
25 -}  
26 -.tab_line .panel-wrap ._panel ._head{  
27 - height: 42px;  
28 - line-height: 42px;  
29 - padding-left: 15px;  
30 - font-size: 16px;  
31 - font-family: 微软雅黑;  
32 -}  
33 -.table-striped>tbody>tr:nth-of-type(even) {  
34 - background-color: #eee;  
35 -}  
36 -  
37 -.breadcruma {  
38 - margin:0 auto;  
39 -}  
40 -  
41 -.breadcruma li {  
42 - text-align:center;  
43 - margin:0 auto;  
44 - list-style-type:none;  
45 -}  
46 -.divVerHorCenter{  
47 - line-height: 3;  
48 - position: absolute;  
49 - padding-left: initial;  
50 - top: 50%;  
51 - left: 50%;  
52 - width:50%;  
53 - -webkit-transform: translateX(-50%) translateY(-50%); 1 +.tab_line {
  2 + background-color: #ffffff;
  3 + height: 800px;
  4 + padding-left: 3px;
  5 + padding-right: 3px;
  6 +}
  7 +
  8 +.tab_line .breadcrumb {
  9 + color: #3f444a;
  10 + padding-top: 10px;
  11 +}
  12 +
  13 +.tab_line .panel-wrap {
  14 + height: 100%;
  15 + padding-left: 3px;
  16 + padding-right: 3px;
  17 +}
  18 +
  19 +.tab_line .panel-wrap ._panel {
  20 + border: 1px solid #ddd;
  21 + box-shadow: 0 2px 5px 0 rgba(221, 221, 221, 0.32), 0 2px 10px 0
  22 + rgba(221, 221, 221, 0.32);
  23 + width: 100%;
  24 + height: 100%;
  25 + position: relative;
  26 + /* overflow: auto; */
  27 +}
  28 +
  29 +.tab_line .panel-wrap ._panel ._head {
  30 + height: 42px;
  31 + line-height: 42px;
  32 + padding-left: 15px;
  33 + font-size: 16px;
  34 + font-family: 微软雅黑;
  35 +}
  36 +
  37 +.table-striped>tbody>tr:nth-of-type(even) {
  38 + background-color: #eee;
  39 +}
  40 +
  41 +.breadcruma {
  42 + margin: 0 auto;
  43 +}
  44 +
  45 +.breadcruma li {
  46 + text-align: center;
  47 + margin: 0 auto;
  48 + list-style-type: none;
  49 +}
  50 +
  51 +.divVerHorCenter {
  52 + line-height: 3;
  53 + position: absolute;
  54 + padding-left: initial;
  55 + top: 50%;
  56 + left: 50%;
  57 + width: 50%;
  58 + -webkit-transform: translateX(-50%) translateY(-50%);
  59 +}
  60 +
  61 +.inputCommon{
  62 + height: 30px;
  63 + padding: 5px 10px;
  64 + font-size: 12px;
  65 + line-height: 1.5;
  66 + box-shadow: none !important;
  67 + border: 1px solid #c2cad8;
  68 + background-color: #fff;
  69 +}
  70 +.dateRange {
  71 + width: 30px;
  72 + margin-right: 5px;
  73 + text-align: center;
  74 +}
  75 +
  76 +.dateTime {
  77 + width: 100px;
  78 +}
  79 +
  80 +.inputCarPlate {
  81 + width: 100px;
54 } 82 }
55 \ No newline at end of file 83 \ No newline at end of file
src/main/resources/static/pages/trafficManage/js/lineStationUpload.js
1 -/**  
2 - *  
3 - * @JSName : common.js(运管功能公共js)  
4 - *  
5 - * @Author : bsth@lq  
6 - *  
7 - * @Description : TODO(运管功能公共js)  
8 - *  
9 - * @Data : 2016年6月29日 上午9:21:17  
10 - *  
11 - * @Version 公交调度系统BS版 0.1  
12 - *  
13 - */  
14 -  
15 -(function(){  
16 - /**  
17 - * 取得编码-公司map  
18 - * gsmap["5"] = 南汇公司  
19 - * gsmap["5_3"] = 芦潮港分公司  
20 - */  
21 - function getBusMap(){  
22 - // 取得公司信息,替换公司编码  
23 - var gsmap = {};  
24 - $get('/business/all', null, function(array){  
25 - $.each(array, function(i, gs){  
26 - var k = gs.upCode + '_' + gs.businessCode;  
27 - if(gs.upCode === '88'){  
28 - k = gs.businessCode;  
29 - }  
30 - gsmap[k] = gs.businessName;  
31 - });  
32 - });  
33 - return gsmap;  
34 - }  
35 - // 填充公司下拉框选择值  
36 - $get('/business/all', {upCode_eq: '88'}, function(array){  
37 -  
38 - // 公司下拉options属性值  
39 - var options = '<option value="">请选择...</option>';  
40 -  
41 - // 遍历array  
42 - $.each(array, function(i,d){  
43 -  
44 - options += '<option value="'+d.businessCode+'">'+d.businessName+'</option>';  
45 -  
46 - });  
47 -  
48 - // 填充公司下拉框options,并添加公司下拉框值改变事件setbrancheCompanySelectOptions  
49 - $('#companySelect').html(options).on('change', setbrancheCompanySelectOptions);  
50 -  
51 - });  
52 -  
53 - // 填充分公司下拉框选择值  
54 - function setbrancheCompanySelectOptions(){  
55 -  
56 - // 获取公司下拉框选择值  
57 - var businessCode = $('#companySelect').val();  
58 -  
59 - // 分公司下拉框options属性值  
60 - var options = '<option value="">请选择...</option>';  
61 -  
62 - // 如果公司选择为空则分公司为空 ; 否则查询出所属公司下的分公司名称和相应分公司代码  
63 - if(businessCode == null || businessCode ==''){  
64 -  
65 - // 填充分公司下拉框options  
66 - $('#brancheCompanySelect').html(options);  
67 -  
68 - } else {  
69 -  
70 - // 查询出所属公司下的分公司名称和相应分公司代码  
71 - $get('/business/all', {upCode_eq: businessCode}, function(array){  
72 -  
73 - // 遍历array  
74 - $.each(array, function(i,d){  
75 -  
76 - options += '<option value="'+d.businessCode+'">'+d.businessName+'</option>';  
77 -  
78 - // 填充分公司下拉框options  
79 - $('#brancheCompanySelect').html(options);  
80 -  
81 - });  
82 - });  
83 -  
84 - // 填充公司下拉框options,并添加公司下拉框值改变事件setbrancheCompanySelectOptions  
85 - $('#brancheCompanySelect').html(options).on('change', setLineAutocompleteOptions);  
86 - }  
87 - }  
88 -  
89 - function setLineAutocompleteOptions(){  
90 - // 搜索参数集合  
91 - var params = {};  
92 - // 搜索字段名称  
93 - var name;  
94 - var items = $("ul.breadcrumb select");  
95 - // 遍历items集合  
96 - for(var j = 0, item; item = items[j++];){  
97 - // 获取字段名称  
98 - name = $(item).attr('name');  
99 - if(name){  
100 - // 赋取相对应的值  
101 - params[name] = $(item).val();  
102 - }  
103 - }  
104 - var lines = new Array();  
105 - var gsmap = getBusMap();  
106 - // 取得所有线路  
107 - $get('/line/all', params, function(allLine) {  
108 - // 遍历数组  
109 - $.each(allLine, function(i, e) {  
110 - var companyCode = e.company;  
111 - e.company = gsmap[e.company];  
112 - e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];  
113 - var line = '{"hex":"'+e.company+'","label":"'+e.name+'"}';  
114 - var obj = jQuery.parseJSON(line);  
115 - lines[i]= obj;  
116 - });  
117 -  
118 -  
119 - });  
120 - // 给输入框绑定autocomplete事件  
121 - $("input[name='name_eq']").autocompleter({  
122 - highlightMatches: true,  
123 - source: lines,  
124 - template: '{{ label }} <span>({{ hex }})</span>',  
125 - hint: true,  
126 - empty: false,  
127 - limit: 5,  
128 - });  
129 - }  
130 -  
131 -  
132 - // 设置autocompleter的宽度和输入框一样  
133 - $(".autocompleter").css("width",$("input[name='name_eq']").css("width"))  
134 - // 绑定查询事件  
135 - $("#search").click(searchM);  
136 - // 绑定上传事件  
137 - $("#upload").click(uploadM);  
138 - // 绑定全部移到右边事件  
139 - $("#to_right").click(function(){  
140 - $("#left_div tbody tr:not(.muted)").click();  
141 - });  
142 - // 绑定全部移到左边事件  
143 - $("#to_left").click(function(){  
144 - $("#right_div tbody tr:not(.muted)").click();  
145 - });  
146 - // 查询方法  
147 - function searchM() {  
148 - // 清空已选定列表  
149 - $("#right_div table tbody").empty();  
150 - var params = {};  
151 - // 取得输入框的值  
152 - var inputs = $("ul.breadcrumb input");  
153 - // 遍历数组  
154 - $.each(inputs, function(i, element) {  
155 - params[$(element).attr("name")] = $(element).val();  
156 - });  
157 - var i = layer.load(2);  
158 - $get('/line', params, function(data) {  
159 - var bodyHtm = template('lineStation_list_temp', {  
160 - list : data.content  
161 - });  
162 - $("#left_div table tbody").empty();  
163 - $("#left_div table tbody").append(bodyHtm);  
164 - $("#left_div tbody tr:not(.muted)").click(_click);  
165 - layer.close(i);  
166 - });  
167 - }  
168 -  
169 - // 上传方法  
170 - function uploadM() {  
171 - var params = {};  
172 - // 取得输入框的值  
173 - var trs = $("#right_div tbody tr");  
174 - if (trs.length == 0) {  
175 - alert("请选择模板");  
176 - return;  
177 - }  
178 - // 遍历数组  
179 - $.each(trs, function(i, element) {  
180 - alert($(".ttInfoId", element).html());  
181 - });  
182 - }  
183 -  
184 - // 表格行的单击事件  
185 - function _click() {  
186 - var tmpTr = $(this).clone();  
187 - tmpTr.unbind("click").click(_click);  
188 - // 判断父DIV的ID  
189 - if ($(this).closest(".table-container").attr("id") == "left_div") {  
190 - // 把要移动行的class=".seq"的HTML的内容设成另一分类的最后一个序号  
191 - $(".seq",tmpTr).html($("#right_div tbody tr:not(.muted)").length + 1);  
192 - $("#right_div tbody").append(tmpTr);  
193 - nextAllChildSeqMinusOne($(this));  
194 - } else {  
195 - // 把要移动行的class=".seq"的HTML的内容设成另一分类的最后一个序号  
196 - $(".seq",tmpTr).html($("#left_div tbody tr:not(.muted)").length + 1);  
197 - $("#left_div tbody").append(tmpTr);  
198 - nextAllChildSeqMinusOne($(this));  
199 - }  
200 - $(this).remove();  
201 - }  
202 -  
203 - // 后面所有兄弟节点的中class=".seq"的HTML的内容自减 1  
204 - function nextAllChildSeqMinusOne(theElement){  
205 - $.each(theElement.nextAll(),function(i,e){  
206 - $(".seq",e).html($(".seq",e).html() - 1);  
207 - });  
208 - }  
209 - // 保存左边空表格  
210 - var leftDivTemplate = $("#left_div table").clone(true);  
211 - // 把左边表格的格式复制到右边  
212 - $("#right_div").append(leftDivTemplate);  
213 - 1 +/**
  2 + *
  3 + * @JSName : common.js(运管功能公共js)
  4 + *
  5 + * @Author : bsth@lq
  6 + *
  7 + * @Description : TODO(运管功能公共js)
  8 + *
  9 + * @Data : 2016年6月29日 上午9:21:17
  10 + *
  11 + * @Version 公交调度系统BS版 0.1
  12 + *
  13 + */
  14 +
  15 +(function(){
  16 + /**
  17 + * 取得编码-公司map
  18 + * gsmap["5"] = 南汇公司
  19 + * gsmap["5_3"] = 芦潮港分公司
  20 + */
  21 + function getBusMap(){
  22 + // 取得公司信息,替换公司编码
  23 + var gsmap = {};
  24 + $get('/business/all', null, function(array){
  25 + $.each(array, function(i, gs){
  26 + var k = gs.upCode + '_' + gs.businessCode;
  27 + if(gs.upCode === '88'){
  28 + k = gs.businessCode;
  29 + }
  30 + gsmap[k] = gs.businessName;
  31 + });
  32 + });
  33 + return gsmap;
  34 + }
  35 + // 填充公司下拉框选择值
  36 + $get('/business/all', {upCode_eq: '88'}, function(array){
  37 +
  38 + // 公司下拉options属性值
  39 + var options = '<option value="">请选择...</option>';
  40 +
  41 + // 遍历array
  42 + $.each(array, function(i,d){
  43 +
  44 + options += '<option value="'+d.businessCode+'">'+d.businessName+'</option>';
  45 +
  46 + });
  47 +
  48 + // 填充公司下拉框options,并添加公司下拉框值改变事件setbrancheCompanySelectOptions
  49 + $('#companySelect').html(options).on('change', setbrancheCompanySelectOptions);
  50 +
  51 + });
  52 +
  53 + // 填充分公司下拉框选择值
  54 + function setbrancheCompanySelectOptions(){
  55 +
  56 + // 获取公司下拉框选择值
  57 + var businessCode = $('#companySelect').val();
  58 +
  59 + // 分公司下拉框options属性值
  60 + var options = '<option value="">请选择...</option>';
  61 +
  62 + // 如果公司选择为空则分公司为空 ; 否则查询出所属公司下的分公司名称和相应分公司代码
  63 + if(businessCode == null || businessCode ==''){
  64 +
  65 + // 填充分公司下拉框options
  66 + $('#brancheCompanySelect').html(options);
  67 +
  68 + } else {
  69 +
  70 + // 查询出所属公司下的分公司名称和相应分公司代码
  71 + $get('/business/all', {upCode_eq: businessCode}, function(array){
  72 +
  73 + // 遍历array
  74 + $.each(array, function(i,d){
  75 +
  76 + options += '<option value="'+d.businessCode+'">'+d.businessName+'</option>';
  77 +
  78 + // 填充分公司下拉框options
  79 + $('#brancheCompanySelect').html(options);
  80 +
  81 + });
  82 + });
  83 +
  84 + // 填充公司下拉框options,并添加公司下拉框值改变事件setbrancheCompanySelectOptions
  85 + $('#brancheCompanySelect').html(options).on('change', setLineAutocompleteOptions);
  86 + }
  87 + }
  88 +
  89 + function setLineAutocompleteOptions(){
  90 + // 搜索参数集合
  91 + var params = {};
  92 + // 搜索字段名称
  93 + var name;
  94 + var items = $("ul.breadcrumb select");
  95 + // 遍历items集合
  96 + for(var j = 0, item; item = items[j++];){
  97 + // 获取字段名称
  98 + name = $(item).attr('name');
  99 + if(name){
  100 + // 赋取相对应的值
  101 + params[name] = $(item).val();
  102 + }
  103 + }
  104 + var lines = new Array();
  105 + var gsmap = getBusMap();
  106 + // 取得所有线路
  107 + $get('/line/all', params, function(allLine) {
  108 + // 遍历数组
  109 + $.each(allLine, function(i, e) {
  110 + var companyCode = e.company;
  111 + e.company = gsmap[e.company];
  112 + e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];
  113 + var line = '{"hex":"'+e.company+'","label":"'+e.name+'"}';
  114 + var obj = jQuery.parseJSON(line);
  115 + lines[i]= obj;
  116 + });
  117 +
  118 +
  119 + });
  120 + // 给输入框绑定autocomplete事件
  121 + $("input[name='name_eq']").autocompleter({
  122 + highlightMatches: true,
  123 + source: lines,
  124 + template: '{{ label }} <span>({{ hex }})</span>',
  125 + hint: true,
  126 + empty: false,
  127 + limit: 5,
  128 + });
  129 + }
  130 +
  131 +
  132 + // 设置autocompleter的宽度和输入框一样
  133 + $(".autocompleter").css("width",$("input[name='name_eq']").css("width"))
  134 + // 绑定查询事件
  135 + $("#search").click(searchM);
  136 + // 绑定上传事件
  137 + $("#upload").click(uploadM);
  138 + // 绑定全部移到右边事件
  139 + $("#to_right").click(function(){
  140 + $("#left_div tbody tr:not(.muted)").click();
  141 + });
  142 + // 绑定全部移到左边事件
  143 + $("#to_left").click(function(){
  144 + $("#right_div tbody tr:not(.muted)").click();
  145 + });
  146 + // 查询方法
  147 + function searchM() {
  148 + // 清空已选定列表
  149 + $("#right_div table tbody").empty();
  150 + var params = {};
  151 + // 取得输入框的值
  152 + var inputs = $("ul.breadcrumb input");
  153 + // 遍历数组
  154 + $.each(inputs, function(i, element) {
  155 + params[$(element).attr("name")] = $(element).val();
  156 + });
  157 + var i = layer.load(2);
  158 + $get('/line', params, function(data) {
  159 + var bodyHtm = template('lineStation_list_temp', {
  160 + list : data.content
  161 + });
  162 + $("#left_div table tbody").empty();
  163 + $("#left_div table tbody").append(bodyHtm);
  164 + $("#left_div tbody tr:not(.muted)").click(_click);
  165 + layer.close(i);
  166 + });
  167 + }
  168 +
  169 + // 上传方法
  170 + function uploadM() {
  171 + var params = {};
  172 + // 取得输入框的值
  173 + var trs = $("#right_div tbody tr");
  174 + if (trs.length == 0) {
  175 + alert("请选择模板");
  176 + return;
  177 + }
  178 + // 遍历数组
  179 + $.each(trs, function(i, element) {
  180 + alert($(".ttInfoId", element).html());
  181 + });
  182 + }
  183 +
  184 + // 表格行的单击事件
  185 + function _click() {
  186 + var tmpTr = $(this).clone();
  187 + tmpTr.unbind("click").click(_click);
  188 + // 判断父DIV的ID
  189 + if ($(this).closest(".table-container").attr("id") == "left_div") {
  190 + // 把要移动行的class=".seq"的HTML的内容设成另一分类的最后一个序号
  191 + $(".seq",tmpTr).html($("#right_div tbody tr:not(.muted)").length + 1);
  192 + $("#right_div tbody").append(tmpTr);
  193 + nextAllChildSeqMinusOne($(this));
  194 + } else {
  195 + // 把要移动行的class=".seq"的HTML的内容设成另一分类的最后一个序号
  196 + $(".seq",tmpTr).html($("#left_div tbody tr:not(.muted)").length + 1);
  197 + $("#left_div tbody").append(tmpTr);
  198 + nextAllChildSeqMinusOne($(this));
  199 + }
  200 + $(this).remove();
  201 + }
  202 +
  203 + // 后面所有兄弟节点的中class=".seq"的HTML的内容自减 1
  204 + function nextAllChildSeqMinusOne(theElement){
  205 + $.each(theElement.nextAll(),function(i,e){
  206 + $(".seq",e).html($(".seq",e).html() - 1);
  207 + });
  208 + }
  209 + // 保存左边空表格
  210 + var leftDivTemplate = $("#left_div table").clone(true);
  211 + // 把左边表格的格式复制到右边
  212 + $("#right_div").append(leftDivTemplate);
  213 +
214 })(); 214 })();
215 \ No newline at end of file 215 \ No newline at end of file
src/main/resources/static/pages/trafficManage/js/lineStationUploadRecord.js 0 → 100644
  1 +/**
  2 + *
  3 + * @JSName : common.js(运管功能公共js)
  4 + *
  5 + * @Author : bsth@lq
  6 + *
  7 + * @Description : TODO(运管功能公共js)
  8 + *
  9 + * @Data : 2016年6月29日 上午9:21:17
  10 + *
  11 + * @Version 公交调度系统BS版 0.1
  12 + *
  13 + */
  14 +
  15 +(function(){
  16 + // 关闭左侧栏
  17 + if (!$('body').hasClass('page-sidebar-closed'))
  18 + $('.menu-toggler.sidebar-toggler').click();
  19 + // 日期控件
  20 + $('#dateInput').datetimepicker({
  21 + // 日期控件时间格式
  22 + format : 'YYYY-MM-DD',
  23 + // 语言
  24 + locale: 'zh-cn'
  25 + });
  26 + // 日期范围输入框限制,绑定按键和粘贴事件
  27 + $(".dateRange").keyup(function(){
  28 + var tmptxt=$(this).val();
  29 + $(this).val(tmptxt.replace(/\D|^0/g,''));
  30 + if(tmptxt.length > 2){
  31 + $(this).val(tmptxt.substring(0,2));
  32 + }
  33 + if(tmptxt > 24){
  34 + $(this).val(24);
  35 + }
  36 + if(tmptxt < 0){
  37 + $(this).val(00);
  38 + }
  39 + }).bind("paste",function(){
  40 + var tmptxt=$(this).val();
  41 + $(this).val(tmptxt.replace(/\D|^0/g,''));
  42 + if(tmptxt.length > 2){
  43 + $(this).val(tmptxt.substring(0,2));
  44 + }
  45 + if(tmptxt > 24){
  46 + $(this).val(24);
  47 + }
  48 + if(tmptxt < 0){
  49 + $(this).val(00);
  50 + }
  51 + }).css("ime-mode", "disabled");
  52 + /**
  53 + * 取得编码-公司map
  54 + * gsmap["5"] = 南汇公司
  55 + * gsmap["5_3"] = 芦潮港分公司
  56 + */
  57 + function getBusMap(){
  58 + // 取得公司信息,替换公司编码
  59 + var gsmap = {};
  60 + $get('/business/all', null, function(array){
  61 + $.each(array, function(i, gs){
  62 + var k = gs.upCode + '_' + gs.businessCode;
  63 + if(gs.upCode === '88'){
  64 + k = gs.businessCode;
  65 + }
  66 + gsmap[k] = gs.businessName;
  67 + });
  68 + });
  69 + return gsmap;
  70 + }
  71 + /**
  72 + * 设置公司自动完成
  73 + */
  74 + var lines = new Array();
  75 + var gsmap = getBusMap();
  76 + // 取得所有线路
  77 + $get('/line/all', null, function(allLine) {
  78 + // 遍历数组
  79 + $.each(allLine, function(i, e) {
  80 + var companyCode = e.company;
  81 + e.company = gsmap[e.company];
  82 + e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];
  83 + var line = '{"hex":"' + e.company + '","label":"' + e.name
  84 + + '"}';
  85 + var obj = jQuery.parseJSON(line);
  86 + lines[i] = obj;
  87 + });
  88 + });
  89 + // 给输入框绑定autocomplete事件
  90 + $("input[name='xl.name_eq']").autocompleter({
  91 + highlightMatches : true,
  92 + source : lines,
  93 + template : '{{ label }} <span>({{ hex }})</span>',
  94 + hint : true,
  95 + empty : false,
  96 + limit : 5,
  97 + });
  98 + // 设置autocompleter的宽度和输入框一样
  99 + $(".autocompleter").css("width",
  100 + $("input[name='xl.name_eq']").css("width"));
  101 +
  102 + /**
  103 + * 设置内部编码自动完成
  104 + */
  105 + var cars = new Array();
  106 + // 取得所有车辆
  107 + $get('/cars/all', null, function(allCars) {
  108 + // 遍历数组
  109 + $.each(allCars, function(i, e) {
  110 + var car = '{"hex":"' + e.insideCode + '","label":"' + e.insideCode
  111 + + '"}';
  112 + var obj = jQuery.parseJSON(car);
  113 + cars[i] = obj;
  114 + });
  115 + });
  116 + // 给输入框绑定autocomplete事件
  117 + $("input[name='xl.insideCode_eq']").autocompleter({
  118 + highlightMatches : true,
  119 + source : cars,
  120 + template : '{{ label }}',
  121 + hint : true,
  122 + empty : false,
  123 + limit : 5,
  124 + });
  125 + // 设置autocompleter的宽度和输入框一样
  126 + $(".autocompleter").css("width",
  127 + $("input[name='xl.insideCode_eq']").css("width"));
  128 +})();
0 \ No newline at end of file 129 \ No newline at end of file
src/main/resources/static/pages/trafficManage/js/shLineCodeList.js
1 -/**  
2 - *  
3 - * @JSName : common.js(运管功能公共js)  
4 - *  
5 - * @Author : bsth@lq  
6 - *  
7 - * @Description : TODO(运管功能公共js)  
8 - *  
9 - * @Data : 2016年6月29日 上午9:21:17  
10 - *  
11 - * @Version 公交调度系统BS版 0.1  
12 - *  
13 - */  
14 -  
15 -(function(){  
16 - /**  
17 - * 取得编码-公司map  
18 - * gsmap["5"] = 南汇公司  
19 - * gsmap["5_3"] = 芦潮港分公司  
20 - */  
21 - function getBusMap(){  
22 - // 取得公司信息,替换公司编码  
23 - var gsmap = {};  
24 - $get('/business/all', null, function(array){  
25 - $.each(array, function(i, gs){  
26 - var k = gs.upCode + '_' + gs.businessCode;  
27 - if(gs.upCode === '88'){  
28 - k = gs.businessCode;  
29 - }  
30 - gsmap[k] = gs.businessName;  
31 - });  
32 - });  
33 - return gsmap;  
34 - }  
35 - var lines = new Array();  
36 - var gsmap = getBusMap();  
37 - // 取得所有线路  
38 - $get('/line/all', null, function(allLine) {  
39 - // 遍历数组  
40 - $.each(allLine, function(i, e) {  
41 - var companyCode = e.company;  
42 - e.company = gsmap[e.company];  
43 - e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];  
44 - var line = '{"hex":"' + e.company + '","label":"' + e.name  
45 - + '"}';  
46 - var obj = jQuery.parseJSON(line);  
47 - lines[i] = obj;  
48 - });  
49 - });  
50 - // 给输入框绑定autocomplete事件  
51 - $("input[name='name_like']").autocompleter({  
52 - highlightMatches : true,  
53 - source : lines,  
54 - template : '{{ label }} <span>({{ hex }})</span>',  
55 - hint : true,  
56 - empty : false,  
57 - limit : 5,  
58 - });  
59 - // 设置autocompleter的宽度和输入框一样  
60 - $(".autocompleter").css("width",  
61 - $("input[name='name_like']").css("width"))  
62 - /**  
63 - * -----page : 当前页  
64 - *  
65 - * -----initPag :  
66 - *  
67 - */  
68 - var page = 0,initPag;  
69 - // 绑定查询事件  
70 - $("#search").click(searchM);  
71 - // 查询方法  
72 - function searchM() {  
73 - // 搜索参数集合  
74 - var params = {};  
75 - // 取得输入框的值  
76 - var inputs = $("ul.breadcrumb input");  
77 - // 遍历数组  
78 - $.each(inputs, function(i, element) {  
79 - params[$(element).attr("name")] = $(element).val();  
80 - });  
81 - page = 0;  
82 -  
83 - loadTableDate(params,true);  
84 - }  
85 -  
86 - /**  
87 - * 表格数据分页加载事件  
88 - *  
89 - * ------@param : 查询参数  
90 - *  
91 - * ------@isPon : 是否重新分页  
92 - *  
93 - */  
94 - function loadTableDate(param,isPon){  
95 - // 搜索参数  
96 - var params = {};  
97 - if(param)  
98 - params = param;  
99 - // 排序(按更新时间)  
100 - params['order'] = 'id';  
101 - // 记录当前页数  
102 - params['page'] = page;  
103 - // 弹出正在加载层  
104 - var i = layer.load(2);  
105 - // 异步请求获取表格数据  
106 - $.get('/line',params,function(result){  
107 - // 遍历数组  
108 - $.each(result.content, function(i, e) {  
109 - var companyCode = e.company;  
110 - e.company = gsmap[e.company];  
111 - e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];  
112 - });  
113 - // 把数据填充到模版中  
114 - var tbodyHtml = template('shLineCode_list_temp',{list:result.content});  
115 - // 把渲染好的模版html文本追加到表格中  
116 - $('.table-container tbody').html(tbodyHtml);  
117 - // 是重新分页且返回数据长度大于0  
118 - if(isPon && result.content.length > 0){  
119 - // 重新分页  
120 - initPag = true;  
121 - // 分页栏  
122 - showPagination(result);  
123 - }  
124 - // 关闭弹出加载层  
125 - layer.close(i);  
126 - });  
127 - }  
128 -  
129 - /**  
130 - * 分页栏组件  
131 - *  
132 - */  
133 - function showPagination(data){  
134 - // 分页组件  
135 - $('#pagination').jqPaginator({  
136 - // 总页数  
137 - totalPages: data.totalPages,  
138 - // 中间显示页数  
139 - visiblePages: 6,  
140 - // 当前页  
141 - currentPage: page + 1,  
142 - first: '<li class="first"><a href="javascript:void(0);">首页<\/a><\/li>',  
143 - prev: '<li class="prev"><a href="javascript:void(0);">上一页<\/a><\/li>',  
144 - next: '<li class="next"><a href="javascript:void(0);">下一页<\/a><\/li>',  
145 - last: '<li class="last"><a href="javascript:void(0);">尾页<\/a><\/li>',  
146 - page: '<li class="page"><a href="javascript:void(0);">{{page}}<\/a><\/li>',  
147 - onPageChange: function (num, type) {  
148 - if(initPag){  
149 - initPag = false;  
150 - return;  
151 - }  
152 - page = num - 1;  
153 - loadTableDate(null, false);  
154 - }  
155 - });  
156 - }  
157 - 1 +/**
  2 + *
  3 + * @JSName : common.js(运管功能公共js)
  4 + *
  5 + * @Author : bsth@lq
  6 + *
  7 + * @Description : TODO(运管功能公共js)
  8 + *
  9 + * @Data : 2016年6月29日 上午9:21:17
  10 + *
  11 + * @Version 公交调度系统BS版 0.1
  12 + *
  13 + */
  14 +
  15 +(function(){
  16 + /**
  17 + * 取得编码-公司map
  18 + * gsmap["5"] = 南汇公司
  19 + * gsmap["5_3"] = 芦潮港分公司
  20 + */
  21 + function getBusMap(){
  22 + // 取得公司信息,替换公司编码
  23 + var gsmap = {};
  24 + $get('/business/all', null, function(array){
  25 + $.each(array, function(i, gs){
  26 + var k = gs.upCode + '_' + gs.businessCode;
  27 + if(gs.upCode === '88'){
  28 + k = gs.businessCode;
  29 + }
  30 + gsmap[k] = gs.businessName;
  31 + });
  32 + });
  33 + return gsmap;
  34 + }
  35 + var lines = new Array();
  36 + var gsmap = getBusMap();
  37 + // 取得所有线路
  38 + $get('/line/all', null, function(allLine) {
  39 + // 遍历数组
  40 + $.each(allLine, function(i, e) {
  41 + var companyCode = e.company;
  42 + e.company = gsmap[e.company];
  43 + e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];
  44 + var line = '{"hex":"' + e.company + '","label":"' + e.name
  45 + + '"}';
  46 + var obj = jQuery.parseJSON(line);
  47 + lines[i] = obj;
  48 + });
  49 + });
  50 + // 给输入框绑定autocomplete事件
  51 + $("input[name='name_like']").autocompleter({
  52 + highlightMatches : true,
  53 + source : lines,
  54 + template : '{{ label }} <span>({{ hex }})</span>',
  55 + hint : true,
  56 + empty : false,
  57 + limit : 5,
  58 + });
  59 + // 设置autocompleter的宽度和输入框一样
  60 + $(".autocompleter").css("width",
  61 + $("input[name='name_like']").css("width"))
  62 + /**
  63 + * -----page : 当前页
  64 + *
  65 + * -----initPag :
  66 + *
  67 + */
  68 + var page = 0,initPag;
  69 + // 绑定查询事件
  70 + $("#search").click(searchM);
  71 + // 查询方法
  72 + function searchM() {
  73 + // 搜索参数集合
  74 + var params = {};
  75 + // 取得输入框的值
  76 + var inputs = $("ul.breadcrumb input");
  77 + // 遍历数组
  78 + $.each(inputs, function(i, element) {
  79 + params[$(element).attr("name")] = $(element).val();
  80 + });
  81 + page = 0;
  82 +
  83 + loadTableDate(params,true);
  84 + }
  85 +
  86 + /**
  87 + * 表格数据分页加载事件
  88 + *
  89 + * ------@param : 查询参数
  90 + *
  91 + * ------@isPon : 是否重新分页
  92 + *
  93 + */
  94 + function loadTableDate(param,isPon){
  95 + // 搜索参数
  96 + var params = {};
  97 + if(param)
  98 + params = param;
  99 + // 排序(按更新时间)
  100 + params['order'] = 'id';
  101 + // 记录当前页数
  102 + params['page'] = page;
  103 + // 弹出正在加载层
  104 + var i = layer.load(2);
  105 + // 异步请求获取表格数据
  106 + $.get('/line',params,function(result){
  107 + // 遍历数组
  108 + $.each(result.content, function(i, e) {
  109 + var companyCode = e.company;
  110 + e.company = gsmap[e.company];
  111 + e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];
  112 + });
  113 + // 把数据填充到模版中
  114 + var tbodyHtml = template('shLineCode_list_temp',{list:result.content});
  115 + // 把渲染好的模版html文本追加到表格中
  116 + $('.table-container tbody').html(tbodyHtml);
  117 + // 是重新分页且返回数据长度大于0
  118 + if(isPon && result.content.length > 0){
  119 + // 重新分页
  120 + initPag = true;
  121 + // 分页栏
  122 + showPagination(result);
  123 + }
  124 + // 关闭弹出加载层
  125 + layer.close(i);
  126 + });
  127 + }
  128 +
  129 + /**
  130 + * 分页栏组件
  131 + *
  132 + */
  133 + function showPagination(data){
  134 + // 分页组件
  135 + $('#pagination').jqPaginator({
  136 + // 总页数
  137 + totalPages: data.totalPages,
  138 + // 中间显示页数
  139 + visiblePages: 6,
  140 + // 当前页
  141 + currentPage: page + 1,
  142 + first: '<li class="first"><a href="javascript:void(0);">首页<\/a><\/li>',
  143 + prev: '<li class="prev"><a href="javascript:void(0);">上一页<\/a><\/li>',
  144 + next: '<li class="next"><a href="javascript:void(0);">下一页<\/a><\/li>',
  145 + last: '<li class="last"><a href="javascript:void(0);">尾页<\/a><\/li>',
  146 + page: '<li class="page"><a href="javascript:void(0);">{{page}}<\/a><\/li>',
  147 + onPageChange: function (num, type) {
  148 + if(initPag){
  149 + initPag = false;
  150 + return;
  151 + }
  152 + page = num - 1;
  153 + loadTableDate(null, false);
  154 + }
  155 + });
  156 + }
  157 +
158 })(); 158 })();
159 \ No newline at end of file 159 \ No newline at end of file
src/main/resources/static/pages/trafficManage/js/timeTempletUpload.js
1 -/**  
2 - *  
3 - * @JSName : common.js(运管功能公共js)  
4 - *  
5 - * @Author : bsth@lq  
6 - *  
7 - * @Description : TODO(运管功能公共js)  
8 - *  
9 - * @Data : 2016年6月29日 上午9:21:17  
10 - *  
11 - * @Version 公交调度系统BS版 0.1  
12 - *  
13 - */  
14 -  
15 -(function(){  
16 - /**  
17 - * 取得编码-公司map  
18 - * gsmap["5"] = 南汇公司  
19 - * gsmap["5_3"] = 芦潮港分公司  
20 - */  
21 - function getBusMap(){  
22 - // 取得公司信息,替换公司编码  
23 - var gsmap = {};  
24 - $get('/business/all', null, function(array){  
25 - $.each(array, function(i, gs){  
26 - var k = gs.upCode + '_' + gs.businessCode;  
27 - if(gs.upCode === '88'){  
28 - k = gs.businessCode;  
29 - }  
30 - gsmap[k] = gs.businessName;  
31 - });  
32 - });  
33 - return gsmap;  
34 - }  
35 - var lines = new Array();  
36 - var gsmap = getBusMap();  
37 - console.log(gsmap);  
38 - // 取得所有线路  
39 - $get('/line/all', null, function(allLine) {  
40 - // 遍历数组  
41 - $.each(allLine, function(i, e) {  
42 - var companyCode = e.company;  
43 - e.company = gsmap[e.company];  
44 - e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];  
45 - var line = '{"hex":"' + e.company + '","label":"' + e.name  
46 - + '"}';  
47 - var obj = jQuery.parseJSON(line);  
48 - lines[i] = obj;  
49 - });  
50 - });  
51 - // 给输入框绑定autocomplete事件  
52 - $("input[name='xl.name_eq']").autocompleter({  
53 - highlightMatches : true,  
54 - source : lines,  
55 - template : '{{ label }} <span>({{ hex }})</span>',  
56 - hint : true,  
57 - empty : false,  
58 - limit : 5,  
59 - });  
60 - // 设置autocompleter的宽度和输入框一样  
61 - $(".autocompleter").css("width",  
62 - $("input[name='xl.name_eq']").css("width"))  
63 - // 绑定查询事件  
64 - $("#search").click(searchM);  
65 - // 绑定上传事件  
66 - $("#upload").click(uploadM);  
67 - // 绑定全部移到右边事件  
68 - $("#to_right").click(function() {  
69 - $("#left_div tbody tr:not(.muted)").click();  
70 - });  
71 - // 绑定全部移到左边事件  
72 - $("#to_left").click(function() {  
73 - $("#right_div tbody tr:not(.muted)").click();  
74 - });  
75 - // 查询方法  
76 - function searchM() {  
77 - // 清空已选定列表  
78 - $("#right_div table tbody").empty();  
79 - var params = {};  
80 - // 取得输入框的值  
81 - var inputs = $("ul.breadcrumb input");  
82 - // 遍历数组  
83 - $.each(inputs, function(i, element) {  
84 - params[$(element).attr("name")] = $(element).val();  
85 - });  
86 - var i = layer.load(2);  
87 - $get('/spc', params, function(data) {  
88 - _dateFormat(data.content);  
89 - var bodyHtm = template('timeTemplet_list_temp', {  
90 - list : data.content  
91 - });  
92 - $("#left_div table tbody").empty();  
93 - $("#left_div table tbody").append(bodyHtm);  
94 - $("#left_div tbody tr:not(.muted)").click(_click);  
95 - layer.close(i);  
96 - });  
97 - }  
98 -  
99 - // 上传方法  
100 - function uploadM() {  
101 - var params = {};  
102 - // 取得输入框的值  
103 - var trs = $("#right_div tbody tr");  
104 - if (trs.length == 0) {  
105 - alert("请选择模板");  
106 - return;  
107 - }  
108 - // 遍历数组  
109 - $.each(trs, function(i, element) {  
110 - alert($(".ttInfoId", element).html());  
111 - });  
112 - }  
113 -  
114 - // 表格行的单击事件  
115 - function _click() {  
116 - var tmpTr = $(this).clone();  
117 - tmpTr.unbind("click").click(_click);  
118 - // 判断父DIV的ID  
119 - if ($(this).closest(".table-container").attr("id") == "left_div") {  
120 - // 把要移动行的class=".seq"的HTML的内容设成另一分类的最后一个序号  
121 - $(".seq", tmpTr).html(  
122 - $("#right_div tbody tr:not(.muted)").length + 1);  
123 - $("#right_div tbody").append(tmpTr);  
124 - nextAllChildSeqMinusOne($(this));  
125 - } else {  
126 - // 把要移动行的class=".seq"的HTML的内容设成另一分类的最后一个序号  
127 - $(".seq", tmpTr).html(  
128 - $("#left_div tbody tr:not(.muted)").length + 1);  
129 - $("#left_div tbody").append(tmpTr);  
130 - nextAllChildSeqMinusOne($(this));  
131 - }  
132 - $(this).remove();  
133 - }  
134 -  
135 - // 后面所有兄弟节点的中class=".seq"的HTML的内容自减 1  
136 - function nextAllChildSeqMinusOne(theElement) {  
137 - $.each(theElement.nextAll(), function(i, e) {  
138 - $(".seq", e).html($(".seq", e).html() - 1);  
139 - });  
140 - }  
141 - // 保存左边空表格  
142 - var leftDivTemplate = $("#left_div table").clone(true);  
143 - // 把左边表格的格式复制到右边  
144 - $("#right_div").append(leftDivTemplate);  
145 - //转换时间格式  
146 - function _dateFormat(list) {  
147 - var fs = 'YYYY-MM-DD HH:mm';  
148 - $.each(list, function(i, obj) {  
149 - obj.ttInfo.qyrq = moment(obj.ttInfo.qyrq).format(fs);  
150 - });  
151 - } 1 +/**
  2 + *
  3 + * @JSName : common.js(运管功能公共js)
  4 + *
  5 + * @Author : bsth@lq
  6 + *
  7 + * @Description : TODO(运管功能公共js)
  8 + *
  9 + * @Data : 2016年6月29日 上午9:21:17
  10 + *
  11 + * @Version 公交调度系统BS版 0.1
  12 + *
  13 + */
  14 +
  15 +(function(){
  16 + /**
  17 + * 取得编码-公司map
  18 + * gsmap["5"] = 南汇公司
  19 + * gsmap["5_3"] = 芦潮港分公司
  20 + */
  21 + function getBusMap(){
  22 + // 取得公司信息,替换公司编码
  23 + var gsmap = {};
  24 + $get('/business/all', null, function(array){
  25 + $.each(array, function(i, gs){
  26 + var k = gs.upCode + '_' + gs.businessCode;
  27 + if(gs.upCode === '88'){
  28 + k = gs.businessCode;
  29 + }
  30 + gsmap[k] = gs.businessName;
  31 + });
  32 + });
  33 + return gsmap;
  34 + }
  35 + var lines = new Array();
  36 + var gsmap = getBusMap();
  37 + // 取得所有线路
  38 + $get('/line/all', null, function(allLine) {
  39 + // 遍历数组
  40 + $.each(allLine, function(i, e) {
  41 + var companyCode = e.company;
  42 + e.company = gsmap[e.company];
  43 + e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];
  44 + var line = '{"hex":"' + e.company + '","label":"' + e.name
  45 + + '"}';
  46 + var obj = jQuery.parseJSON(line);
  47 + lines[i] = obj;
  48 + });
  49 + });
  50 + // 给输入框绑定autocomplete事件
  51 + $("input[name='xl.name_eq']").autocompleter({
  52 + highlightMatches : true,
  53 + source : lines,
  54 + template : '{{ label }} <span>({{ hex }})</span>',
  55 + hint : true,
  56 + empty : false,
  57 + limit : 5,
  58 + });
  59 + // 设置autocompleter的宽度和输入框一样
  60 + $(".autocompleter").css("width",
  61 + $("input[name='xl.name_eq']").css("width"));
  62 + // 绑定查询事件
  63 + $("#search").click(searchM);
  64 + // 绑定上传事件
  65 + $("#upload").click(uploadM);
  66 + // 绑定全部移到右边事件
  67 + $("#to_right").click(function() {
  68 + $("#left_div tbody tr:not(.muted)").click();
  69 + });
  70 + // 绑定全部移到左边事件
  71 + $("#to_left").click(function() {
  72 + $("#right_div tbody tr:not(.muted)").click();
  73 + });
  74 + // 查询方法
  75 + function searchM() {
  76 + // 清空已选定列表
  77 + $("#right_div table tbody").empty();
  78 + var params = {};
  79 + // 取得输入框的值
  80 + var inputs = $("ul.breadcrumb input");
  81 + // 遍历数组
  82 + $.each(inputs, function(i, element) {
  83 + params[$(element).attr("name")] = $(element).val();
  84 + });
  85 + var i = layer.load(2);
  86 + $get('/spc', params, function(data) {
  87 + _dateFormat(data.content);
  88 + var bodyHtm = template('timeTemplet_list_temp', {
  89 + list : data.content
  90 + });
  91 + $("#left_div table tbody").empty();
  92 + $("#left_div table tbody").append(bodyHtm);
  93 + $("#left_div tbody tr:not(.muted)").click(_click);
  94 + layer.close(i);
  95 + });
  96 + }
  97 +
  98 + // 上传方法
  99 + function uploadM() {
  100 + var params = {};
  101 + // 取得输入框的值
  102 + var trs = $("#right_div tbody tr");
  103 + if (trs.length == 0) {
  104 + alert("请选择模板");
  105 + return;
  106 + }
  107 + // 遍历数组
  108 + $.each(trs, function(i, element) {
  109 + alert($(".ttInfoId", element).html());
  110 + });
  111 + }
  112 +
  113 + // 表格行的单击事件
  114 + function _click() {
  115 + var tmpTr = $(this).clone();
  116 + tmpTr.unbind("click").click(_click);
  117 + // 判断父DIV的ID
  118 + if ($(this).closest(".table-container").attr("id") == "left_div") {
  119 + // 把要移动行的class=".seq"的HTML的内容设成另一分类的最后一个序号
  120 + $(".seq", tmpTr).html(
  121 + $("#right_div tbody tr:not(.muted)").length + 1);
  122 + $("#right_div tbody").append(tmpTr);
  123 + nextAllChildSeqMinusOne($(this));
  124 + } else {
  125 + // 把要移动行的class=".seq"的HTML的内容设成另一分类的最后一个序号
  126 + $(".seq", tmpTr).html(
  127 + $("#left_div tbody tr:not(.muted)").length + 1);
  128 + $("#left_div tbody").append(tmpTr);
  129 + nextAllChildSeqMinusOne($(this));
  130 + }
  131 + $(this).remove();
  132 + }
  133 +
  134 + // 后面所有兄弟节点的中class=".seq"的HTML的内容自减 1
  135 + function nextAllChildSeqMinusOne(theElement) {
  136 + $.each(theElement.nextAll(), function(i, e) {
  137 + $(".seq", e).html($(".seq", e).html() - 1);
  138 + });
  139 + }
  140 + // 保存左边空表格
  141 + var leftDivTemplate = $("#left_div table").clone(true);
  142 + // 把左边表格的格式复制到右边
  143 + $("#right_div").append(leftDivTemplate);
  144 + //转换时间格式
  145 + function _dateFormat(list) {
  146 + var fs = 'YYYY-MM-DD HH:mm';
  147 + $.each(list, function(i, obj) {
  148 + obj.ttInfo.qyrq = moment(obj.ttInfo.qyrq).format(fs);
  149 + });
  150 + }
152 })(); 151 })();
153 \ No newline at end of file 152 \ No newline at end of file
src/main/resources/static/pages/trafficManage/js/timeTempletUploadRecord.js 0 → 100644
  1 +/**
  2 + *
  3 + * @JSName : common.js(运管功能公共js)
  4 + *
  5 + * @Author : bsth@lq
  6 + *
  7 + * @Description : TODO(运管功能公共js)
  8 + *
  9 + * @Data : 2016年6月29日 上午9:21:17
  10 + *
  11 + * @Version 公交调度系统BS版 0.1
  12 + *
  13 + */
  14 +
  15 +(function(){
  16 + // 关闭左侧栏
  17 + if (!$('body').hasClass('page-sidebar-closed'))
  18 + $('.menu-toggler.sidebar-toggler').click();
  19 + // 填充公司下拉框选择值
  20 + $get('/business/all', {upCode_eq: '88'}, function(array){
  21 +
  22 + // 公司下拉options属性值
  23 + var options = '<option value="">请选择...</option>';
  24 +
  25 + // 遍历array
  26 + $.each(array, function(i,d){
  27 +
  28 + options += '<option value="'+d.businessCode+'">'+d.businessName+'</option>';
  29 +
  30 + });
  31 +
  32 + // 填充公司下拉框options,并添加公司下拉框值改变事件setbrancheCompanySelectOptions
  33 + $('#companySelect').html(options).on('change', setbrancheCompanySelectOptions);
  34 +
  35 + });
  36 +
  37 + // 填充分公司下拉框选择值
  38 + function setbrancheCompanySelectOptions(){
  39 +
  40 + // 获取公司下拉框选择值
  41 + var businessCode = $('#companySelect').val();
  42 +
  43 + // 分公司下拉框options属性值
  44 + var options = '<option value="">请选择...</option>';
  45 +
  46 + // 如果公司选择为空则分公司为空 ; 否则查询出所属公司下的分公司名称和相应分公司代码
  47 + if(businessCode == null || businessCode ==''){
  48 +
  49 + // 填充分公司下拉框options
  50 + $('#brancheCompanySelect').html(options);
  51 +
  52 + } else {
  53 +
  54 + // 查询出所属公司下的分公司名称和相应分公司代码
  55 + $get('/business/all', {upCode_eq: businessCode}, function(array){
  56 +
  57 + // 遍历array
  58 + $.each(array, function(i,d){
  59 +
  60 + options += '<option value="'+d.businessCode+'">'+d.businessName+'</option>';
  61 +
  62 + // 填充分公司下拉框options
  63 + $('#brancheCompanySelect').html(options);
  64 +
  65 + });
  66 + });
  67 +
  68 + // 填充公司下拉框options,并添加公司下拉框值改变事件setbrancheCompanySelectOptions
  69 + $('#brancheCompanySelect').html(options).on('change', setLineAutocompleteOptions);
  70 + }
  71 + }
  72 + // 日期控件
  73 + $('#dateInput').datetimepicker({
  74 + // 日期控件时间格式
  75 + format : 'YYYY-MM-DD',
  76 + // 语言
  77 + locale: 'zh-cn'
  78 + });
  79 + // 日期范围输入框限制,绑定按键和粘贴事件
  80 + $(".dateRange").keyup(function(){
  81 + var tmptxt=$(this).val();
  82 + $(this).val(tmptxt.replace(/\D|^0/g,''));
  83 + if(tmptxt.length > 2){
  84 + $(this).val(tmptxt.substring(0,2));
  85 + }
  86 + if(tmptxt > 24){
  87 + $(this).val(24);
  88 + }
  89 + if(tmptxt < 0){
  90 + $(this).val(00);
  91 + }
  92 + }).bind("paste",function(){
  93 + var tmptxt=$(this).val();
  94 + $(this).val(tmptxt.replace(/\D|^0/g,''));
  95 + if(tmptxt.length > 2){
  96 + $(this).val(tmptxt.substring(0,2));
  97 + }
  98 + if(tmptxt > 24){
  99 + $(this).val(24);
  100 + }
  101 + if(tmptxt < 0){
  102 + $(this).val(00);
  103 + }
  104 + }).css("ime-mode", "disabled");
  105 + /**
  106 + * 取得编码-公司map
  107 + * gsmap["5"] = 南汇公司
  108 + * gsmap["5_3"] = 芦潮港分公司
  109 + */
  110 + function getBusMap(){
  111 + // 取得公司信息,替换公司编码
  112 + var gsmap = {};
  113 + $get('/business/all', null, function(array){
  114 + $.each(array, function(i, gs){
  115 + var k = gs.upCode + '_' + gs.businessCode;
  116 + if(gs.upCode === '88'){
  117 + k = gs.businessCode;
  118 + }
  119 + gsmap[k] = gs.businessName;
  120 + });
  121 + });
  122 + return gsmap;
  123 + }
  124 + /**
  125 + * 设置公司自动完成
  126 + */
  127 + var lines = new Array();
  128 + var gsmap = getBusMap();
  129 + // 取得所有线路
  130 + $get('/line/all', null, function(allLine) {
  131 + // 遍历数组
  132 + $.each(allLine, function(i, e) {
  133 + var companyCode = e.company;
  134 + e.company = gsmap[e.company];
  135 + e.brancheCompany = gsmap[companyCode+"_"+e.brancheCompany];
  136 + var line = '{"hex":"' + e.company + '","label":"' + e.name
  137 + + '"}';
  138 + var obj = jQuery.parseJSON(line);
  139 + lines[i] = obj;
  140 + });
  141 + });
  142 + // 给输入框绑定autocomplete事件
  143 + $("input[name='xl.name_eq']").autocompleter({
  144 + highlightMatches : true,
  145 + source : lines,
  146 + template : '{{ label }} <span>({{ hex }})</span>',
  147 + hint : true,
  148 + empty : false,
  149 + limit : 5,
  150 + });
  151 + // 设置autocompleter的宽度和输入框一样
  152 + $(".autocompleter").css("width",
  153 + $("input[name='xl.name_eq']").css("width"));
  154 +})();
0 \ No newline at end of file 155 \ No newline at end of file
src/main/resources/static/pages/trafficManage/lineStationUpload.html
1 -<link href="css/trafficManage.css" rel="stylesheet" type="text/css" />  
2 -<link href="css/autocompleter.css" rel="stylesheet" type="text/css" />  
3 -<ul class="page-breadcrumb breadcrumb">  
4 - <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li>  
5 - <li><span class="active">运维管理</span> <i class="fa fa-circle"></i></li>  
6 - <li><span class="active">线路停靠站上传</span></li>  
7 -</ul>  
8 -<div class="tab_line">  
9 - <div class="col-md-12">  
10 - <ul class="breadcrumb">  
11 - <li>公司:</li>  
12 - <li><select name="company_eq" class="form-control" id="companySelect"></select></li>  
13 - <li>分公司:</li>  
14 - <li><select name="brancheCompany_eq" class="form-control" id="brancheCompanySelect"></select></li>  
15 - <li>线路名称:</li>  
16 - <li><input type="text" class="form-control form-filter input-sm"  
17 - name="name_eq" placeholder="请输入线路名称" maxlength="40" /></li>  
18 - <li><a class="btn btn-circle blue" id="search">查询</a></li>  
19 - <li><a class="btn btn-circle red" id="upload">上传</a></li>  
20 - </ul>  
21 - </div>  
22 - <!-- Begin: left-div -->  
23 - <div class="col-md-5 panel-wrap" style="height: 60%;">  
24 - <div class="_panel">  
25 - <div class="_head" style="color: #2765A7;">待选上传站点线路列表</div>  
26 - <div class="table-container" id="left_div">  
27 - <table  
28 - class="table table-striped table-bordered table-advance pb-table head">  
29 - <thead>  
30 - <tr>  
31 - <th width="5%">#</th>  
32 - <th width="20%">线路编码</th>  
33 - <th width="15%">线路名称</th>  
34 - </tr>  
35 - </thead>  
36 - <tbody>  
37 - </tbody>  
38 - </table>  
39 - </div>  
40 - </div>  
41 - </div>  
42 - <div class="col-md-2" style="height: 60%;">  
43 - <ul class="breadcruma divVerHorCenter">  
44 - <li><a class="btn btn-circle blue btn-outline" id="to_right">>></a></li>  
45 - <li><a class="btn btn-circle blue btn-outline" id="to_left"><<</a></li>  
46 - </ul>  
47 - </div>  
48 - <!-- End: left-div -->  
49 - <!-- Begin: right-div -->  
50 - <div class="col-md-5 panel-wrap" style="height: 60%;">  
51 - <div class="_panel">  
52 - <div class="_head" style="color: #2765A7;">已选上传站点线路列表</div>  
53 - <div class="table-container" id="right_div"></div>  
54 - </div>  
55 - </div>  
56 - <!-- End: right-div -->  
57 -</div>  
58 -<script id="lineStation_list_temp" type="text/html">  
59 -{{each list as obj i}}  
60 -<tr>  
61 - <td class="seq" style="vertical-align: middle;">  
62 - {{i+1}}  
63 - </td>  
64 - <td>  
65 - {{obj.lineCode}}  
66 - </td>  
67 - <td class="ttInfoId">  
68 - {{obj.name}}  
69 - </td>  
70 -</tr>  
71 -{{/each}}  
72 -{{if list.length == 0}}  
73 -<tr class="muted">  
74 - <td colspan=5 style="text-align: center;"><h6>没有找到相关数据</h6></td>  
75 -</tr>  
76 -{{/if}}  
77 - </script>  
78 -<script src="./js/lineStationUpload.js"></script> 1 +<link href="css/trafficManage.css" rel="stylesheet" type="text/css" />
  2 +<link href="css/autocompleter.css" rel="stylesheet" type="text/css" />
  3 +<ul class="page-breadcrumb breadcrumb">
  4 + <li><a href="/pages/home.html" data-pjax>首页</a> <i class="fa fa-circle"></i></li>
  5 + <li><span class="active">运维管理</span> <i class="fa fa-circle"></i></li>
  6 + <li><span class="active">线路停靠站上传</span></li>
  7 +</ul>
  8 +<div class="tab_line">
  9 + <div class="col-md-12">
  10 + <ul class="breadcrumb">
  11 + <li>公司:</li>
  12 + <li><select name="company_eq" class="form-control" id="companySelect"></select></li>
  13 + <li>分公司:</li>
  14 + <li><select name="brancheCompany_eq" class="form-control" id="brancheCompanySelect"></select></li>
  15 + <li>线路名称:</li>
  16 + <li><input type="text" class="form-control form-filter input-sm"
  17 + name="name_eq" placeholder="请输入线路名称" maxlength="40" /></li>
  18 + <li><a class="btn btn-circle blue" id="search">查询</a></li>
  19 + <li><a class="btn btn-circle red" id="upload">上传</a></li>
  20 + </ul>
  21 + </div>
  22 + <!-- Begin: left-div -->
  23 + <div class="col-md-5 panel-wrap" style="height: 60%;">
  24 + <div class="_panel">
  25 + <div class="_head" style="color: #2765A7;">待选上传站点线路列表</div>
  26 + <div class="table-container" id="left_div">
  27 + <table
  28 + class="table table-striped table-bordered table-advance pb-table head">
  29 + <thead>
  30 + <tr>
  31 + <th width="5%">#</th>
  32 + <th width="20%">线路编码</th>
  33 + <th width="15%">线路名称</th>
  34 + </tr>
  35 + </thead>
  36 + <tbody>
  37 + </tbody>
  38 + </table>
  39 + </div>
  40 + </div>
  41 + </div>
  42 + <div class="col-md-2" style="height: 60%;">
  43 + <ul class="breadcruma divVerHorCenter">
  44 + <li><a class="btn btn-circle blue btn-outline" id="to_right">>></a></li>
  45 + <li><a class="btn btn-circle blue btn-outline" id="to_left"><<</a></li>
  46 + </ul>
  47 + </div>
  48 + <!-- End: left-div -->
  49 + <!-- Begin: right-div -->
  50 + <div class="col-md-5 panel-wrap" style="height: 60%;">
  51 + <div class="_panel">
  52 + <div class="_head" style="color: #2765A7;">已选上传站点线路列表</div>
  53 + <div class="table-container" id="right_div"></div>
  54 + </div>
  55 + </div>
  56 + <!-- End: right-div -->
  57 +</div>
  58 +<script id="lineStation_list_temp" type="text/html">
  59 +{{each list as obj i}}
  60 +<tr>
  61 + <td class="seq" style="vertical-align: middle;">
  62 + {{i+1}}
  63 + </td>
  64 + <td>
  65 + {{obj.lineCode}}
  66 + </td>
  67 + <td class="ttInfoId">
  68 + {{obj.name}}
  69 + </td>
  70 +</tr>
  71 +{{/each}}
  72 +{{if list.length == 0}}
  73 +<tr class="muted">
  74 + <td colspan=5 style="text-align: center;"><h6>没有找到相关数据</h6></td>
  75 +</tr>
  76 +{{/if}}
  77 + </script>
  78 +<script src="./js/lineStationUpload.js"></script>
src/main/resources/static/pages/trafficManage/lineStationUploadRecord.html 0 → 100644
  1 +<link href="css/trafficManage.css" rel="stylesheet" type="text/css" />
  2 +<link href="css/autocompleter.css" rel="stylesheet" type="text/css" />
  3 +<ul class="page-breadcrumb breadcrumb">
  4 + <li><a href="/pages/home.html" data-pjax>首页</a> <i
  5 + class="fa fa-circle"></i></li>
  6 + <li><span class="active">运维管理</span> <i class="fa fa-circle"></i></li>
  7 + <li><span class="active">车载上报停靠站</span></li>
  8 +</ul>
  9 +<div class="tab_line">
  10 + <div class="col-md-12">
  11 + <ul class="breadcrumb">
  12 + <li>筛选数据:</li>
  13 + <li>日期:</li>
  14 + <li><input type="text" class="inputCommon dateTime" name="date" id="dateInput" placeholder="日期"></li>
  15 + <li>时间范围:</li>
  16 + <li><input type="text" class="inputCommon dateRange" name="startDate">至
  17 + <input type="text" class="inputCommon dateRange" name="endDate">时</li>
  18 + <li>线路名称:</li>
  19 + <li><input type="text" class="form-control form-filter input-sm"
  20 + name="xl.name_eq" maxlength="40" /></li>
  21 + <li>内部编码:</li>
  22 + <li><input type="text" class="form-control form-filter input-sm"
  23 + name="xl.insideCode_eq" maxlength="40" /></li>
  24 + <li>车牌号:</li>
  25 + <li><input type="text" class="inputCommon inputCarPlate"
  26 + name="xl.carPlate_eq" maxlength="40" /></li>
  27 + <li><a class="btn btn-circle blue" id="search">筛选</a></li>
  28 + </ul>
  29 + </div>
  30 + <div class="col-md-12 panel-wrap">
  31 + <div class="_panel">
  32 + <div class="table-container">
  33 + <table
  34 + class="table table-striped table-bordered table-advance pb-table head">
  35 + <thead>
  36 + <tr>
  37 + <th>序号</th>
  38 + <th>公司</th>
  39 + <th>分公司</th>
  40 + <th>线路</th>
  41 + <th>上海市线路编码</th>
  42 + <th>内部编码</th>
  43 + <th>设备编码</th>
  44 + <th>车牌</th>
  45 + <th>站点序号</th>
  46 + <th>营运状态</th>
  47 + <th>上下行</th>
  48 + <th>站内外</th>
  49 + <th>上报时间</th>
  50 + </tr>
  51 + </thead>
  52 + <tbody>
  53 + </tbody>
  54 + </table>
  55 + <div style="text-align: right;">
  56 + <ul id="pagination" class="pagination"></ul>
  57 + </div>
  58 + </div>
  59 + </div>
  60 + </div>
  61 +</div>
  62 +<script id="lineStationRecord_list_temp" type="text/html">
  63 +{{each list as obj i}}
  64 +<tr>
  65 + <td class="seq" style="vertical-align: middle;">
  66 + {{i+1}}
  67 + </td>
  68 + <td>
  69 + {{obj.name}}
  70 + </td>
  71 + <td class="ttInfoId">
  72 + {{obj.company}}
  73 + </td>
  74 + <td>
  75 +
  76 + </td>
  77 + <td >
  78 +
  79 + </td>
  80 + <td>
  81 + {{obj.name}}
  82 + </td>
  83 + <td>
  84 + {{obj.company}}
  85 + </td>
  86 + <td>
  87 +
  88 + </td>
  89 + <td >
  90 +
  91 + </td>
  92 + <td>
  93 + {{obj.name}}
  94 + </td>
  95 + <td>
  96 + {{obj.company}}
  97 + </td>
  98 + <td>
  99 +
  100 + </td>
  101 + <td >
  102 +
  103 + </td>
  104 +</tr>
  105 +{{/each}}
  106 +{{if list.length == 0}}
  107 +<tr class="muted">
  108 + <td colspan=5 style="text-align: center;"><h6>没有找到相关数据</h6></td>
  109 +</tr>
  110 +{{/if}}
  111 + </script>
  112 +<script src="./js/lineStationUploadRecord.js"></script>
0 \ No newline at end of file 113 \ No newline at end of file
src/main/resources/static/pages/trafficManage/shLineCodeList.html
1 -<link href="css/trafficManage.css" rel="stylesheet" type="text/css" />  
2 -<link href="css/autocompleter.css" rel="stylesheet" type="text/css" />  
3 -<ul class="page-breadcrumb breadcrumb">  
4 - <li><a href="/pages/home.html" data-pjax>首页</a> <i  
5 - class="fa fa-circle"></i></li>  
6 - <li><span class="active">运维管理</span> <i class="fa fa-circle"></i></li>  
7 - <li><span class="active">上海市线路编码查询</span></li>  
8 -</ul>  
9 -<div class="tab_line">  
10 - <div class="col-md-12">  
11 - <ul class="breadcrumb">  
12 - <li>线路名称:</li>  
13 - <li><input type="text" class="form-control form-filter input-sm"  
14 - name="name_like" placeholder="请输入线路名称" maxlength="40" /></li>  
15 - <li><a class="btn btn-circle blue" id="search">查询</a></li>  
16 - </ul>  
17 - </div>  
18 - <div class="col-md-12 panel-wrap">  
19 - <div class="_panel">  
20 - <div class="_head" style="color: #2765A7;">待选线路模板列表</div>  
21 - <div class="table-container">  
22 - <table  
23 - class="table table-striped table-bordered table-advance pb-table head">  
24 - <thead>  
25 - <tr>  
26 - <th width="5%">序号</th>  
27 - <th width="20%">线路名称</th>  
28 - <th width="15%">所属公司</th>  
29 - <th width="25%">调度方式</th>  
30 - <th>上海市线路编码</th>  
31 - </tr>  
32 - </thead>  
33 - <tbody>  
34 - </tbody>  
35 - </table>  
36 - <div style="text-align: right;">  
37 - <ul id="pagination" class="pagination"></ul>  
38 - </div>  
39 - </div>  
40 - </div>  
41 - </div>  
42 -</div>  
43 -<script id="shLineCode_list_temp" type="text/html">  
44 -{{each list as obj i}}  
45 -<tr>  
46 - <td class="seq" style="vertical-align: middle;">  
47 - {{i+1}}  
48 - </td>  
49 - <td>  
50 - {{obj.name}}  
51 - </td>  
52 - <td class="ttInfoId">  
53 - {{obj.company}}  
54 - </td>  
55 - <td>  
56 - 全程  
57 - </td>  
58 - <td >  
59 - {{obj.shanghaiLinecode}}  
60 - </td>  
61 -</tr>  
62 -{{/each}}  
63 -{{if list.length == 0}}  
64 -<tr class="muted">  
65 - <td colspan=5 style="text-align: center;"><h6>没有找到相关数据</h6></td>  
66 -</tr>  
67 -{{/if}}  
68 - </script> 1 +<link href="css/trafficManage.css" rel="stylesheet" type="text/css" />
  2 +<link href="css/autocompleter.css" rel="stylesheet" type="text/css" />
  3 +<ul class="page-breadcrumb breadcrumb">
  4 + <li><a href="/pages/home.html" data-pjax>首页</a> <i
  5 + class="fa fa-circle"></i></li>
  6 + <li><span class="active">运维管理</span> <i class="fa fa-circle"></i></li>
  7 + <li><span class="active">上海市线路编码查询</span></li>
  8 +</ul>
  9 +<div class="tab_line">
  10 + <div class="col-md-12">
  11 + <ul class="breadcrumb">
  12 + <li>线路名称:</li>
  13 + <li><input type="text" class="form-control form-filter input-sm"
  14 + name="name_like" placeholder="请输入线路名称" maxlength="40" /></li>
  15 + <li><a class="btn btn-circle blue" id="search">查询</a></li>
  16 + </ul>
  17 + </div>
  18 + <div class="col-md-12 panel-wrap">
  19 + <div class="_panel">
  20 + <div class="table-container">
  21 + <table
  22 + class="table table-striped table-bordered table-advance pb-table head">
  23 + <thead>
  24 + <tr>
  25 + <th width="5%">序号</th>
  26 + <th width="20%">线路名称</th>
  27 + <th width="15%">所属公司</th>
  28 + <th width="25%">调度方式</th>
  29 + <th>上海市线路编码</th>
  30 + </tr>
  31 + </thead>
  32 + <tbody>
  33 + </tbody>
  34 + </table>
  35 + <div style="text-align: right;">
  36 + <ul id="pagination" class="pagination"></ul>
  37 + </div>
  38 + </div>
  39 + </div>
  40 + </div>
  41 +</div>
  42 +<script id="shLineCode_list_temp" type="text/html">
  43 +{{each list as obj i}}
  44 +<tr>
  45 + <td class="seq" style="vertical-align: middle;">
  46 + {{i+1}}
  47 + </td>
  48 + <td>
  49 + {{obj.name}}
  50 + </td>
  51 + <td class="ttInfoId">
  52 + {{obj.company}}
  53 + </td>
  54 + <td>
  55 +
  56 + </td>
  57 + <td >
  58 + {{obj.shanghaiLinecode}}
  59 + </td>
  60 +</tr>
  61 +{{/each}}
  62 +{{if list.length == 0}}
  63 +<tr class="muted">
  64 + <td colspan=5 style="text-align: center;"><h6>没有找到相关数据</h6></td>
  65 +</tr>
  66 +{{/if}}
  67 + </script>
69 <script src="./js/shLineCodeList.js"></script> 68 <script src="./js/shLineCodeList.js"></script>
70 \ No newline at end of file 69 \ No newline at end of file
src/main/resources/static/pages/trafficManage/timeTempletUpload.html
1 -<link href="css/trafficManage.css" rel="stylesheet" type="text/css" />  
2 -<link href="css/autocompleter.css" rel="stylesheet" type="text/css" />  
3 -<ul class="page-breadcrumb breadcrumb">  
4 - <li><a href="/pages/home.html" data-pjax>首页</a> <i  
5 - class="fa fa-circle"></i></li>  
6 - <li><span class="active">运维管理</span> <i class="fa fa-circle"></i></li>  
7 - <li><span class="active">时刻模板上传</span></li>  
8 -</ul>  
9 -<div class="tab_line">  
10 - <div class="col-md-12">  
11 - <ul class="breadcrumb">  
12 - <li>线路名称:</li>  
13 - <li><input type="text" class="form-control form-filter input-sm"  
14 - name="xl.name_eq" placeholder="请输入线路名称" maxlength="40" /></li>  
15 - <li>模板名称(关键字):</li>  
16 - <li><input type="text" class="form-control form-filter input-sm"  
17 - name="ttInfo.name_like" maxlength="40" /></li>  
18 - <li><a class="btn btn-circle blue" id="search">查询</a></li>  
19 - <li><a class="btn btn-circle red" id="upload">上传</a></li>  
20 - </ul>  
21 - </div>  
22 - <!-- Begin: left-div -->  
23 - <div class="col-md-5 panel-wrap" style="height: 60%;">  
24 - <div class="_panel">  
25 - <div class="_head" style="color: #2765A7;">待选线路模板列表</div>  
26 - <div class="table-container" id="left_div">  
27 - <table  
28 - class="table table-striped table-bordered table-advance pb-table head">  
29 - <thead>  
30 - <tr>  
31 - <th width="5%">#</th>  
32 - <th width="20%">线路名称</th>  
33 - <th width="15%">模板ID</th>  
34 - <th width="25%">模板名称</th>  
35 - <th>启用日期</th>  
36 - </tr>  
37 - </thead>  
38 - <tbody>  
39 - </tbody>  
40 - </table>  
41 - </div>  
42 - </div>  
43 - </div>  
44 - <div class="col-md-2" style="height: 60%;">  
45 - <ul class="breadcruma divVerHorCenter">  
46 - <li><a class="btn btn-circle blue btn-outline" id="to_right">>></a></li>  
47 - <li><a class="btn btn-circle blue btn-outline" id="to_left"><<</a></li>  
48 - </ul>  
49 - </div>  
50 - <!-- End: left-div -->  
51 - <!-- Begin: right-div -->  
52 - <div class="col-md-5 panel-wrap" style="height: 60%;">  
53 - <div class="_panel">  
54 - <div class="_head" style="color: #2765A7;">已选线路模板列表</div>  
55 - <div class="table-container" id="right_div"></div>  
56 - </div>  
57 - </div>  
58 - <!-- End: right-div -->  
59 -</div>  
60 -<script id="timeTemplet_list_temp" type="text/html">  
61 -{{each list as obj i}}  
62 -<tr>  
63 - <td class="seq" style="vertical-align: middle;">  
64 - {{i+1}}  
65 - </td>  
66 - <td>  
67 - {{obj.xl.name}}  
68 - </td>  
69 - <td class="ttInfoId">  
70 - {{obj.ttInfo.id}}  
71 - </td>  
72 - <td>  
73 - {{obj.ttInfo.name}}  
74 - </td>  
75 - <td >  
76 - {{obj.ttInfo.qyrq}}  
77 - </td>  
78 -</tr>  
79 -{{/each}}  
80 -{{if list.length == 0}}  
81 -<tr class="muted">  
82 - <td colspan=5 style="text-align: center;"><h6>没有找到相关数据</h6></td>  
83 -</tr>  
84 -{{/if}}  
85 - </script> 1 +<link href="css/trafficManage.css" rel="stylesheet" type="text/css" />
  2 +<link href="css/autocompleter.css" rel="stylesheet" type="text/css" />
  3 +<ul class="page-breadcrumb breadcrumb">
  4 + <li><a href="/pages/home.html" data-pjax>首页</a> <i
  5 + class="fa fa-circle"></i></li>
  6 + <li><span class="active">运维管理</span> <i class="fa fa-circle"></i></li>
  7 + <li><span class="active">时刻模板上传</span></li>
  8 +</ul>
  9 +<div class="tab_line">
  10 + <div class="col-md-12">
  11 + <ul class="breadcrumb">
  12 + <li>线路名称:</li>
  13 + <li><input type="text" class="form-control form-filter input-sm"
  14 + name="xl.name_eq" placeholder="请输入线路名称" maxlength="40" /></li>
  15 + <li>模板名称(关键字):</li>
  16 + <li><input type="text" class="form-control form-filter input-sm"
  17 + name="ttInfo.name_like" maxlength="40" /></li>
  18 + <li><a class="btn btn-circle blue" id="search">查询</a></li>
  19 + <li><a class="btn btn-circle red" id="upload">上传</a></li>
  20 + </ul>
  21 + </div>
  22 + <!-- Begin: left-div -->
  23 + <div class="col-md-5 panel-wrap" style="height: 60%;">
  24 + <div class="_panel">
  25 + <div class="_head" style="color: #2765A7;">待选线路模板列表</div>
  26 + <div class="table-container" id="left_div">
  27 + <table
  28 + class="table table-striped table-bordered table-advance pb-table head">
  29 + <thead>
  30 + <tr>
  31 + <th width="5%">#</th>
  32 + <th width="20%">线路名称</th>
  33 + <th width="15%">模板ID</th>
  34 + <th width="25%">模板名称</th>
  35 + <th>启用日期</th>
  36 + </tr>
  37 + </thead>
  38 + <tbody>
  39 + </tbody>
  40 + </table>
  41 + </div>
  42 + </div>
  43 + </div>
  44 + <div class="col-md-2" style="height: 60%;">
  45 + <ul class="breadcruma divVerHorCenter">
  46 + <li><a class="btn btn-circle blue btn-outline" id="to_right">>></a></li>
  47 + <li><a class="btn btn-circle blue btn-outline" id="to_left"><<</a></li>
  48 + </ul>
  49 + </div>
  50 + <!-- End: left-div -->
  51 + <!-- Begin: right-div -->
  52 + <div class="col-md-5 panel-wrap" style="height: 60%;">
  53 + <div class="_panel">
  54 + <div class="_head" style="color: #2765A7;">已选线路模板列表</div>
  55 + <div class="table-container" id="right_div"></div>
  56 + </div>
  57 + </div>
  58 + <!-- End: right-div -->
  59 +</div>
  60 +<script id="timeTemplet_list_temp" type="text/html">
  61 +{{each list as obj i}}
  62 +<tr>
  63 + <td class="seq" style="vertical-align: middle;">
  64 + {{i+1}}
  65 + </td>
  66 + <td>
  67 + {{obj.xl.name}}
  68 + </td>
  69 + <td class="ttInfoId">
  70 + {{obj.ttInfo.id}}
  71 + </td>
  72 + <td>
  73 + {{obj.ttInfo.name}}
  74 + </td>
  75 + <td >
  76 + {{obj.ttInfo.qyrq}}
  77 + </td>
  78 +</tr>
  79 +{{/each}}
  80 +{{if list.length == 0}}
  81 +<tr class="muted">
  82 + <td colspan=5 style="text-align: center;"><h6>没有找到相关数据</h6></td>
  83 +</tr>
  84 +{{/if}}
  85 + </script>
86 <script src="./js/timeTempletUpload.js"></script> 86 <script src="./js/timeTempletUpload.js"></script>
87 \ No newline at end of file 87 \ No newline at end of file
src/main/resources/static/pages/trafficManage/timeTempletUploadRecord.html 0 → 100644
  1 +<link href="css/trafficManage.css" rel="stylesheet" type="text/css" />
  2 +<link href="css/autocompleter.css" rel="stylesheet" type="text/css" />
  3 +<ul class="page-breadcrumb breadcrumb">
  4 + <li><a href="/pages/home.html" data-pjax>首页</a> <i
  5 + class="fa fa-circle"></i></li>
  6 + <li><span class="active">运维管理</span> <i class="fa fa-circle"></i></li>
  7 + <li><span class="active">时刻模板上传日志</span></li>
  8 +</ul>
  9 +<div class="tab_line">
  10 + <div class="col-md-12">
  11 + <ul class="breadcrumb">
  12 + <li>筛选数据:</li>
  13 + <li><select name="company_eq" class="form-control" id="companySelect"></select></li>
  14 + <li><select name="brancheCompany_eq" class="form-control" id="brancheCompanySelect"></select></li>
  15 + <li>日期:</li>
  16 + <li><input type="text" class="inputCommon dateTime" name="date" id="dateInput" placeholder="日期"></li>
  17 + <li>线路名称:</li>
  18 + <li><input type="text" class="form-control form-filter input-sm"
  19 + name="xl.name_eq" maxlength="40" /></li>
  20 + <li>上传用户:</li>
  21 + <li><input type="text" class="inputCommon inputCarPlate"
  22 + name="xl.user_eq" maxlength="40" /></li>
  23 + <li><a class="btn btn-circle blue" id="search">筛选</a></li>
  24 + </ul>
  25 + </div>
  26 + <div class="col-md-12 panel-wrap">
  27 + <div class="_panel">
  28 + <div class="table-container">
  29 + <table
  30 + class="table table-striped table-bordered table-advance pb-table head">
  31 + <thead>
  32 + <tr>
  33 + <th>序号</th>
  34 + <th>公司</th>
  35 + <th>分公司</th>
  36 + <th>线路</th>
  37 + <th>模板名称</th>
  38 + <th>上传人员</th>
  39 + <th>上传时间</th>
  40 + </tr>
  41 + </thead>
  42 + <tbody>
  43 + </tbody>
  44 + </table>
  45 + <div style="text-align: right;">
  46 + <ul id="pagination" class="pagination"></ul>
  47 + </div>
  48 + </div>
  49 + </div>
  50 + </div>
  51 +</div>
  52 +<script id="lineStationRecord_list_temp" type="text/html">
  53 +{{each list as obj i}}
  54 +<tr>
  55 + <td class="seq" style="vertical-align: middle;">
  56 + {{i+1}}
  57 + </td>
  58 + <td>
  59 + {{obj.name}}
  60 + </td>
  61 + <td class="ttInfoId">
  62 + {{obj.company}}
  63 + </td>
  64 + <td>
  65 + {{obj.name}}
  66 + </td>
  67 + <td>
  68 + {{obj.company}}
  69 + </td>
  70 + <td>
  71 +
  72 + </td>
  73 + <td >
  74 +
  75 + </td>
  76 +</tr>
  77 +{{/each}}
  78 +{{if list.length == 0}}
  79 +<tr class="muted">
  80 + <td colspan=5 style="text-align: center;"><h6>没有找到相关数据</h6></td>
  81 +</tr>
  82 +{{/if}}
  83 + </script>
  84 +<script src="./js/timeTempletUploadRecord.js"></script>
0 \ No newline at end of file 85 \ No newline at end of file