Hello,
I have a TreeList that has 64 rows, with 24 being expandable rows.
6 rows are the parent rows that populate on loading of the TreeList.
the remaining rows are child rows that can be one row below a parent row, or they can be multiple child rows deep.
I have an image that I click to expand my rows. The first time I click it, i only want the 1st level of child rows to expand just one level.
The second time I click it, I want the child rows of this now expanded 1st level of child rows to expand only one level.
Each time I click the image, I want only one level of expansion to happen for rows that are expandable from the last level of rows that was just expanded.
I want to do the reverse for collapsing as well.
I have the following code that gets all the rows that can be toggled. However when I loop through it expanding these rows, I obviously end up expanding every row.
var rowsThatCanToggle = treelist.content.find("tr.k-treelist-group", treelist.tbody);
for (var i = 0; i < rowsThatCanToggle.length; i++) {
treelist.expand(rowsThatCanToggle[i]);
}
I have looked through documentation that shows how to expand a specific row using "tr:eq(<some index number>)" but my problem is identifying the last set
of expanded rows. Do you have any documentation or actual examples that specifically shows how to get the most recent set of expanded rows only, and how to expand their child rows?
Thank you...
I have a TreeList that has 64 rows, with 24 being expandable rows.
6 rows are the parent rows that populate on loading of the TreeList.
the remaining rows are child rows that can be one row below a parent row, or they can be multiple child rows deep.
I have an image that I click to expand my rows. The first time I click it, i only want the 1st level of child rows to expand just one level.
The second time I click it, I want the child rows of this now expanded 1st level of child rows to expand only one level.
Each time I click the image, I want only one level of expansion to happen for rows that are expandable from the last level of rows that was just expanded.
I want to do the reverse for collapsing as well.
I have the following code that gets all the rows that can be toggled. However when I loop through it expanding these rows, I obviously end up expanding every row.
var rowsThatCanToggle = treelist.content.find("tr.k-treelist-group", treelist.tbody);
for (var i = 0; i < rowsThatCanToggle.length; i++) {
treelist.expand(rowsThatCanToggle[i]);
}
I have looked through documentation that shows how to expand a specific row using "tr:eq(<some index number>)" but my problem is identifying the last set
of expanded rows. Do you have any documentation or actual examples that specifically shows how to get the most recent set of expanded rows only, and how to expand their child rows?
Thank you...