MCPcopy Create free account
hub / github.com/DHTMLX/scheduler / handleAllEvents

Function handleAllEvents

codebase/sources/dhtmlxscheduler.es.js:18996–19018  ·  view source on GitHub ↗
(occurrence2)

Source from the content-addressed store, hash-verified

18994 }
18995 };
18996 const handleAllEvents = function(occurrence2) {
18997 let initialOccurrence = scheduler2._lame_clone(occurrence2);
18998 if (scheduler2._isExceptionFirstOccurrence(initialOccurrence)) {
18999 deleteExceptionFromStorage(initialOccurrence);
19000 }
19001 if (tempEndDate && tempStartDate) {
19002 tempEvent.start_date.setHours(tempStartDate.getHours());
19003 tempEvent.start_date.setMinutes(tempStartDate.getMinutes());
19004 tempEvent.start_date.setSeconds(tempStartDate.getSeconds());
19005 tempEvent.duration = (+tempEndDate - +tempStartDate) / 1e3;
19006 }
19007 tempEvent._beforeEventChangedFlag = occurrence2._beforeEventChangedFlag;
19008 tempEvent._thisAndFollowing = null;
19009 if (!scheduler2.config.collision_limit || scheduler2.checkCollision(tempEvent)) {
19010 for (const i in scheduler2._events) {
19011 let tev = scheduler2._events[i];
19012 if (tev.id == tempEvent.id) {
19013 scheduler2._events[i] = { ...tempEvent };
19014 scheduler2.callEvent("onEventChanged", [scheduler2._events[i].id, scheduler2._events[i]]);
19015 }
19016 }
19017 }
19018 };
19019 if (type === "ask") {
19020 buttons = ["occurrence", "following", "series"];
19021 } else {

Callers 1

recurringFunction · 0.70

Calls 3

checkCollisionMethod · 0.65
callEventMethod · 0.65

Tested by

no test coverage detected