Example based on the "Basic demo"
import { Gantt, ProjectModel } from '../../build/gantt.module.js?435054';
import shared from '../_shared/shared.module.js?435054';
/* eslint-disable no-unused-vars */
const project = new ProjectModel({
transport : {
load : {
url : '../_datasets/launch-saas.json'
}
}
});
let gantt = new Gantt({
appendTo : 'container',
project : project,
columns : [
{ type : 'name', field : 'name', width : 250 }
]
});
gantt.on('beforeTaskEdit', () => {console.log('open'); return false;});
project.load();
I have done some investigation and this is because in TaskEdit.js on line 148 there is `me._editing = true;` but then when it detects the return false on line 172 it does not set editing back to false and there seems to be no way to set this value from outside the library so it becomes stuck in edit mode. I have modified the source to simply set `me._editing = false;` just before it gets to the return which has solved the issue for me so this is not an urgent problem but it would be good to have a proper way to deal with this without having to modify the library code.