From 9b46d29e73ce2638a4cf5035abb6145ad3664c51 Mon Sep 17 00:00:00 2001 From: wxg0103 <727495428@qq.com> Date: Tue, 25 Mar 2025 14:54:53 +0800 Subject: [PATCH] refactor: lark document --- .../views/dataset/ImportDocumentDataset.vue | 40 ++++++++++++++++--- 1 file changed, 35 insertions(+), 5 deletions(-) diff --git a/ui/src/views/dataset/ImportDocumentDataset.vue b/ui/src/views/dataset/ImportDocumentDataset.vue index 84729b57..a43685f8 100644 --- a/ui/src/views/dataset/ImportDocumentDataset.vue +++ b/ui/src/views/dataset/ImportDocumentDataset.vue @@ -53,8 +53,30 @@ > @@ -93,6 +115,7 @@ const loading = ref(false) const disabled = ref(false) const allCheck = ref(false) const treeRef = ref(null) + interface Tree { name: string leaf?: boolean @@ -125,13 +148,12 @@ const loadNode = (node: Node, resolve: (nodeData: Tree[]) => void) => { .getLarkDocumentList(datasetId, token, {}, loading) .then((res: any) => { const nodes = res.data.files as Tree[] - + resolve(nodes) nodes.forEach((childNode) => { if (childNode.is_exist) { - treeRef.value?.setchecked(childNode.token, true, false) + treeRef.value?.setChecked(childNode.token, true, false) } }) - resolve(nodes) }) .catch((err) => { @@ -206,4 +228,12 @@ function back() { margin-bottom: 20px; } } +.xlsx-icon { + svg { + width: 24px; + height: 24px; + stroke: #000000 !important; + fill: #ffffff !important; + } +}