0
votes

I have created a extjs tree with the json response i.e created from the php function. I am fetching the complete data at once and convert to json and then send the response to extjs . But fetching lakhs of records and getting response at once will be a long process and may the ajax timeout happens. So what I am planning to do is to have the root nodes to be listed on first load of tree. And then on click on parent node the child nodes will be loaded by sending the parent node id.(with the extjs proxy ajax). This will help server to have less load on it. I dont want to load the lakhs of data to be loaded once. The conclusion of this logic is to have the pagination on tree grid. So my question is that is this feature supported on current version of extjs 4.1 tree.

1

1 Answers

1
votes

Yes, Simply do NOT send the "children" attribute of any node you do not wish to be loaded right away. ExtJS will automatically make another request when you try to expand a non-leaf node without any children.

Here is a nice official example from Sencha.