an object of the lightbox controls
gantt.form_blocks["date_local_editor"] = {
render: function (sns) {
return "<input class='custom_section' type='datetime-local' name='1'>"
},
set_value: function (node, value, task) {
if (task.start_date) {
const dateValue = gantt.date.date_to_str("%Y-%m-%d")(value);
const timeValue = gantt.date.date_to_str("%H:%i")(value);
const dateLocalValue = dateValue + "T" + timeValue;
node.value = dateLocalValue;
}
},
get_value: function (node, task) {
task.start_date = new Date(node.value)
task.end_date = gantt.calculateEndDate(task)
return task.start_date;
},
focus: function (node) {
const a = node;
a.select();
a.focus();
}
};
The object has the following types: