I use the builtin navigation to switch one week backwards or forwards. The whole data, section and events, is coming from the scheduler.serverList(). The first view is correct. Clicking on the next week, a new request is made against the backend, but data from the first week is also displayed. Moving back there is no call to the backend but cached data is shown but also incorrectly. How to force data retrieval each time a navigation is clicked and how to clear the existing data? Thank you for any help
dhtmlxScheduler caches previously loaded dates, so every date range is loaded only once.
If you want to bypass this cache, you'll need to clear the scheduler each time you change the date/mode:
scheduler.attachEvent("onBeforeViewChange", function (oldMode, oldDate, mode, date) {
if (oldMode != mode || +oldDate != +date) {
scheduler.clearAll();
}
return true;
});
Demo: https://snippet.dhtmlx.com/e5b55912e
API: