Demo:update
This commit is contained in:
parent
740c898bb1
commit
e966e5d57c
@ -14,6 +14,7 @@ let mindMapData = null
|
|||||||
* @Desc: 克隆思维导图数据,去除激活状态
|
* @Desc: 克隆思维导图数据,去除激活状态
|
||||||
*/
|
*/
|
||||||
const copyMindMapTreeData = (tree, root) => {
|
const copyMindMapTreeData = (tree, root) => {
|
||||||
|
if (!root) return null
|
||||||
tree.data = simpleDeepClone(root.data)
|
tree.data = simpleDeepClone(root.data)
|
||||||
// tree.data.isActive = false
|
// tree.data.isActive = false
|
||||||
tree.children = []
|
tree.children = []
|
||||||
|
|||||||
@ -70,6 +70,7 @@ export default {
|
|||||||
* @Desc: 遍历
|
* @Desc: 遍历
|
||||||
*/
|
*/
|
||||||
walk(data) {
|
walk(data) {
|
||||||
|
if (!data) return
|
||||||
this.num++
|
this.num++
|
||||||
this.textStr += String(data.data.text) || ''
|
this.textStr += String(data.data.text) || ''
|
||||||
if (data.children && data.children.length > 0) {
|
if (data.children && data.children.length > 0) {
|
||||||
|
|||||||
@ -179,7 +179,7 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
activeNodes: [],
|
activeNodes: [],
|
||||||
backEnd: false,
|
backEnd: true,
|
||||||
forwardEnd: true,
|
forwardEnd: true,
|
||||||
readonly: false,
|
readonly: false,
|
||||||
isFullDataFile: false,
|
isFullDataFile: false,
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user