Commit 40ad0a49a88f191f707a3de71c2fda12f9d4b3ef

Authored by YRF
1 parent b9831686

闵行超速异常修改

src/main/java/com/bsth/service/excep/impl/NowSpeedingServiceImpl.java
@@ -129,20 +129,19 @@ public class NowSpeedingServiceImpl implements NowSpeedingService { @@ -129,20 +129,19 @@ public class NowSpeedingServiceImpl implements NowSpeedingService {
129 @Override 129 @Override
130 public PageObject<Speeding> Pagequery(Map<String, Object> map) { 130 public PageObject<Speeding> Pagequery(Map<String, Object> map) {
131 String sql="select count(*) record from bsth_c_speeding_handle where 1=1 "; 131 String sql="select count(*) record from bsth_c_speeding_handle where 1=1 ";
132 - SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); 132 + SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
133 Object line=map.get("line"); 133 Object line=map.get("line");
134 Object updown=map.get("updown"); 134 Object updown=map.get("updown");
135 Object startDate=map.get("startDate"); 135 Object startDate=map.get("startDate");
136 Object endDate=map.get("endDate"); 136 Object endDate=map.get("endDate");
137 Object times=map.get("times"); 137 Object times=map.get("times");
138 -  
139 - if(line!=null){ 138 + if(line!=null && line != ""){
140 sql +=" and line like'%"+line.toString().trim()+"%'"; 139 sql +=" and line like'%"+line.toString().trim()+"%'";
141 } 140 }
142 - if(updown!=null){ 141 + if(updown!=null && line != ""){
143 sql +="and up_down like '%"+updown.toString()+"%'"; 142 sql +="and up_down like '%"+updown.toString()+"%'";
144 } 143 }
145 - if(startDate!=null){ 144 + if(startDate!=null && line != ""){
146 if (startDate.toString().length()>0) { 145 if (startDate.toString().length()>0) {
147 try { 146 try {
148 Long t1 = sdf.parse(startDate.toString()+" 00:00:00").getTime(); 147 Long t1 = sdf.parse(startDate.toString()+" 00:00:00").getTime();
@@ -152,7 +151,7 @@ public class NowSpeedingServiceImpl implements NowSpeedingService { @@ -152,7 +151,7 @@ public class NowSpeedingServiceImpl implements NowSpeedingService {
152 } 151 }
153 } 152 }
154 } 153 }
155 - if(endDate!=null){ 154 + if(endDate!=null && line != ""){
156 if (endDate.toString().length()>0) { 155 if (endDate.toString().length()>0) {
157 try { 156 try {
158 Long t2=sdf.parse(endDate.toString()+" 23:59:59").getTime(); 157 Long t2=sdf.parse(endDate.toString()+" 23:59:59").getTime();
@@ -163,7 +162,7 @@ public class NowSpeedingServiceImpl implements NowSpeedingService { @@ -163,7 +162,7 @@ public class NowSpeedingServiceImpl implements NowSpeedingService {
163 } 162 }
164 } 163 }
165 164
166 - if(times!=null && times.toString().length()>0){ 165 + if(times!=null && times.toString().length()>0 && line != ""){
167 sql +=" and (endTimestamp-startTimestamp) >="+Integer.valueOf(times.toString())*1000; 166 sql +=" and (endTimestamp-startTimestamp) >="+Integer.valueOf(times.toString())*1000;
168 } 167 }
169 168
src/main/resources/static/pages/base/station/js/station-list-table.js
@@ -262,7 +262,6 @@ @@ -262,7 +262,6 @@
262 var i = layer.load(2); 262 var i = layer.load(2);
263 // 异步请求获取表格数据 263 // 异步请求获取表格数据
264 $.get('/stationroute',params,function(result){ 264 $.get('/stationroute',params,function(result){
265 - console.log(result);  
266 // 添加序号 265 // 添加序号
267 result.content.page = page; 266 result.content.page = page;
268 // 把数据填充到模版中 267 // 把数据填充到模版中
src/main/resources/static/pages/excep/mhspeedingList.html
@@ -302,17 +302,17 @@ $(function(){ @@ -302,17 +302,17 @@ $(function(){
302 var cells = $('tr.filter')[0].cells 302 var cells = $('tr.filter')[0].cells
303 ,params = {} 303 ,params = {}
304 ,name; 304 ,name;
305 - $.each(cells, function(i, cell){  
306 - var items = $('input,select', cell);  
307 - for(var j = 0, item; item = items[j++];){  
308 - name = $(item).attr('name');  
309 - if(name){  
310 - params[name] = $(item).val(); 305 + $.each(cells, function(i, cell){
  306 + var items = $('input,select', cell);
  307 + for(var j = 0, item; item = items[j++];){
  308 + name = $(item).attr('name');
  309 + if(name){
  310 + params[name] = $(item).val();
  311 + }
311 } 312 }
312 - }  
313 - });  
314 - page = num - 1;  
315 - jsDoQuery(params, false); 313 + });
  314 + page = num - 1;
  315 + jsDoQuery(params, false);
316 } 316 }
317 }); 317 });
318 } 318 }