From d5b37d1ed0847b2daf39060ca7a0a05f73eda111 Mon Sep 17 00:00:00 2001 From: Allen Date: Fri, 20 Oct 2023 13:37:58 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20editor=20manager=20getContentSchemas=20?= =?UTF-8?q?=E4=B8=AD=20type=20=E8=8E=B7=E5=8F=96=E9=97=AE=E9=A2=98=20(#844?= =?UTF-8?q?3)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/amis-editor-core/src/manager.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/amis-editor-core/src/manager.ts b/packages/amis-editor-core/src/manager.ts index a9f444ec7..37673117d 100644 --- a/packages/amis-editor-core/src/manager.ts +++ b/packages/amis-editor-core/src/manager.ts @@ -1983,7 +1983,8 @@ export class EditorManager { // 更新组件树中的所有上下文数据声明为最新数据 while (scope) { - const [nodeId, type] = scope.id.split('-'); + const [nodeId] = scope.id.split('-'); + const type = scope.id.replace(`${nodeId}-`, ''); const scopeNode = this.store.getNodeById(nodeId, type); // 拿非重复组件id的父组件作为主数据域展示,如CRUD,不展示表格,只展示增删改查信息,避免变量面板出现两份数据