onBeforeLinkUpdate
Description
在更新链接之前触发
onBeforeLinkUpdate: (id: string | number, new_link: Link) => boolean;
Parameters
id- (required) string | number - 链接的 idnew_link- (required) Link - 链接的新(已更新的)对象
Returns
result- (boolean) - 定义事件的默认行为是触发 (true) 还是取消 (false)
Example
gantt.attachEvent("onBeforeLinkUpdate", function(id,new_link){
// 在这里插入您的自定义逻辑
return true;
});
Details
该事件可被阻塞。返回 false 以取消链接的更新。
Related API
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.