Hi how can i close second level nodes please.
https://s10.postimg.org/8ouy6zo95/Capturar.jpg
Thank you
4 Answers, 1 is accepted
The TreeList API has collapse method, which accepts a TR element (corresponding to the record) that will be collapsed. For your convenience, I have created the following dojo example, which demonstrates how you could use the collapse method and the rendering of the TreeList to achieve the desired result:
Hope this helps.
Regards,
Konstantin Dikov
Telerik by Progress
Thank you
Konstantin Dikov that is what i need thank you
now im getting a error and averything get slow
Um script nesta página pode estar ocupado ou pode ter parado de responder. Pode parar o script agora, a
Script: http:/Con…s/plugins/jquery/jquery.min.js:4
function onClickCollapse() {
console.log("onClickCollapse");
var level = 1;
var treeList = $("#DefinitionTreeList").data("kendoTreeList");
var rows = treeList.element.find(".k-grid-content [role='row']");
rows.each(function () {
var row = $(this);
if(row.find(".k-i-none").length == level){
treeList.collapse(row);
}
})
}
Could you please modify the dojo example from my previous post, so it could replicate the error that you are receiving:
Looking forward to your reply.
Regards,
Konstantin Dikov
Telerik by Progress