From c65d02ebea846a03292c24d9b9a0ec944f5ba621 Mon Sep 17 00:00:00 2001 From: hailin Date: Thu, 8 Jan 2026 05:31:07 -0800 Subject: [PATCH] =?UTF-8?q?fix(admin-web):=20=E4=BB=85=E5=9C=A8=E6=B2=A1?= =?UTF-8?q?=E6=9C=89=E4=B8=8A=E7=BA=A7=E6=97=B6=E6=98=BE=E7=A4=BA=E6=80=BB?= =?UTF-8?q?=E9=83=A8=E8=8A=82=E7=82=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 有上级时显示祖先节点列表 - 没有上级时才显示"总部"节点 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 --- .../src/app/(dashboard)/users/[id]/page.tsx | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/frontend/admin-web/src/app/(dashboard)/users/[id]/page.tsx b/frontend/admin-web/src/app/(dashboard)/users/[id]/page.tsx index babaffe9..91bc994c 100644 --- a/frontend/admin-web/src/app/(dashboard)/users/[id]/page.tsx +++ b/frontend/admin-web/src/app/(dashboard)/users/[id]/page.tsx @@ -413,14 +413,9 @@ export default function UserDetailPage() { {/* 向上的引荐人链 */}
引荐人链 (向上)
- {/* 总部节点(始终显示在最顶端) */} -
- 总部 -
-
- {/* 祖先节点列表 */} - {referralTree.ancestors.length > 0 && ( + {referralTree.ancestors.length > 0 ? ( <> + {/* 有上级时显示祖先节点列表 */}
{referralTree.ancestors.map((ancestor, index) => (
@@ -444,6 +439,14 @@ export default function UserDetailPage() {
+ ) : ( + <> + {/* 没有上级时显示总部节点 */} +
+ 总部 +
+
+ )}