Commit ac15eac085e69061e76f8fcb76bc422700ca7741
Merge branch 'minhang' of http://222.66.0.204:8090/panzhaov5/bsth_control into minhang
Showing
19 changed files
with
212 additions
and
57 deletions
src/main/java/com/bsth/controller/oil/CwjyController.java
| ... | ... | @@ -13,6 +13,8 @@ import org.springframework.web.bind.annotation.RequestParam; |
| 13 | 13 | import org.springframework.web.bind.annotation.RestController; |
| 14 | 14 | |
| 15 | 15 | import com.bsth.controller.BaseController; |
| 16 | +import com.bsth.data.BasicData; | |
| 17 | +import com.bsth.entity.Line; | |
| 16 | 18 | import com.bsth.entity.oil.Cwjy; |
| 17 | 19 | import com.bsth.entity.oil.Ylxxb; |
| 18 | 20 | import com.bsth.entity.sys.SysUser; |
| ... | ... | @@ -30,12 +32,15 @@ public class CwjyController extends BaseController<Cwjy, Integer>{ |
| 30 | 32 | SysUser sysUser = SecurityUtils.getCurrentUser(); |
| 31 | 33 | t.setCreateDate(new Date()); |
| 32 | 34 | t.setXgr(sysUser.getUserName()); |
| 35 | + t.setNbbm(t.getNbbm().trim().toUpperCase()); | |
| 36 | + Line line=BasicData.nbbm2LineMap.get(t.getNbbm()); | |
| 37 | + t.setLine(line == null?"" : line.getLineCode()); | |
| 33 | 38 | return service.save(t); |
| 34 | 39 | } |
| 35 | 40 | |
| 36 | 41 | @RequestMapping(value = "/checkNbbm",method = RequestMethod.GET) |
| 37 | 42 | public int checkNbbm(Cwjy t){ |
| 38 | - return service.checkNbbm(t.getNbbm().trim()); | |
| 43 | + return service.checkNbbm(t); | |
| 39 | 44 | } |
| 40 | 45 | |
| 41 | 46 | @RequestMapping(value = "/queryList",method = RequestMethod.GET) | ... | ... |
src/main/java/com/bsth/entity/oil/Cwjy.java
| ... | ... | @@ -26,6 +26,11 @@ public class Cwjy { |
| 26 | 26 | private String xgr; |
| 27 | 27 | |
| 28 | 28 | private Date createDate; |
| 29 | + | |
| 30 | + private String line; | |
| 31 | + | |
| 32 | + @Transient | |
| 33 | + private String linename; | |
| 29 | 34 | |
| 30 | 35 | @Transient |
| 31 | 36 | private String gsname; |
| ... | ... | @@ -95,6 +100,24 @@ public class Cwjy { |
| 95 | 100 | public void setFgsname(String fgsname) { |
| 96 | 101 | this.fgsname = fgsname; |
| 97 | 102 | } |
| 103 | + | |
| 104 | + public String getLine() { | |
| 105 | + return line; | |
| 106 | + } | |
| 107 | + | |
| 108 | + public void setLine(String line) { | |
| 109 | + this.line = line; | |
| 110 | + } | |
| 111 | + | |
| 112 | + public String getLinename() { | |
| 113 | + return BasicData.lineCode2NameMap.get(this.line); | |
| 114 | + } | |
| 115 | + | |
| 116 | + public void setLinename(String linename) { | |
| 117 | + this.linename = linename; | |
| 118 | + } | |
| 119 | + | |
| 120 | + | |
| 98 | 121 | |
| 99 | 122 | |
| 100 | 123 | } | ... | ... |
src/main/java/com/bsth/entity/oil/Ylxxb.java
| ... | ... | @@ -44,7 +44,8 @@ public class Ylxxb { |
| 44 | 44 | private String gsname; |
| 45 | 45 | @Transient |
| 46 | 46 | private String fgsname; |
| 47 | - | |
| 47 | + @Transient | |
| 48 | + private String linename; | |
| 48 | 49 | @Transient |
| 49 | 50 | private Double zjzl; |
| 50 | 51 | |
| ... | ... | @@ -193,6 +194,12 @@ public class Ylxxb { |
| 193 | 194 | public void setZjzl(Double zjzl) { |
| 194 | 195 | this.zjzl = zjzl; |
| 195 | 196 | } |
| 197 | + public String getLinename() { | |
| 198 | + return linename; | |
| 199 | + } | |
| 200 | + public void setLinename(String linename) { | |
| 201 | + this.linename = linename; | |
| 202 | + } | |
| 196 | 203 | |
| 197 | 204 | |
| 198 | 205 | ... | ... |
src/main/java/com/bsth/repository/oil/CwjyRepository.java
| ... | ... | @@ -30,5 +30,8 @@ public interface CwjyRepository extends BaseRepository<Cwjy, Integer>{ |
| 30 | 30 | @Query(value="select * from bsth_c_cwjy where nbbm like %?1% and gsdm like %?2% and fgsdm like %?3%",nativeQuery=true) |
| 31 | 31 | List<Cwjy> selectAll(String nbbm,String gsdm,String fgsdm); |
| 32 | 32 | |
| 33 | + @Query(value="select * from bsth_c_cwjy where nbbm like %?1% and gsdm like %?2% and fgsdm like %?3% and line =?4",nativeQuery=true) | |
| 34 | + List<Cwjy> selectAll_s(String nbbm,String gsdm,String fgsdm,String line); | |
| 35 | + | |
| 33 | 36 | |
| 34 | 37 | } | ... | ... |
src/main/java/com/bsth/service/excep/impl/NowOutboundServiceImpl.java
| ... | ... | @@ -70,7 +70,7 @@ public class NowOutboundServiceImpl implements NowOutboundService{ |
| 70 | 70 | |
| 71 | 71 | } |
| 72 | 72 | |
| 73 | - sql +=" and endtimestamp - starttimestamp >10000 ";//yue越界超过10秒的才显示,有待探讨。 | |
| 73 | + sql +=" and endtimestamp - starttimestamp >10000 ";//越界超过30秒的才显示,有待探讨。 | |
| 74 | 74 | |
| 75 | 75 | sql +=" order by starttimestamp limit ?,?"; |
| 76 | 76 | ... | ... |
src/main/java/com/bsth/service/oil/CwjyService.java
src/main/java/com/bsth/service/oil/impl/CwjyServiceImpl.java
| ... | ... | @@ -24,6 +24,7 @@ import org.springframework.stereotype.Service; |
| 24 | 24 | import com.alibaba.fastjson.JSONArray; |
| 25 | 25 | import com.alibaba.fastjson.JSONObject; |
| 26 | 26 | import com.bsth.common.ResponseCode; |
| 27 | +import com.bsth.data.BasicData; | |
| 27 | 28 | import com.bsth.entity.oil.Cwjy; |
| 28 | 29 | import com.bsth.entity.oil.Cyl; |
| 29 | 30 | import com.bsth.entity.oil.Ylb; |
| ... | ... | @@ -281,6 +282,7 @@ public class CwjyServiceImpl extends BaseServiceImpl<Cwjy,Integer> implements Cw |
| 281 | 282 | String gsdm=map.get("gsdm_like").toString(); |
| 282 | 283 | |
| 283 | 284 | String fgsdm=map.get("fgsdm_like").toString(); |
| 285 | + String line =map.get("line_like").toString().trim(); | |
| 284 | 286 | /*String sql="SELECT a.gsdm as gsdm,a.fgsdm as fgsdm,a.nbbm as nbbm," |
| 285 | 287 | + "b.jyggh as jyggh,b.jzl as jzl ,b.stationid as stationid,b.jsy as jsy," |
| 286 | 288 | + "b.nylx as nylx,b.yj as yj,b.bz as bz,b.id as id ,c.jsy as ldgh FROM bsth_c_cwjy a "+ |
| ... | ... | @@ -318,7 +320,13 @@ public class CwjyServiceImpl extends BaseServiceImpl<Cwjy,Integer> implements Cw |
| 318 | 320 | return t; |
| 319 | 321 | } |
| 320 | 322 | }); |
| 321 | - List<Cwjy> cwList=repository.selectAll(nbbm, gsdm, fgsdm); | |
| 323 | + List<Cwjy> cwList=null; | |
| 324 | + if(line.equals("")){ | |
| 325 | + cwList = repository.selectAll(nbbm, gsdm, fgsdm); | |
| 326 | + }else{ | |
| 327 | + cwList = repository.selectAll_s(nbbm, gsdm, fgsdm, line); | |
| 328 | + } | |
| 329 | + | |
| 322 | 330 | String sql_ylb="SELECT nbbm,group_concat(jsy) AS jsy FROM bsth_c_ylb WHERE " |
| 323 | 331 | + " to_days(rq) = to_days('"+rq+"') AND ssgsdm = '"+gsdm+"' AND " |
| 324 | 332 | + " fgsdm = '"+fgsdm+"' GROUP BY nbbm"; |
| ... | ... | @@ -338,9 +346,6 @@ public class CwjyServiceImpl extends BaseServiceImpl<Cwjy,Integer> implements Cw |
| 338 | 346 | Ylxxb y=null; |
| 339 | 347 | for (int i = 0; i < cwList.size(); i++) { |
| 340 | 348 | Cwjy cwjy=cwList.get(i); |
| 341 | - if(cwjy.getNbbm().equals("W7B-092")){ | |
| 342 | - System.out.println(); | |
| 343 | - } | |
| 344 | 349 | y=new Ylxxb(); |
| 345 | 350 | y.setNylx(0); |
| 346 | 351 | y.setId(0); |
| ... | ... | @@ -348,6 +353,7 @@ public class CwjyServiceImpl extends BaseServiceImpl<Cwjy,Integer> implements Cw |
| 348 | 353 | y.setGsdm(cwjy.getGsdm()); |
| 349 | 354 | y.setFgsdm(cwjy.getFgsdm()); |
| 350 | 355 | y.setNbbm(cwjy.getNbbm()); |
| 356 | + y.setLinename(cwjy.getLinename()); | |
| 351 | 357 | for (int j = 0; j < yList.size(); j++) { |
| 352 | 358 | Ylxxb ylxxb=yList.get(j); |
| 353 | 359 | if(y.getNbbm().equals(ylxxb.getNbbm())){ |
| ... | ... | @@ -379,9 +385,10 @@ public class CwjyServiceImpl extends BaseServiceImpl<Cwjy,Integer> implements Cw |
| 379 | 385 | } |
| 380 | 386 | |
| 381 | 387 | @Override |
| 382 | - public int checkNbbm(String nbbm) { | |
| 388 | + public int checkNbbm(Cwjy t) { | |
| 383 | 389 | // TODO Auto-generated method stub |
| 384 | - String sql="select count(*) from bsth_c_cwjy where nbbm ='"+nbbm+"'"; | |
| 390 | + String sql="select count(*) from bsth_c_cwjy where nbbm ='"+t.getNbbm()+"'" | |
| 391 | + + " and gsdm ='"+t.getFgsdm()+"' and fgsdm ='"+t.getFgsdm()+"'"; | |
| 385 | 392 | int cs=jdbcTemplate.queryForObject(sql, Integer.class); |
| 386 | 393 | |
| 387 | 394 | return cs; | ... | ... |
src/main/java/com/bsth/service/oil/impl/YlbServiceImpl.java
| ... | ... | @@ -384,6 +384,7 @@ public class YlbServiceImpl extends BaseServiceImpl<Ylb,Integer> implements YlbS |
| 384 | 384 | for (int i = 0; i < ylxxList.size(); i++) { |
| 385 | 385 | Ylxxb ylxxb = ylxxList.get(i); |
| 386 | 386 | if (map.get("clZbh").toString().equals(ylxxb.getNbbm()) |
| 387 | + && map.get("jGh").toString().equals(ylxxb.getJsy()) | |
| 387 | 388 | && ylxxb.getJylx()==1) { |
| 388 | 389 | if(ylxxb.getJzl()>0){ |
| 389 | 390 | fage2=true; | ... | ... |
src/main/java/com/bsth/service/oil/impl/YlxxbServiceImpl.java
| ... | ... | @@ -176,6 +176,7 @@ public class YlxxbServiceImpl extends BaseServiceImpl<Ylxxb,Integer> implements |
| 176 | 176 | String jsy =jsonObject.getString("jsy"); |
| 177 | 177 | Ylxxb ylxxb=repository.findOne(id); |
| 178 | 178 | ylxxb.setJsy(jsy); |
| 179 | + ylxxb.setJylx(1); | |
| 179 | 180 | repository.save(ylxxb); |
| 180 | 181 | } |
| 181 | 182 | newMap.put("status", ResponseCode.SUCCESS); | ... | ... |
src/main/java/com/bsth/service/realcontrol/impl/ScheduleRealInfoServiceImpl.java
| ... | ... | @@ -2737,7 +2737,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 2737 | 2737 | if (a == 2) { |
| 2738 | 2738 | x = b + 1; |
| 2739 | 2739 | y = x * 2; |
| 2740 | - } else if (b == 1) { | |
| 2740 | + } else if (a == 1) { | |
| 2741 | 2741 | x = b + 1; |
| 2742 | 2742 | y = x * 2 - 1; |
| 2743 | 2743 | } else { |
| ... | ... | @@ -4075,7 +4075,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 4075 | 4075 | if((zdsj_-zdsjActual_)>0){ |
| 4076 | 4076 | zdsjk =String.valueOf(zdsj_-zdsjActual_); |
| 4077 | 4077 | }else{ |
| 4078 | - zdsjm =String.valueOf(zdsj_-zdsjActual_); | |
| 4078 | + zdsjm =String.valueOf(zdsjActual_-zdsj_); | |
| 4079 | 4079 | } |
| 4080 | 4080 | } |
| 4081 | 4081 | tempMap.put("zdsjk" + x, zdsjk); |
| ... | ... | @@ -4102,7 +4102,7 @@ public class ScheduleRealInfoServiceImpl extends BaseServiceImpl<ScheduleRealInf |
| 4102 | 4102 | if((zdsj_-fcsjActural_)>0){ |
| 4103 | 4103 | fcsjk =String.valueOf(zdsj_-fcsjActural_); |
| 4104 | 4104 | }else{ |
| 4105 | - fcsjm =String.valueOf(zdsj_-fcsjActural_); | |
| 4105 | + fcsjm =String.valueOf(fcsjActural_-zdsj_); | |
| 4106 | 4106 | } |
| 4107 | 4107 | } |
| 4108 | 4108 | tempMap.put("fcsjk" + x, fcsjk); | ... | ... |
src/main/resources/static/pages/base/interval/js/interval-add-form.js
| ... | ... | @@ -30,21 +30,18 @@ $(function(){ |
| 30 | 30 | focusInvalid : true, |
| 31 | 31 | // 需要验证的表单元素 |
| 32 | 32 | rules : { |
| 33 | - // 公司名称编码 | |
| 34 | 33 | 'level' : { |
| 35 | 34 | // 必填项 |
| 36 | 35 | required : true, |
| 37 | 36 | // 最大长度 |
| 38 | 37 | maxlength: 10 |
| 39 | 38 | }, |
| 40 | - // 公司名称 | |
| 41 | 39 | 'peak' : { |
| 42 | 40 | // 必填项 |
| 43 | 41 | required : true, |
| 44 | 42 | // 最大长度 |
| 45 | 43 | maxlength: 10 |
| 46 | 44 | }, |
| 47 | - // 公司名称 | |
| 48 | 45 | 'trough' : { |
| 49 | 46 | // 必填项 |
| 50 | 47 | required : true, | ... | ... |
src/main/resources/static/pages/base/interval/js/interval-edit-form.js
| ... | ... | @@ -12,7 +12,7 @@ |
| 12 | 12 | var intervalId = $.url().param('no'); |
| 13 | 13 | // 如果参数ID不为空 |
| 14 | 14 | if(intervalId) { |
| 15 | - // 获取线路Id元素并设值 | |
| 15 | + // 获取间隔信息Id元素并设值 | |
| 16 | 16 | $('#intervalId').val(intervalId); |
| 17 | 17 | /** 根据ID查询详细信息 */ |
| 18 | 18 | $get('/interval/' + intervalId ,null, function(result){ |
| ... | ... | @@ -50,21 +50,18 @@ |
| 50 | 50 | focusInvalid : true, |
| 51 | 51 | // 需要验证的表单元素 |
| 52 | 52 | rules : { |
| 53 | - // 公司名称编码 | |
| 54 | 53 | 'level' : { |
| 55 | 54 | // 必填项 |
| 56 | 55 | required : true, |
| 57 | 56 | // 最大长度 |
| 58 | 57 | maxlength: 10 |
| 59 | 58 | }, |
| 60 | - // 公司名称 | |
| 61 | 59 | 'peak' : { |
| 62 | 60 | // 必填项 |
| 63 | 61 | required : true, |
| 64 | 62 | // 最大长度 |
| 65 | 63 | maxlength: 10 |
| 66 | 64 | }, |
| 67 | - // 公司名称 | |
| 68 | 65 | 'trough' : { |
| 69 | 66 | // 必填项 |
| 70 | 67 | required : true, | ... | ... |
src/main/resources/static/pages/excep/outBoundMap.html deleted
100644 → 0
| 1 | -<link href="/pages/base/stationroute/css/bmap_base.css" rel="stylesheet" type="text/css" /> | |
| 2 | -<div class="portlet-body"> | |
| 3 | - <!-- 地图 --> | |
| 4 | - <div id="bmap_basic" class="bmaps"></div> | |
| 5 | -</div> | |
| 6 | -<!-- load事件 --> | |
| 7 | -<script src="/pages/excep/js/outboundmap-load.js"></script> | |
| 8 | -<!-- 线路类 --> | |
| 9 | -<script src="/pages/excep/js/outboundline.js"></script> | |
| 10 | -<!-- 绘图类 --> | |
| 11 | -<script src="/pages/base/stationroute/js/drawingManager.js"></script> | |
| 12 | -<!-- 地图类 --> | |
| 13 | -<script src="/pages/excep/js/outbound-map.js"></script> | |
| 14 | -<!-- 函数与方法 --> | |
| 15 | -<script src="/pages/excep/js/outboundmap-function.js"></script> | |
| 16 | -<!-- ajax请求类 --> | |
| 17 | -<script src="/pages/base/stationroute/js/stationroute-ajax-getdata.js"></script> | |
| 18 | - |
src/main/resources/static/pages/excep/outboundMap.html
0 → 100644
| 1 | +<style> | |
| 2 | + .play_back-layer .layui-layer-title{ | |
| 3 | + height: 36px; | |
| 4 | + border-bottom: none; | |
| 5 | + } | |
| 6 | +</style> | |
| 7 | + | |
| 8 | +<div id="titleMap"> | |
| 9 | +<button id="run" style="margin-left:10px" class="btn btn-sm green btn-outline filter-submit margin-bottom">运行</button> | |
| 10 | +</div> | |
| 11 | +<div id="BasicMap"> | |
| 12 | +</div> | |
| 13 | +<style type="text/css"> | |
| 14 | + | |
| 15 | +#BasicMap{ | |
| 16 | + width: 100%; | |
| 17 | + border: 2px solid #fdfdfd; | |
| 18 | + height: calc(100% - 30px); | |
| 19 | + overflow: hidden; | |
| 20 | +} | |
| 21 | +</style> | |
| 22 | +<script type="text/javascript" src="/pages/excep/js/map.js"></script> | |
| 23 | +<script type="text/javascript" src="/pages/excep/js/line-list-function.js"></script> | |
| 24 | + | |
| 25 | +<script type="text/javascript"> | |
| 26 | +$(function(){ | |
| 27 | + var dataArr = window.localStorage.zbhAndDate.split(",");//获取页面传递过来的车辆自编号以及超速起始时间和超速结束时间 | |
| 28 | + localStorage.clear();//清楚前端缓存 | |
| 29 | + var vehicle = dataArr[0]; | |
| 30 | + var startdate = dataArr[1]; | |
| 31 | + var enddate = dataArr[2]; | |
| 32 | + var lon = dataArr[3];//起点经度 | |
| 33 | + var lat = dataArr[4];//起点纬度 | |
| 34 | + var endLon = dataArr[5];//终点经度 | |
| 35 | + var endLat = dataArr[6];//终点纬度 | |
| 36 | + var lineid = dataArr[7]; | |
| 37 | + var directionData = dataArr[8]; | |
| 38 | + var pointObj;//坐标和速度组成的对象 | |
| 39 | + var Points = [];//坐标和速度对象的集合 | |
| 40 | + var coordinateArr = [];//坐标点数组 | |
| 41 | + $.ajax({ | |
| 42 | + type: "GET", | |
| 43 | + async:false, | |
| 44 | + url: '/nowbound/findPosition', | |
| 45 | + data: {vehicle:vehicle,startdate:startdate,enddate:enddate}, | |
| 46 | + success: function(data){ | |
| 47 | + $.each(data,function(i,item){ | |
| 48 | + if(item.lon>1 && item.lat>1){ | |
| 49 | + pointObj = new Object(); | |
| 50 | + pointObj.coordinate = new BMap.Point(item.lon,item.lat); | |
| 51 | + pointObj.vehicle = item.vehicle; | |
| 52 | + Points.push(pointObj); | |
| 53 | + } | |
| 54 | + }); | |
| 55 | + } | |
| 56 | + }); | |
| 57 | + setTimeout(function(){ | |
| 58 | + var map = BasicMap.init();//创建地图 | |
| 59 | + $get('/sectionroute/findSection',{'line.id_eq' : lineid , 'directions_eq' :directionData},function(data) { | |
| 60 | + // 在地图上画出线路走向 | |
| 61 | + PublicFunctions.linePanlThree(lineid,data,directionData); | |
| 62 | + }); | |
| 63 | + var myP1 = new BMap.Point(lon,lat); //起点 | |
| 64 | + var myP2 = new BMap.Point(endLon,endLat); //终点 | |
| 65 | + for(i in Points){ | |
| 66 | + coordinateArr.push(Points[i].coordinate); | |
| 67 | + } | |
| 68 | + var polyline = new BMap.Polyline(coordinateArr, {strokeColor:"red", strokeWeight:5, strokeOpacity:0.5});//创建折线 | |
| 69 | + var myIcon = new BMap.Icon("/pages/excep/img/bus.png", new BMap.Size(32, 70), {//小车图片 | |
| 70 | + imageOffset: new BMap.Size(5,20) //图片的偏移量。为了是图片底部中心对准坐标点。 | |
| 71 | + }); | |
| 72 | + | |
| 73 | + var carMk; | |
| 74 | + $(document).on('click', '#run', function() { | |
| 75 | + map.centerAndZoom(new BMap.Point(lon,lat),16);//地图中心点坐标 */ | |
| 76 | + if(typeof(carMk)!="undefined"){ | |
| 77 | + map.removeOverlay(carMk);//清空上一次的轨迹 | |
| 78 | + } | |
| 79 | + carMk = new BMap.Marker(coordinateArr[0],{icon:myIcon}); | |
| 80 | + map.addOverlay(polyline);//增加折线 | |
| 81 | + var paths = coordinateArr.length;//获得有几个点 | |
| 82 | + map.addOverlay(carMk); | |
| 83 | + i=0; | |
| 84 | + setTimeout(function(){ | |
| 85 | + resetMkPoint(0); | |
| 86 | + },500); | |
| 87 | + function resetMkPoint(i){ | |
| 88 | + carMk.setPosition(coordinateArr[i]); | |
| 89 | + if(i < paths-1){ | |
| 90 | + setTimeout(function(){ | |
| 91 | + i++; | |
| 92 | + resetMkPoint(i); | |
| 93 | + },500); | |
| 94 | + } | |
| 95 | + }; | |
| 96 | + | |
| 97 | + }); | |
| 98 | + }, 500); | |
| 99 | + }); | |
| 100 | +</script> | |
| 101 | + | |
| 102 | + | ... | ... |
src/main/resources/static/pages/excep/pdboundList.html
| ... | ... | @@ -65,11 +65,9 @@ |
| 65 | 65 | <tr role="row" class="filter"> |
| 66 | 66 | <td></td> |
| 67 | 67 | <td> |
| 68 | -<!-- <input type="text" class="form-control form-filter input-sm" name="userName_like"> --> | |
| 69 | 68 | <select class="form-control" name="line" id="line" style="width: 150px;"></select> |
| 70 | 69 | </td> |
| 71 | 70 | <td> |
| 72 | -<!-- <input type="text" class="form-control form-filter input-sm" name="nbbm"> --> | |
| 73 | 71 | <select class="form-control" name="nbbm" id="nbbm" style="width: 150px;"></select> |
| 74 | 72 | </td> |
| 75 | 73 | <td> |
| ... | ... | @@ -128,7 +126,7 @@ |
| 128 | 126 | {{/if}} |
| 129 | 127 | </td> |
| 130 | 128 | <td> |
| 131 | - {{obj.id}} | |
| 129 | + {{obj.address}} | |
| 132 | 130 | </td> |
| 133 | 131 | <td> |
| 134 | 132 | {{obj.timestampDate}} |
| ... | ... | @@ -137,7 +135,7 @@ |
| 137 | 135 | <a class="btn default blue-stripe btn-sm lookTrajectory" data-vehicle ="{{obj.vehicle}}" |
| 138 | 136 | data-startdate="{{obj.timestampDate}}" data-enddate="{{obj.endtimestampDate}}" |
| 139 | 137 | data-lon="{{obj.lon}}" data-lat="{{obj.lat}}" data-endlon="{{obj.endlon}}" |
| 140 | - data-endlat="{{obj.endlat}}" data-lineid="{{obj.lineId}}" data-updown="{{obj.upDown}}"> | |
| 138 | + data-endlat="{{obj.endlat}}" data-lineid="{{obj.line}}" data-updown="{{obj.upDown}}"> | |
| 141 | 139 | 轨迹回放 |
| 142 | 140 | </a> |
| 143 | 141 | </td> |
| ... | ... | @@ -243,8 +241,8 @@ $(function(){ |
| 243 | 241 | content:result,//内容 |
| 244 | 242 | }); |
| 245 | 243 | }); |
| 246 | - }) | |
| 247 | - return; | |
| 244 | + }) | |
| 245 | + return; | |
| 248 | 246 | } |
| 249 | 247 | var result = listResult[index]; |
| 250 | 248 | new BMap.Geocoder().getLocation(new BMap.Point(result.lon,result.lat), function(rs){ | ... | ... |
src/main/resources/static/pages/excep/speedingMap.html
| ... | ... | @@ -25,6 +25,7 @@ |
| 25 | 25 | <script type="text/javascript"> |
| 26 | 26 | $(function(){ |
| 27 | 27 | var dataArr = window.localStorage.zbhAndDate.split(",");//获取页面传递过来的车辆自编号以及超速起始时间和超速结束时间 |
| 28 | + localStorage.clear();//清楚前端缓存 | |
| 28 | 29 | var vehicle = dataArr[0]; |
| 29 | 30 | var startdate = dataArr[1]; |
| 30 | 31 | var enddate = dataArr[2]; | ... | ... |
src/main/resources/static/pages/oil/jyglList.html
| ... | ... | @@ -58,15 +58,15 @@ |
| 58 | 58 | <tr role="row" class="heading"> |
| 59 | 59 | <th width="2%">#</th> |
| 60 | 60 | <th width="10%">日期</th> |
| 61 | - <th width="10%">公司</th> | |
| 62 | - <th width="10%">分公司</th> | |
| 61 | + <th width="8%">公司</th> | |
| 62 | + <th width="8%">分公司</th> | |
| 63 | + <th width="8%">线路</th> | |
| 63 | 64 | <th width="8%">车辆</th> |
| 64 | 65 | <th width="14%">驾驶员</th> |
| 65 | 66 | <th width="5%">加注量</th> |
| 66 | 67 | <th width="4%">加油站</th> |
| 67 | 68 | <th width="3%">加油类型</th> |
| 68 | 69 | <th width="5%">加油工工号</th> |
| 69 | - <th width="3%">油价</th> | |
| 70 | 70 | <th width="4%">路单工号</th> |
| 71 | 71 | <th width="4%">备注</th> |
| 72 | 72 | <th width="10%">操作</th> |
| ... | ... | @@ -83,6 +83,9 @@ |
| 83 | 83 | <select class="form-control" name="fgsdm_like" id="jyglListFgsdmId" ></select> |
| 84 | 84 | </td> |
| 85 | 85 | <td> |
| 86 | + <select class="form-control" name="line_like" id="line" style="width: 120px;"></select> | |
| 87 | + </td> | |
| 88 | + <td> | |
| 86 | 89 | <input type="text" class="form-control form-filter input-sm" name="nbbh" id="nbbh"> |
| 87 | 90 | </td> |
| 88 | 91 | <td></td> |
| ... | ... | @@ -92,7 +95,6 @@ |
| 92 | 95 | <td></td> |
| 93 | 96 | <td></td> |
| 94 | 97 | <td></td> |
| 95 | - <td></td> | |
| 96 | 98 | <td> |
| 97 | 99 | <button class="btn btn-sm green btn-outline filter-submit margin-bottom" > |
| 98 | 100 | <i class="fa fa-search"></i> 搜索</button> |
| ... | ... | @@ -124,6 +126,7 @@ |
| 124 | 126 | <td> |
| 125 | 127 | {{obj.fgsname}} |
| 126 | 128 | </td> |
| 129 | + <td>{{obj.linename}}</td> | |
| 127 | 130 | <td> |
| 128 | 131 | {{obj.nbbm}} |
| 129 | 132 | </td> |
| ... | ... | @@ -153,7 +156,7 @@ onkeyup="this.value=this.value.replace(/[^(\d||/.)]/g,'').replace('.','$#$').rep |
| 153 | 156 | <input data-id="{{obj.nbbm}}" href="javascript:;" class="in_carpark_jyggh" |
| 154 | 157 | type="text" value="{{obj.jyggh}}" style=" width:45px" /> |
| 155 | 158 | </td> |
| 156 | - <td></td> | |
| 159 | + | |
| 157 | 160 | <td>{{obj.ldgh}}</td> |
| 158 | 161 | <td> |
| 159 | 162 | <input data-id="{{obj.nbbm}}" href="javascript:;" class="in_carpark_bz" |
| ... | ... | @@ -234,6 +237,27 @@ $(function(){ |
| 234 | 237 | }); |
| 235 | 238 | |
| 236 | 239 | |
| 240 | + | |
| 241 | + $.get('/report/lineList',function(xlList){ | |
| 242 | + var data = []; | |
| 243 | + data.push({id: " ", text: "全部线路"}); | |
| 244 | + $.get('/user/companyData', function(result){ | |
| 245 | + for(var i = 0; i < result.length; i++){ | |
| 246 | + var companyCode = result[i].companyCode; | |
| 247 | + var children = result[i].children; | |
| 248 | + for(var j = 0; j < children.length; j++){ | |
| 249 | + var code = children[j].code; | |
| 250 | + for(var k=0;k < xlList.length;k++ ){ | |
| 251 | + if(xlList[k]["fgsbm"]==code && xlList[k]["gsbm"]==companyCode){ | |
| 252 | + data.push({id: xlList[k]["xlbm"], text: xlList[k]["xlname"]}); | |
| 253 | + } | |
| 254 | + } | |
| 255 | + } | |
| 256 | + } | |
| 257 | + initPinYinSelect2('#line',data,''); | |
| 258 | + | |
| 259 | + }); | |
| 260 | + }); | |
| 237 | 261 | // var gsqx=""; |
| 238 | 262 | // var fgsqx=""; |
| 239 | 263 | ... | ... |
src/main/resources/static/pages/oil/jyszAdd.html
| ... | ... | @@ -33,7 +33,7 @@ |
| 33 | 33 | <label class="col-md-3 control-label">内部编码</label> |
| 34 | 34 | <div class="col-md-9"> |
| 35 | 35 | <!-- <select class="form-control input-medium " name="nbbm" id="nbbm" ></select> --> |
| 36 | - <input type="text" class="form-control input-medium" name="nbbm" > | |
| 36 | + <input type="text" class="form-control" name="nbbm" style="width: 180px"> | |
| 37 | 37 | </div> |
| 38 | 38 | </div> |
| 39 | 39 | </div> |
| ... | ... | @@ -87,6 +87,8 @@ $(function(){ |
| 87 | 87 | $('#fgsdm').html(options); |
| 88 | 88 | } |
| 89 | 89 | |
| 90 | + | |
| 91 | + | |
| 90 | 92 | //提交 |
| 91 | 93 | $('#addJyszModuleButton').on('click', function() { |
| 92 | 94 | form.submit(); |
| ... | ... | @@ -98,7 +100,7 @@ $(function(){ |
| 98 | 100 | focusInvalid : false, |
| 99 | 101 | rules : { |
| 100 | 102 | nbbm : { |
| 101 | - minlength : 2, | |
| 103 | + minlength : 4, | |
| 102 | 104 | required : true, |
| 103 | 105 | maxlength : 10 |
| 104 | 106 | } |
| ... | ... | @@ -125,7 +127,7 @@ $(function(){ |
| 125 | 127 | error.hide(); |
| 126 | 128 | $get('/cwjy/checkNbbm',params,function(result){ |
| 127 | 129 | if(result>0){ |
| 128 | - layer.msg('该车辆已经添加.'); | |
| 130 | + layer.msg('分公司该车辆已经添加.'); | |
| 129 | 131 | }else{ |
| 130 | 132 | $post('/cwjy', params, function(result){ |
| 131 | 133 | layer.msg('新增加油设置成功.'); | ... | ... |
src/main/resources/static/pages/oil/jyszList.html
| ... | ... | @@ -21,8 +21,9 @@ |
| 21 | 21 | </div> |
| 22 | 22 | <div class="actions"> |
| 23 | 23 | <!-- <a class="btn btn-circle blue" href="jyszAdd.html" data-pjax><i class="fa fa-plus"></i> 添加</a> --> |
| 24 | - <button type="button" class="btn btn-circle blue" id="addJysz"><i class="fa fa-trash"></i> 添加</button> | |
| 25 | -<!-- <button type="button" class="btn btn-circle blue" onclick="refreshJsTree()"><i class="fa fa-trash"></i>刷新</button> --> | |
| 24 | + <button type="button" class="btn btn-circle blue" id="addJysz"><i class="fa fa-plus"></i> 添加</button> | |
| 25 | +<!-- | |
| 26 | + <button type="button" class="btn btn-circle blue" onclick="refreshJsTree()"><i class="fa fa-trash"></i>刷新</button> --> | |
| 26 | 27 | |
| 27 | 28 | <!-- <div class="btn-group"> |
| 28 | 29 | <a class="btn red btn-outline btn-circle" href="javascript:;" |
| ... | ... | @@ -60,8 +61,9 @@ |
| 60 | 61 | <th width="15%">公司</th> |
| 61 | 62 | <th width="13%">分公司</th> |
| 62 | 63 | <th width="10%">车辆</th> |
| 64 | + <th width="10%">线路</th> | |
| 63 | 65 | <th width="10%">修改人</th> |
| 64 | - <th width="20%">日期</th> | |
| 66 | + <th width="10%">日期</th> | |
| 65 | 67 | <th width="19%">操作</th> |
| 66 | 68 | </tr> |
| 67 | 69 | <tr role="row" class="filter"> |
| ... | ... | @@ -77,6 +79,8 @@ |
| 77 | 79 | </td> |
| 78 | 80 | <td> |
| 79 | 81 | </td> |
| 82 | + <td> | |
| 83 | + </td> | |
| 80 | 84 | <td></td> |
| 81 | 85 | <td> |
| 82 | 86 | <button class="btn btn-sm green btn-outline filter-submit margin-bottom" > |
| ... | ... | @@ -107,6 +111,7 @@ |
| 107 | 111 | <td>{{obj.gsname}}</td> |
| 108 | 112 | <td>{{obj.fgsname}}</td> |
| 109 | 113 | <td>{{obj.nbbm}}</td> |
| 114 | + <td>{{obj.linename}}</td> | |
| 110 | 115 | <td>{{obj.xgr}}</td> |
| 111 | 116 | <td>{{obj.createDate}}</td> |
| 112 | 117 | <td> |
| ... | ... | @@ -236,6 +241,7 @@ $(function(){ |
| 236 | 241 | $.each(data.content, function(i, obj) { |
| 237 | 242 | obj.createDate = moment(obj.createDate).format("YYYY-MM-DD"); |
| 238 | 243 | }); |
| 244 | + console.log(data.content); | |
| 239 | 245 | var bodyHtm = template('jysz_list_temp', {list: data.content}); |
| 240 | 246 | |
| 241 | 247 | $('#datatable_jysz tbody').html(bodyHtm) |
| ... | ... | @@ -288,7 +294,7 @@ $(function(){ |
| 288 | 294 | for(var j = 0, item; item = items[j++];){ |
| 289 | 295 | name = $(item).attr('name'); |
| 290 | 296 | if(name){ |
| 291 | - params[name] = $(item).val(); | |
| 297 | + params[name] = $(item).val().replace(/(^\s*)|(\s*$)/g, ""); | |
| 292 | 298 | } |
| 293 | 299 | } |
| 294 | 300 | }); |
| ... | ... | @@ -315,7 +321,6 @@ $(function(){ |
| 315 | 321 | $.get('jyszAdd.html', function(m){$(pjaxContainer).append(m);}); |
| 316 | 322 | }); |
| 317 | 323 | |
| 318 | - | |
| 319 | 324 | }); |
| 320 | 325 | |
| 321 | 326 | ... | ... |