Commit c68baa08282f72afb61d3be03254b6dbd45a616d
1 parent
2a38042d
发车的时候不再同步车载状态...
Showing
1 changed file
with
3 additions
and
3 deletions
src/main/java/com/bsth/service/gps/GpsServiceImpl.java
| @@ -205,7 +205,7 @@ public class GpsServiceImpl implements GpsService { | @@ -205,7 +205,7 @@ public class GpsServiceImpl implements GpsService { | ||
| 205 | t2 = dc.getEt(); | 205 | t2 = dc.getEt(); |
| 206 | 206 | ||
| 207 | sql.append("select DEVICE_ID,LON,LAT,TS,INOUT_STOP,SERVICE_STATE ,STOP_NO,DIRECTION,LINE_ID,SPEED_GPS,SECTION_CODE from "+tableName+" where days_year in ("+sDayOfYear+","+eDayOfYear+") " + | 207 | sql.append("select DEVICE_ID,LON,LAT,TS,INOUT_STOP,SERVICE_STATE ,STOP_NO,DIRECTION,LINE_ID,SPEED_GPS,SECTION_CODE from "+tableName+" where days_year in ("+sDayOfYear+","+eDayOfYear+") " + |
| 208 | - " and device_id='"+dc.getDevice()+"' and ts > "+t1+" and ts < "+t2+" "); | 208 | + " and device_id='"+dc.getDevice()+"' and ts >= "+t1+" and ts <= "+t2+" "); |
| 209 | 209 | ||
| 210 | if(i == len - 1) | 210 | if(i == len - 1) |
| 211 | sql.append(" ORDER BY device_id,ts,stop_no"); | 211 | sql.append(" ORDER BY device_id,ts,stop_no"); |
| @@ -910,7 +910,7 @@ public class GpsServiceImpl implements GpsService { | @@ -910,7 +910,7 @@ public class GpsServiceImpl implements GpsService { | ||
| 910 | t2 = dc.getEt(); | 910 | t2 = dc.getEt(); |
| 911 | 911 | ||
| 912 | sql.append(" select vehicle, line, up_down, lon, lat, speed,timestamp from "+tableName+" where " + | 912 | sql.append(" select vehicle, line, up_down, lon, lat, speed,timestamp from "+tableName+" where " + |
| 913 | - " weeks_year in ("+sWeekYear+", "+eWeekYear+") and vehicle='"+dc.getDevice()+"' and timestamp>"+t1+" and timestamp< " + t2); | 913 | + " weeks_year in ("+sWeekYear+", "+eWeekYear+") and vehicle='"+dc.getDevice()+"' and timestamp>="+t1+" and timestamp<= " + t2); |
| 914 | 914 | ||
| 915 | if(i == len - 1) | 915 | if(i == len - 1) |
| 916 | sql.append(" ORDER BY vehicle,timestamp"); | 916 | sql.append(" ORDER BY vehicle,timestamp"); |
| @@ -951,7 +951,7 @@ public class GpsServiceImpl implements GpsService { | @@ -951,7 +951,7 @@ public class GpsServiceImpl implements GpsService { | ||
| 951 | t2 = dc.getEt(); | 951 | t2 = dc.getEt(); |
| 952 | 952 | ||
| 953 | sql.append("select vehicle,line,up_down,lon,lat,timestamp from "+tableName+" where " + | 953 | sql.append("select vehicle,line,up_down,lon,lat,timestamp from "+tableName+" where " + |
| 954 | - " weeks_year in ("+sWeekYear+", "+eWeekYear+") and vehicle='"+dc.getDevice()+"' and timestamp>"+t1+" and timestamp<" + t2); | 954 | + " weeks_year in ("+sWeekYear+", "+eWeekYear+") and vehicle='"+dc.getDevice()+"' and timestamp>="+t1+" and timestamp<=" + t2); |
| 955 | 955 | ||
| 956 | if(i == len - 1) | 956 | if(i == len - 1) |
| 957 | sql.append(" ORDER BY vehicle,timestamp"); | 957 | sql.append(" ORDER BY vehicle,timestamp"); |