| | |
| | | if(xpVehicle== null){ |
| | | throw new ServiceException("获取行驶中的车辆信息错误"); |
| | | } |
| | | //剩余里程xx米,或者 剩余时间xx分钟 禁止修改目的地 |
| | | //获取订单的 |
| | | Object cacheObject = redisService.getCacheObject(CacheConstants.navigationEnd(uid)); |
| | | if(cacheObject != null){ |
| | | RouteVo routeRemain = JSON.parseObject(cacheObject.toString(), RouteVo.class); |
| | | Integer xczSyDistance = routeRemain.getDistance();//行程中剩余里程 |
| | | Integer xczSyTime = routeRemain.getDuration();//行程中剩余时间 |
| | | if(systemSetting.getXczSyDistance()<xczSyDistance || systemSetting.getXczSyTime() < xczSyTime){ |
| | | throw new ServiceException("即将达到终点,禁止修改目的地"); |
| | | } |
| | | } |
| | | |
| | | // 是否在运营区域时间内 |
| | | XpElectronicFenceArea xpElectronicFenceArea = xpElectronicFenceAreaMapper.selectById(order.getXpElectronicFenceAreaId()); |
| | |
| | | //获取距离和时间 |
| | | this.getDD(uid,dto); |
| | | |
| | | |
| | | //将修改信息存入到redis, |
| | | // 获取起点经纬度 |
| | | XpPoint xpPoint = xpPointService.getById(order.getStartPointId()); |