Zum Hauptinhalt springen

getTaskByIndex

Description

Liefert eine Aufgabe anhand ihres globalen Aufgabenindex

getTaskByIndex: (index: number | string) => Task

Parameters

  • index - (erforderlich) number | string - der Aufgabenindex im Baum (nullbasierte Zählung)

Returns

  • task - (Task) - ein Aufgabenobjekt

Example

const globalTaskIndex = gantt.getGlobalTaskIndex(19); // -> 10

const task = gantt.getTaskByIndex(10);
// -> {id:"19", text:"Task name", type:"project", order:"10", progress:0.4, …}
Need help?
Got a question about the documentation? Reach out to our technical support team for help and guidance. For custom component solutions, visit the Services page.