fires before a new task is added to the Gantt chart
| id | string|number | the task id |
| task | Task | the task object |
| boolean | defines whether the default action of the event will be triggered (true) or canceled (false) |
gantt.attachEvent("onBeforeTaskAdd", function(id,task){
//any custom logic here
return true;
});
The event is blockable. Return false to cancel adding of the task.