I am using the browser-layout example for my application.
I\'m trying to add a tree grid to it. I defined a new class, but when I call my tree grid I can see the gr
var store = Ext.create('Ext.data.TreeStore', {
proxy:{
type: 'ajax',
url: 'myTree.json',
},
reader:{
type: 'ajax',
root: 'nodes',
record: 'leaf'
}
});
var myTree = Ext.create('Ext.tree.Panel', {
store: store,
rootVisible: false,
border: false,
renderTo:Ext.getBody() //missing
});
JSON
{
children: [
{ text:"Clients", expanded: true,
children: [{ text:"MAIN", leaf: true }]
}
]
}
Here is an working example, u can define myTree and call it in your Browser-layout!
Go to firebug NET console, refresh the page and search for treeGrid.json,
Hover over with mouse to see full URL
Update store with correct path from localstore to a folder with your .json
Try now!