If I additionally create my own datastore with the createDatastore method, I get an empty config object back when using getDatastore. It only works for the resource datastore inside the Gantt chart. Are there explanations for this behavior?
Example:
this.resourcesDatastore = gantt.createDatastore({
name: gantt.config.resource_store,
type: “treeDatastore”,
initItem: (item) => {
item.parent = item.parent || gantt.config.root_id;
item[gantt.config.resource_property] = item.parent;
item.open = true;
return item;
}
});
getDatastore will return the datastore with all entries.
this.abcStore = gantt.createDatastore({
name: “abc”,
type: “treeDatastore”,
initItem: (item) => {
// […] parent logic
item.open = true;
return item;
}
});
getDatastore will return config object without entries.