Commit 6b3607afb991c33cc51441a2e8ae80f5481be2a2

Authored by 王通
1 parent ec705dfa

1.生成线路时去掉下行的'(起点站)' '(终点站)'字样

src/main/java/com/bsth/data/car_out_info/CarOutInfoHandler.java
... ... @@ -117,7 +117,7 @@ public class CarOutInfoHandler {
117 117 //删除
118 118 jdbcTemplate.update("delete from bsth_t_clfcxxb");
119 119 //重新写入
120   - jdbcTemplate.batchUpdate("insert into bsth_t_clfcxxb(rq, line_code, line_name, lp_name, lp_sn, dfsj, nbbm, cph, bc_type, end_station_name, updown, jGh, jName, remarks, sn)" +
  120 + jdbcTemplate.batchUpdate("insert into bsth_t_clfcxxb(rq, line_code, line_name, lp_name, lp_sn, dfsj, nbbm, cph, bc_type, end_station_name, updown, jGh, jName, remarks, sn, sch)" +
121 121 " VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)", new BatchPreparedStatementSetter() {
122 122 @Override
123 123 public void setValues(PreparedStatement ps, int i) throws SQLException {
... ... @@ -137,6 +137,7 @@ public class CarOutInfoHandler {
137 137 ps.setString(13, sch.getjName());
138 138 ps.setString(14, sch.getRemarks());
139 139 ps.setInt(15, sch.getFcpSn());
  140 + ps.setLong(16, sch.getId());
140 141 }
141 142  
142 143 @Override
... ...
src/main/java/com/bsth/service/impl/StationRouteServiceImpl.java
... ... @@ -710,6 +710,9 @@ public class StationRouteServiceImpl extends BaseServiceImpl<StationRoute, Integ
710 710 String sleepStr = "";
711 711 // 方向
712 712 int directions = objects.get(i)[8]==null ? null : Integer.valueOf(objects.get(i)[8].toString());
  713 + if (directions == 1) {
  714 + stationName = stationName.replaceAll("\\(起点站\\)", "").replaceAll("\\(终点站\\)", "").replaceAll("(起点站)", "").replaceAll("(终点站)", "");
  715 + }
713 716 /** 获取路段路由信息 @pararm:<lineId:线路ID;directions:方向> */
714 717 List<Object[]> sobje = sectionRouteRepository.sectionRouteVector(lineId,directions);
715 718 if(sobje.size()==1) {
... ... @@ -799,6 +802,9 @@ public class StationRouteServiceImpl extends BaseServiceImpl&lt;StationRoute, Integ
799 802 String sleepStr = "";
800 803 // 方向
801 804 int directions = objects.get(i)[8]==null ? null : Integer.valueOf(objects.get(i)[8].toString());
  805 + if (directions == 1) {
  806 + stationName = stationName.replaceAll("\\(起点站\\)", "").replaceAll("\\(终点站\\)", "").replaceAll("(起点站)", "").replaceAll("(终点站)", "");
  807 + }
802 808 /** 获取路段路由信息 @pararm:<lineId:线路ID;directions:方向> */
803 809 List<Object[]> sobje = sectionRouteRepository.sectionRouteVector(lineId,directions);
804 810 if(sobje.size()==1) {
... ...