-
Notifications
You must be signed in to change notification settings - Fork 24
Open
Description
我是用的uniapp来开发微信小程序
当我给graph传入这样的数据时,可以成功绘制
graph = new F6.TreeGraph({/*...*/})
// ...
// rootNode, deviceNode是我自己定义的节点类型,用的F6.registerNode()
graph.data({
id: 'root',
type: 'rootNode',
children: [
{
id: '111',
type: 'deviceNode',
},{
id: '222',
type: 'deviceNode',
}
]
})当我给graph传入这样的数据时,会出现TypeError: Cannot read property 'index' of null,无法绘制树图
graph = new F6.TreeGraph({/*...*/})
// ...
graph.data({
id: 'root',
type: 'rootNode',
children: [
{
id: '111',
type: 'deviceNode',
children: [
{
id: '333',
type: 'deviceNode'
}
]
},{
id: '222',
type: 'deviceNode',
}
]
})请问是不是我哪里写的有问题
Metadata
Metadata
Assignees
Labels
No labels