Custom ColumnTree node attributes
By default, ColumnTree uses these attributes for the nodes: text, id, leaf
. So, the server sould sends something like
{
id: 1,
text: 'A leaf Node',
leaf: true
}
What should i change in the ColumnTree options if my server sends custom params开发者_StackOverflow中文版? Like:
{
n: 1,
folder: 'A leaf Node',
leaf: true
}
You can override the method createNode and assemble your own attributes hash from the data you received from the server. Check the example in the docs of Ext.tree.TreeLoader.createNode
精彩评论