puzhibing
2023-06-12 d4f8078c2a062864dab885d6bd54fbe1195f85e2
user/guns-admin/src/main/java/com/agentdriving/user/modular/system/service/impl/SystemConfigServiceImpl.java
@@ -71,7 +71,12 @@
                map2.put("time", ToolUtil.isEmpty(num1) ? "其他时段" : num1 + "-" + num2);
                map2.put("startingMileage", num4 + "-" + num5 + "公里");
                map2.put("startingPrice", num6 + "元");
                map2.put("exceedStartingPrice", num7 + "元/" + num8 + "公里");
                if(num6 == 0){
                    JSONObject jsonObject2 = num3.getJSONObject(num3.size() - 1);
                    Double num3_1 = jsonObject2.getDouble("num3");
                    map2.put("startingPrice", num3_1 + "元");
                }
                map2.put("exceedStartingPrice", num7 + "公里/" + num8 + "元");
                longDistanceCharges.add(map2);
            }
            priceRulesWarpper.setBasePrice(JSON.toJSONString(basePrice));
@@ -90,7 +95,13 @@
            Map<String, Object> map = new HashMap<>();
            map.put("waitTime", num1 + "分钟/" + num2 + "元");
            map.put("exceedWaitTime", "超出" + num3 + "分钟,收取" + num4 + "元/分钟");
            map.put("badWeather", num5 + "公里内加收" + num6 + "元,超过" + num7 + "公里按照订单单价的" + num8 + "倍计费,最高收取" + num9 + "元");
            map.put("badWeather", "");
            systemConfig = this.selectOne(new EntityWrapper<SystemConfig>().eq("type", 8));
            JSONObject jsonObject1 = JSON.parseObject(systemConfig.getContent());
            Integer num11 = jsonObject1.getInteger("num1");//开启恶劣天气计价
            if(1 == num11){
                map.put("badWeather", num5 + "公里内加收" + num6 + "元,超过" + num7 + "公里按照订单单价的" + num8 + "倍计费,最高收取" + num9 + "元");
            }
            priceRulesWarpper.setAdditionalFee(JSON.toJSONString(map));
        }
        return priceRulesWarpper;