I have nestedlist with treestore. While loading first time the store is loaded perfectly and list is being displayed according to the store. When i click refresh button , my treestore should get reloaded with new data (with same data model as the first time) and nested list also need to be reloaded with new set of data.
Below is my treestore definition
rightPaneStoreData = getFolderListData();
rightPaneStore =new Ext.data.TreeStore({
autoLoad:false,
model: 'FIMT.models.rightPaneModel',
root: rightPaneStoreData,
proxy: {
type: 'memory',
reader: {
type: 'tree',
root: 'items'
}
},
listeners: {
datachanged: function(records){
alert("datachanged");
}
}
});
rightPaneStore.load();
In Ext.data.JsonStore i have accomplished the same using store.loaddata() method. But i couldnt find loaddata() method for TreeStore.
Kindly help me.
This is working for me. I'm using MVC and this code is called in my controller.
treeStore.getRootNode().removeAll();
treeStore.load();
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With