getTaskResources

returns the array of unique resources assigned to a specific task from the datastore

Resource[] getTaskResources(string | number taskId);
taskIdstring | numberthe task id
Resource[]an array of resource objects

Available only in PRO Edition

Example

gantt.getTaskResources(5); // -> see details

Related samples

Details

This functionality is available in the PRO edition only.

The getTaskResources method is not available if process_resource_assignments is disabled.

The method returns an array with objects as in:

[
    {id: 6, text: "John", parent:1, unit: "hours/day" },
    {id: 7, text: "Mike", parent:2, unit: "hours/day" }
]
See also
Change log

added in v8.0

Back to top