Knockout-UI icon indicating copy to clipboard operation
Knockout-UI copied to clipboard

JSON data to tree

Open Umar-Mukhtar opened this issue 11 years ago • 2 comments

I am unable to load the tree when json data is passed to children object in the model. Why is that?

When -children: [] and dynamically assign when json data received tree fails.

When children: [ // { name: "Annabelle", id : '1', isOpen : true,isChecked:true, children : [ // { name: "Arnie", cssClass : 'page', id : '5',isChecked:true, children : [] }, // { name: "Anders", cssClass: 'page', id: '6', isChecked: true, children: [] }, // { name: "Apple", cssClass: 'page', id: '7', isChecked: true, children: [] } // ] // } this works like charm. Why dynamic assignment is not bieng done. Please help

Umar-Mukhtar avatar Mar 21 '13 13:03 Umar-Mukhtar

Okay, i have been able to bind the json data to model at last, Using the custom binding handler. I need to select the checkboxes from parent to child (all childs), does your library support any of these functionalities. I have grabbed the selectnode event but can't get the selected node hierarchy. Please provide any example

Umar-Mukhtar avatar Mar 22 '13 11:03 Umar-Mukhtar

Umar-Mukhtar can u please share your json code?

asif-rahman avatar Jun 05 '13 00:06 asif-rahman