liurunyu
2024-06-28 247deaeb173a6f7b593d9fa4d4ce1ae214f2cdb7
pipIrr-platform/pipIrr-web/pipIrr-web-base/src/main/java/com/dy/pipIrrBase/district/DistrictCtrl.java
@@ -297,6 +297,7 @@
                List<Map<String, Object>> list_towns = Optional.ofNullable(sv.getDistrictsBySupperId(countyId)).orElse(new ArrayList<>());
                if (list_towns.size() > 0) {
                    array_towns = JSONArray.parseArray(JSON.toJSONString(list_towns));
                    job_county.put("children", array_towns);
                    // 遍历每一个镇,将镇下村列表加到镇的子集
                    for (int j = 0; j < array_towns.size(); j++) {
                        JSONObject job_town = array_towns.getJSONObject(j);
@@ -310,7 +311,7 @@
                    //System.out.println("----" + array_towns);
                }
                // 镇村组装完毕,将镇村加到县下
                job_county.put("children", array_towns);
//                job_county.put("children", array_towns);
            }
            // 县组装完毕
            //String a = array_counties.toJSONString();