isTaskExists

验证是否存在具有指定 ID 的任务

boolean isTaskExists(string | number id);
idstring | number任务 ID
booleantrue 如果找到任务,否则为 false

Example

gantt.addTask({
    id:10,
    text:"Task #5",
    start_date:"02-09-2023",
    duration:28
}, "project_2");
 
gantt.isTaskExists(10); // ->true

Back to top