The cells.totalDuration() method returns the total duration of all cells in a JavaScript Scheduler row (DayPilot.Duration).
DayPilot.Row.cells.totalDuration([filter])filter (function) - optional callback that receives a cell object and returns true for cells that should be included in the calculation; available since 2024.1.5854
Returns a DayPilot.Duration object.
Calculate total duration of all cells in a row:
const total = dp.rows.find("A").cells.totalDuration();Calculate total duration of all business cells in a row:
const total = dp.rows.find("A").cells.totalDuration(cell => cell.properties.business);