|
@@ -851,6 +851,11 @@ public class RouteServiceImpl implements RouteService {
|
|
public CurrentLocationResult getCurrentLocation(String capcityNumber) throws Exception {
|
|
public CurrentLocationResult getCurrentLocation(String capcityNumber) throws Exception {
|
|
String json = zhongJiaoXingLu.vLastLocationV3(capcityNumber);
|
|
String json = zhongJiaoXingLu.vLastLocationV3(capcityNumber);
|
|
CurrentLocationResult currentLocationResult = (CurrentLocationResult) DataConversionTool.jsonToBean(json, CurrentLocationResult.class);
|
|
CurrentLocationResult currentLocationResult = (CurrentLocationResult) DataConversionTool.jsonToBean(json, CurrentLocationResult.class);
|
|
|
|
+ if(currentLocationResult.getResult().getLat()!=null&¤tLocationResult.getResult().getLon()!=null){
|
|
|
|
+ Double[] lngLon = LngLonUtil.gps84_To_Gcj02((Double.valueOf(currentLocationResult.getResult().getLat()) / 600000), (Double.valueOf(currentLocationResult.getResult().getLon()) / 600000));
|
|
|
|
+ currentLocationResult.getResult().setLat(lngLon[0].toString());
|
|
|
|
+ currentLocationResult.getResult().setLon(lngLon[1].toString());
|
|
|
|
+ }
|
|
return currentLocationResult;
|
|
return currentLocationResult;
|
|
}
|
|
}
|
|
|
|
|