Your data should be accessible in json in this format:
[
{
"text":"Years",
"nodes":[
{
"text":"2013",
"type":"Y",
"nodes":[
{
"text":"13-Q1",
"type":"Q"
},
{
"text":"13-01",
"type":"M"
},
{
"text":"13-02"
},
{
"text":"13-03"
}
]
}
]
}
]
Using any method (ajax, for example) you can deserialize it:
$.get('url', function (data) {
$('#Dyanmic').treeview({
data: data,
});
source
share