Our state of the art Gantt chart


Post by Proanton »

Hi!
I replace source of data in ganttConfig.js:
Image

and get error:
Image
gantt.module.js?1c5d:9 Uncaught (in promise) TypeError: Cannot read property 'childEvents' of undefined
    at MinimalReferenceAtom.getBucket (gantt.module.js?1c5d:9)
    at MinimalReferenceAtom.put (gantt.module.js?1c5d:9)
    at _0x50f078.set (gantt.module.js?1c5d:9)
    at Function.assign (<anonymous>)
    at _0x50f078.value (gantt.module.js?1c5d:9)
    at _0x50f078.Base (gantt.module.js?1c5d:9)
    at _0x50f078.ModelStm (gantt.module.js?1c5d:9)
    at _0x50f078.TreeNode (gantt.module.js?1c5d:9)
    at _0x50f078.Model (gantt.module.js?1c5d:9)
    at _0x50f078.TimeSpan (gantt.module.js?1c5d:9)
Structure of transmitted data:
Image

What's the problem?

Post by mats »

Please provide a real test case that we can run.

Post by Proanton »

mats wrote: Mon Sep 23, 2019 12:05 pm Please provide a real test case that we can run.
In ganttConfig.js
const ganttConfig = {
  startDate : '2019-01-03 00:00',
  project : new ProjectModel({
    // Let the Project know we want to use our own Task model with custom fields / methods
    taskModelClass : Task,
    transport: {
      load : {
        url: './datasets/tests.json'
      }
    }
  }),
  ...
  
Link to download tests.json

Post by Proanton »

mats wrote: Mon Sep 23, 2019 12:05 pm Please provide a real test case that we can run.
The error occurs when children have a field "parent".
Is there an example of how to load data from flat table?

Post by mats »

'parent' is one of our reserved field names, so try using another name for your own 'parent' field if you need it. We'll improve our docs too to state this.

Post Reply