diff --git a/web/src/api/index.js b/web/src/api/index.js index 0a4f86f1..f783553b 100644 --- a/web/src/api/index.js +++ b/web/src/api/index.js @@ -9,24 +9,6 @@ const SIMPLE_MIND_MAP_LOCAL_CONFIG = 'SIMPLE_MIND_MAP_LOCAL_CONFIG' let mindMapData = null -/** - * @Author: 王林 - * @Date: 2021-08-02 22:36:48 - * @Desc: 克隆思维导图数据,去除激活状态 - */ -const copyMindMapTreeData = (tree, root) => { - if (!root) return null - tree.data = simpleDeepClone(root.data) - // tree.data.isActive = false - tree.children = [] - if (root.children && root.children.length > 0) { - root.children.forEach((item, index) => { - tree.children[index] = copyMindMapTreeData({}, item) - }) - } - return tree -} - /** * @Author: 王林 * @Date: 2021-08-01 10:10:49 @@ -65,7 +47,7 @@ export const storeData = data => { } else { originData = getData() } - originData.root = copyMindMapTreeData({}, data) + originData.root = data if (window.takeOverApp) { mindMapData = originData window.takeOverAppMethods.saveMindMapData(originData)