Pu Zhibing
昨天 aad8398747479ec7fbf3d40e9d6207c3d6e68f78
UserZYTravel/guns-admin/src/main/java/com/stylefeng/guns/modular/specialTrain/server/impl/OrderPrivateCarServiceImpl.java
@@ -224,6 +224,14 @@
    public ResultUtil<BaseWarpper> saveOrderPrivateCar(Integer serverCarModelId, Date travelTime, Integer reservation, Integer instead, String placementLon, String placementLat, String startLon, String startLat,
                                                       String startAddress, String endLon, String endLat, String endAddress, String name, String phone, Integer orderSource, Integer driverId, Integer type, Integer uid,
                                                       BigDecimal estimatedPrice, String cityCode, Integer carIndex) throws Exception {
        String k = "addOrder" + uid;
        boolean b = redisUtil.hasKey(k);
        if(b){
            return ResultUtil.error("不能重复下单");
        }
        redisUtil.setStrValue(k, UUIDUtil.getRandomCode(), 30);
        try {
        long timeMillis = System.currentTimeMillis();
        //如果出行时间大于当前10分钟则默认为预约单
        if(travelTime.getTime() > (System.currentTimeMillis() + 600000)){
@@ -529,6 +537,12 @@
            timeMillis = timeMillis4;
            return ResultUtil.success(baseWarpper);
        }
        }catch (Exception e){
            e.printStackTrace();
        }finally {
            redisUtil.remove(k);
        }
        return ResultUtil.error("下单失败");
    }
//    @Override