Commit 7f44aa98dd7551fa17867649668052ee39edb8aa

Authored by 娄高锋
1 parent 72a50070

班次到离站报表,站点编码模糊查询改成相等查询。

src/main/java/com/bsth/service/report/impl/ReportServiceImpl.java
@@ -247,8 +247,12 @@ public class ReportServiceImpl implements ReportService{ @@ -247,8 +247,12 @@ public class ReportServiceImpl implements ReportService{
247 PreparedStatement ps = null; 247 PreparedStatement ps = null;
248 ResultSet rs = null; 248 ResultSet rs = null;
249 String year=fcsj.substring(0,4); 249 String year=fcsj.substring(0,4);
250 - String sql = "select * from bsth_c_arrival_info_"+year+" where line_id=? AND weeks_year>=? "  
251 - + " AND weeks_year<=? AND ts > ? AND ts <=? AND up_down=? AND stop_no like ? order by ts"; 250 + String sql = "select * from bsth_c_arrival_info_"+year+" where line_id = ? AND weeks_year >= ? "
  251 + + " AND weeks_year <= ? AND ts > ? AND ts <= ? AND up_down = ? ";
  252 + if(zd != null && zd.length() > 0){
  253 + sql += " AND stop_no = ? ";
  254 + }
  255 + sql += " order by ts ";
252 try{ 256 try{
253 conn = DBUtils_MS.getConnection(); 257 conn = DBUtils_MS.getConnection();
254 ps = conn.prepareStatement(sql); 258 ps = conn.prepareStatement(sql);
@@ -258,7 +262,9 @@ public class ReportServiceImpl implements ReportService{ @@ -258,7 +262,9 @@ public class ReportServiceImpl implements ReportService{
258 ps.setLong(4, date1); 262 ps.setLong(4, date1);
259 ps.setLong(5, date2); 263 ps.setLong(5, date2);
260 ps.setString(6, zdlx); 264 ps.setString(6, zdlx);
261 - ps.setString(7, "%"+zd+"%"); 265 + if(zd != null && zd.length() > 0){
  266 + ps.setString(7, zd);
  267 + }
262 rs = ps.executeQuery(); 268 rs = ps.executeQuery();
263 269
264 list = resultSet2Set(rs); 270 list = resultSet2Set(rs);
src/main/resources/static/pages/report/inoutstation.html
@@ -275,8 +275,8 @@ @@ -275,8 +275,8 @@
275 $("#gsdm").val(temp[0]); 275 $("#gsdm").val(temp[0]);
276 updateCompany(); 276 updateCompany();
277 $("#fgsdm").val(temp[1]); 277 $("#fgsdm").val(temp[1]);
278 - $("#gsdm").attr("disabled", true);  
279 - $("#fgsdm").attr("disabled", true); 278 +// $("#gsdm").attr("disabled", true);
  279 +// $("#fgsdm").attr("disabled", true);
280 } 280 }
281 }); 281 });
282 282