我正在使用JStree来显示树结构及其工作正常。现在,在尝试编辑/更新树的情况下,我试图显示选定的父/子节点。
下面是我用来显示所选节点的JSON
[{"text":"func_extensions_job","children":[{"state":{"opened":true,"selected":true},"text":"CodiacSDK.NewModule.dll;extensionCreatePre;","children":[{"state":{},"text":"CodiacSDK.NewModule.dll;extensionInquirePost;","children":[{"state":{},"text":"CodiacSDK.JavaScriptWrapper.dll;UnitValues::extensionCreatePre;","children":[]},{"state":{},"text":"CodiacSDK.JavaScriptWrapper.dll;UnitValues::extensionDeletePre;","children":[]}]},{"state":{},"text":"CodiacSDK.NewModule.dll;extensionExecutePost;","children":[{"state":{},"text":"CodiacSDK.PythonWrapper.dll;UnitValues::extensionInquirePre;","children":[]},{"state":{},"text":"CodiacSDK.PythonWrapper.dll;UnitValues::extensionExecutePre;","children":[]}]}]},{"state":{},"text":"CodiacSDK.NewModule.dll;extensionDeletePre;","children":[{"state":{},"text":"CodiacSDK.NewModule.dll;extensionInquirePost;","children":[{"state":{},"text":"CodiacSDK.JavaScriptWrapper.dll;UnitValues::extensionCreatePre;","children":[]},{"state":{},"text":"CodiacSDK.JavaScriptWrapper.dll;UnitValues::extensionDeletePre;","children":[]}]},{"state":{},"text":"CodiacSDK.NewModule.dll;extensionExecutePost;","children":[{"state":{},"text":"CodiacSDK.PythonWrapper.dll;UnitValues::extensionInquirePre;","children":[]},{"state":{},"text":"CodiacSDK.PythonWrapper.dll;UnitValues::extensionExecutePre;","children":[]}]}]}]}]
我们在这里看到一些值是两次,所以我很难根据父节点显示所选节点。
我们非常感谢您的帮助。预先感谢。