jinpengyong
2020-09-09 a978b4279a12497d0b476b0df31b1c8409498676
src/main/java/com/moral/service/impl/RealWeatherServiceImpl.java
@@ -93,6 +93,13 @@
            hashMap.put("cityCode", code);
            hashSet.add(hashMap);
        }
        Map<String,Object> kunShanMap=new HashMap<>();
        kunShanMap.put("name1","苏州市");
        kunShanMap.put("parentName","江苏省");
        kunShanMap.put("cityCode",320500);
        hashSet.add(kunShanMap);
        List<Element> elements = Dom4jUtils.readDocument();
        String cityID = "101190404";
        for (Map<String, Object> map : hashSet) {
@@ -145,7 +152,7 @@
                jsonMap.put("condition","80");
            }else if(text.equals("阴")){
                jsonMap.put("condition","60");
            }else if(text.equals("雷阵雨")){
            }else if(text.equals("雷阵雨")||text.equals("阵雨")){
                jsonMap.put("condition","40");
            }else if(text.equals("小雨")){
                jsonMap.put("condition","20");
@@ -155,6 +162,6 @@
            resultMap.put("json",JSONObject.toJSONString(jsonMap));
            resultList.add(resultMap);
        }
        return realWeatherMapper.insertRealWeather(null);
        return realWeatherMapper.insertRealWeather(resultList);
    }
}