EasyUI Forum

General Category => EasyUI for jQuery => Topic started by: kingor2001 on February 19, 2016, 10:57:13 PM



Title: Hope idField,treeField properties can be set in a Tree
Post by: kingor2001 on February 19, 2016, 10:57:13 PM
idField,treeField properties can be set in a TreeGrid, I hope these two attributes can also be realized in the Tree,thanks.


Title: Re: Hope idField,treeField properties can be set in a Tree
Post by: stworthy on February 20, 2016, 02:23:58 AM
The 'id' and 'text' properties are available in tree component.


Title: Re: Hope idField,treeField properties can be set in a Tree
Post by: kingor2001 on February 20, 2016, 05:07:38 AM
The 'id' and 'text' properties are available in tree component.
Thanks.
I use <ul id="myTree" data-options="id:'myId',text:'myText'"></ul>, json:[{myId:1, myText:'test'}],
but it doesn't work.


Title: Re: Hope idField,treeField properties can be set in a Tree
Post by: stworthy on February 20, 2016, 09:37:47 AM
The node data should be:
Code:
[{id:1, text:'test'}]


Title: Re: Hope idField,treeField properties can be set in a Tree
Post by: kingor2001 on February 21, 2016, 04:10:09 AM
Hope that 'id' and 'text' not fixed, but can be set, just like 'idField' and 'treefield' in the treegrid.
Thanks.