Search code examples
javascriptjsondhtmlxdhtmlx-scheduler

DHTMLX Scheduler - Events show but then disappear when loading data from multiple sources


When loading event data from multiple json sources, events will display but then will quickly disappear at random. This only occurs when loading many events (400+) from 3 or more data sources. Sometimes they will all display correctly, but most of the time the majority of them disappear.

Note: Many of the events being loaded are more than a year long.

Example using the multiple source extension:

scheduler.load(["data1.json", "data2.json", "data3.json"], "json");

I am suspicious that the events are being filtered after initialisation but can't find out why. This happens on all views.

Please help!


Solution

  • Thanks @Aliaksandr for providing the solution on DHTMLX forums:

    probably this is happening because of collision of ids between the items from different data sources. When scheduler loads an item which has the same id as one of already existing items - it assumes it is the same data item, the old one is getting replaced.

    You can try adding a prefix to ids depending on data source, in order to prevent collisions

    Forum Link: http://forum.dhtmlx.com/viewtopic.php?f=6&t=38299&p=119369#p119369