From c97ae0369607c7091041273012b291d3b6e6bdc1 Mon Sep 17 00:00:00 2001
From: 无关风月 <443237572@qq.com>
Date: 星期一, 25 八月 2025 10:10:01 +0800
Subject: [PATCH] 迭代代码

---
 ruoyi-service/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/RegionServiceImpl.java |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/ruoyi-service/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/RegionServiceImpl.java b/ruoyi-service/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/RegionServiceImpl.java
index 1432bb9..2fe4a05 100644
--- a/ruoyi-service/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/RegionServiceImpl.java
+++ b/ruoyi-service/ruoyi-goods/src/main/java/com/ruoyi/goods/service/impl/RegionServiceImpl.java
@@ -46,6 +46,12 @@
                 region.getChildren().add(e);
             }
         });
+        for (Region region : treeData) {
+            List<Region> children = region.getChildren();
+            for (Region child : children) {
+                child.setChildren(new ArrayList<>());
+            }
+        }
         return treeData;
     }
 

--
Gitblit v1.7.1