The rows.collapse() method collapses the specified rows (tree nodes) of the JavaScript Scheduler.
Available since 2025.4.6661.
DayPilot.Scheduler.rows.find(f);
f
(function) - filter function that returns true
for rows that will be collapsed
Filter function syntax:
function f(row) {}
Filter function parameters:
row
- DayPilot.Row object
Collapse all siblings of the target
row:
const target = scheduler.rows.find("A1");
scheduler.rows.collapse(row => row.parent().id === target.parent().id);