product:优化管理后台相关的接口

area:增加地区列表界面
This commit is contained in:
YunaiV
2022-12-23 18:47:59 +08:00
parent 92dde0b48b
commit 7a4a6a3046
31 changed files with 401 additions and 339 deletions

View File

@ -1,6 +1,7 @@
package cn.iocoder.yudao.framework.ip.core.utils;
import cn.hutool.core.io.resource.ResourceUtil;
import cn.hutool.core.lang.Assert;
import cn.hutool.core.text.csv.CsvRow;
import cn.hutool.core.text.csv.CsvUtil;
import cn.iocoder.yudao.framework.common.util.object.ObjectUtils;
@ -50,6 +51,7 @@ public class AreaUtils {
for (CsvRow row : rows) {
Area area = areas.get(Integer.valueOf(row.get(0))); // 自己
Area parent = areas.get(Integer.valueOf(row.get(3))); // 父
Assert.isTrue(area != parent, "{}:父子节点相同", area.getName());
area.setParent(parent);
parent.getChildren().add(area);
}

View File

@ -2567,8 +2567,6 @@ id,name,type,parentId
441826,连南瑶族自治县,4,441800
441881,英德市,4,441800
441882,连州市,4,441800
441900,东莞市,4,441900
442000,中山市,4,442000
445102,湘桥区,4,445100
445103,潮安区,4,445100
445122,饶平县,4,445100
@ -2704,7 +2702,6 @@ id,name,type,parentId
460321,西沙群岛,4,460300
460322,南沙群岛,4,460300
460323,中沙群岛的岛礁及其海域,4,460300
460400,儋州市,4,460400
469001,五指山市,4,469000
469002,琼海市,4,469000
469005,文昌市,4,469000

1 id name type parentId
2567 441826 连南瑶族自治县 4 441800
2568 441881 英德市 4 441800
2569 441882 连州市 4 441800
441900 东莞市 4 441900
442000 中山市 4 442000
2570 445102 湘桥区 4 445100
2571 445103 潮安区 4 445100
2572 445122 饶平县 4 445100
2702 460321 西沙群岛 4 460300
2703 460322 南沙群岛 4 460300
2704 460323 中沙群岛的岛礁及其海域 4 460300
460400 儋州市 4 460400
2705 469001 五指山市 4 469000
2706 469002 琼海市 4 469000
2707 469005 文昌市 4 469000