我试图显示像“graphnode6.0-----> graphnode0.0 -------> graphnode15.0”这样的力图,但是当我构造json对象时,我总是得到“graphnode6.0---- --> graphnode0.0 <---------graphnode15.0" 我的 JSON 对象是
var json = [
{
"adjacencies": [
{
"nodeTo": "graphnode15.0",
"data": {"$type":"arrow",
"$direction":"['graphnode0.0','graphnode15.0']"}
}
],
"data": {
'$color': "#83548B",
'$type': "circle"
},
"id": "graphnode0.0",
"name": "graphnode0.0"
},
{
"adjacencies": [
{
"nodeTo": "graphnode0.0",
"data": {"$type":"arrow",
"$direction":"['graphnode6.0','graphnode0.0']"}
}],
"data": {
"$color": "#83548B",
"$type": "circle"
},
"id": "graphnode6.0",
"name": "graphnode6.0"
}
];
我在这个 JSON 结构中犯了什么错误吗?谢谢苏米特