fix(sidebar): keep partition pagination at schema root

This commit is contained in:
二丫讲梵 authored and GitHub committed 2026-07-14 01:07:17 +08:00
1 parent 8cbd41e021
commit e51004d79c
3 files changed
+37 -5

No files matched your search

+4 -1
View File
@@ -353,7 +353,10 @@ function findTableTreeNode(nodes: readonly TreeNode[], parent: TableTreeLoadMore
export function appendTableTreeLoadMoreNode(children: TreeNode[], loadMoreNode: TreeNode, parent?: TableTreeLoadMoreParent): TreeNode[] {
const parentNode = parent ? findTableTreeNode(children, parent) : undefined;
const childGroup = parentNode ? tablePartitionGroups(parentNode)[0] : undefined;
// Only TDengine pages are scoped to a STABLE's child-table group. PostgreSQL
// paginates the whole schema, so nesting its global cursor under whichever
// partition happens to end the page can hide all remaining schema objects.
const childGroup = parentNode && isSuperTable(parentNode) ? tablePartitionGroups(parentNode)[0] : undefined;
if (!childGroup) return [...children, loadMoreNode];
childGroup.children = [...(childGroup.children ?? []), loadMoreNode];