@syncfusion/ej2-schedule 20.3.58 → 20.4.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.json +16 -1
- package/CHANGELOG.md +10 -0
- package/README.md +62 -46
- package/dist/ej2-schedule.min.js +2 -2
- package/dist/ej2-schedule.umd.min.js +2 -2
- package/dist/ej2-schedule.umd.min.js.map +1 -1
- package/dist/es6/ej2-schedule.es2015.js +821 -528
- package/dist/es6/ej2-schedule.es2015.js.map +1 -1
- package/dist/es6/ej2-schedule.es5.js +860 -539
- package/dist/es6/ej2-schedule.es5.js.map +1 -1
- package/dist/global/ej2-schedule.min.js +2 -2
- package/dist/global/ej2-schedule.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +22 -30
- package/src/common/calendar-util.js +1 -1
- package/src/recurrence-editor/date-generator.js +26 -26
- package/src/recurrence-editor/recurrence-editor.js +5 -5
- package/src/schedule/actions/action-base.js +3 -3
- package/src/schedule/actions/crud.js +16 -16
- package/src/schedule/actions/drag.js +36 -32
- package/src/schedule/actions/keyboard.js +10 -8
- package/src/schedule/actions/resize.js +6 -6
- package/src/schedule/actions/touch.js +4 -3
- package/src/schedule/actions/virtual-scroll.js +10 -7
- package/src/schedule/base/interface.d.ts +8 -1
- package/src/schedule/base/resource.d.ts +1 -0
- package/src/schedule/base/resource.js +179 -93
- package/src/schedule/base/schedule-model.d.ts +7 -0
- package/src/schedule/base/schedule.d.ts +23 -0
- package/src/schedule/base/schedule.js +73 -22
- package/src/schedule/base/util.js +4 -6
- package/src/schedule/event-renderer/agenda-base.js +36 -31
- package/src/schedule/event-renderer/event-base.js +25 -25
- package/src/schedule/event-renderer/inline-edit.js +8 -5
- package/src/schedule/event-renderer/month.js +17 -14
- package/src/schedule/event-renderer/timeline-view.js +11 -11
- package/src/schedule/event-renderer/vertical-view.d.ts +1 -0
- package/src/schedule/event-renderer/vertical-view.js +97 -70
- package/src/schedule/event-renderer/year.js +25 -17
- package/src/schedule/exports/calendar-export.js +4 -4
- package/src/schedule/exports/calendar-import.js +14 -15
- package/src/schedule/exports/excel-export.js +1 -1
- package/src/schedule/exports/print.js +39 -4
- package/src/schedule/models/group-model.d.ts +8 -0
- package/src/schedule/models/group.d.ts +7 -0
- package/src/schedule/models/group.js +3 -0
- package/src/schedule/models/views-model.d.ts +8 -1
- package/src/schedule/models/views.d.ts +7 -1
- package/src/schedule/models/views.js +3 -0
- package/src/schedule/popups/event-tooltip.js +3 -2
- package/src/schedule/popups/event-window.js +36 -30
- package/src/schedule/popups/quick-popups.js +6 -6
- package/src/schedule/renderer/agenda.js +5 -5
- package/src/schedule/renderer/header-renderer.d.ts +1 -1
- package/src/schedule/renderer/header-renderer.js +21 -5
- package/src/schedule/renderer/month-agenda.js +11 -4
- package/src/schedule/renderer/month.js +44 -16
- package/src/schedule/renderer/renderer.js +3 -3
- package/src/schedule/renderer/timeline-header-row.js +7 -7
- package/src/schedule/renderer/timeline-month.js +5 -5
- package/src/schedule/renderer/timeline-view.js +2 -2
- package/src/schedule/renderer/timeline-year.js +20 -14
- package/src/schedule/renderer/vertical-view.js +24 -9
- package/src/schedule/renderer/view-base.d.ts +3 -0
- package/src/schedule/renderer/view-base.js +11 -3
- package/src/schedule/renderer/year.js +11 -5
- package/styles/bootstrap-dark.css +364 -101
- package/styles/bootstrap.css +363 -99
- package/styles/bootstrap4.css +375 -141
- package/styles/bootstrap5-dark.css +339 -137
- package/styles/bootstrap5.css +339 -137
- package/styles/fabric-dark.css +330 -101
- package/styles/fabric.css +316 -106
- package/styles/fluent-dark.css +395 -102
- package/styles/fluent.css +395 -102
- package/styles/highcontrast-light.css +407 -98
- package/styles/highcontrast.css +399 -113
- package/styles/material-dark.css +362 -110
- package/styles/material.css +404 -110
- package/styles/recurrence-editor/_layout.scss +42 -28
- package/styles/recurrence-editor/bootstrap-dark.css +137 -28
- package/styles/recurrence-editor/bootstrap-dark.scss +5 -0
- package/styles/recurrence-editor/bootstrap.css +137 -28
- package/styles/recurrence-editor/bootstrap.scss +5 -0
- package/styles/recurrence-editor/bootstrap4.css +171 -28
- package/styles/recurrence-editor/bootstrap4.scss +5 -0
- package/styles/recurrence-editor/bootstrap5-dark.css +178 -28
- package/styles/recurrence-editor/bootstrap5-dark.scss +5 -0
- package/styles/recurrence-editor/bootstrap5.css +178 -28
- package/styles/recurrence-editor/bootstrap5.scss +5 -0
- package/styles/recurrence-editor/fabric-dark.css +113 -28
- package/styles/recurrence-editor/fabric-dark.scss +5 -0
- package/styles/recurrence-editor/fabric.css +106 -28
- package/styles/recurrence-editor/fabric.scss +5 -0
- package/styles/recurrence-editor/fluent-dark.css +158 -28
- package/styles/recurrence-editor/fluent-dark.scss +5 -0
- package/styles/recurrence-editor/fluent.css +158 -28
- package/styles/recurrence-editor/fluent.scss +5 -0
- package/styles/recurrence-editor/highcontrast-light.css +110 -28
- package/styles/recurrence-editor/highcontrast-light.scss +5 -0
- package/styles/recurrence-editor/highcontrast.css +110 -28
- package/styles/recurrence-editor/highcontrast.scss +5 -0
- package/styles/recurrence-editor/material-dark.css +138 -28
- package/styles/recurrence-editor/material-dark.scss +5 -0
- package/styles/recurrence-editor/material.css +163 -28
- package/styles/recurrence-editor/material.scss +5 -0
- package/styles/recurrence-editor/tailwind-dark.css +126 -28
- package/styles/recurrence-editor/tailwind-dark.scss +5 -0
- package/styles/recurrence-editor/tailwind.css +126 -28
- package/styles/recurrence-editor/tailwind.scss +5 -0
- package/styles/schedule/_bootstrap-dark-definition.scss +63 -4
- package/styles/schedule/_bootstrap-definition.scss +62 -3
- package/styles/schedule/_bootstrap4-definition.scss +65 -5
- package/styles/schedule/_bootstrap5-definition.scss +63 -5
- package/styles/schedule/_fabric-dark-definition.scss +61 -3
- package/styles/schedule/_fabric-definition.scss +62 -3
- package/styles/schedule/_fluent-definition.scss +63 -6
- package/styles/schedule/_fusionnew-definition.scss +60 -3
- package/styles/schedule/_highcontrast-definition.scss +62 -3
- package/styles/schedule/_highcontrast-light-definition.scss +62 -3
- package/styles/schedule/_layout.scss +117 -506
- package/styles/schedule/_material-dark-definition.scss +63 -4
- package/styles/schedule/_material-definition.scss +63 -4
- package/styles/schedule/_material3-definition.scss +62 -3
- package/styles/schedule/_tailwind-definition.scss +63 -6
- package/styles/schedule/_theme.scss +97 -62
- package/styles/schedule/bootstrap-dark.css +332 -73
- package/styles/schedule/bootstrap-dark.scss +11 -0
- package/styles/schedule/bootstrap.css +331 -71
- package/styles/schedule/bootstrap.scss +11 -0
- package/styles/schedule/bootstrap4.css +343 -113
- package/styles/schedule/bootstrap4.scss +11 -0
- package/styles/schedule/bootstrap5-dark.css +307 -109
- package/styles/schedule/bootstrap5-dark.scss +11 -0
- package/styles/schedule/bootstrap5.css +307 -109
- package/styles/schedule/bootstrap5.scss +11 -0
- package/styles/schedule/fabric-dark.css +298 -73
- package/styles/schedule/fabric-dark.scss +11 -0
- package/styles/schedule/fabric.css +284 -78
- package/styles/schedule/fabric.scss +11 -0
- package/styles/schedule/fluent-dark.css +363 -74
- package/styles/schedule/fluent-dark.scss +11 -0
- package/styles/schedule/fluent.css +363 -74
- package/styles/schedule/fluent.scss +11 -0
- package/styles/schedule/highcontrast-light.css +375 -70
- package/styles/schedule/highcontrast-light.scss +11 -0
- package/styles/schedule/highcontrast.css +367 -85
- package/styles/schedule/highcontrast.scss +11 -0
- package/styles/schedule/material-dark.css +330 -82
- package/styles/schedule/material-dark.scss +11 -0
- package/styles/schedule/material.css +372 -82
- package/styles/schedule/material.scss +11 -0
- package/styles/schedule/tailwind-dark.css +246 -111
- package/styles/schedule/tailwind-dark.scss +11 -0
- package/styles/schedule/tailwind.css +246 -111
- package/styles/schedule/tailwind.scss +11 -0
- package/styles/tailwind-dark.css +279 -140
- package/styles/tailwind.css +279 -140
package/dist/global/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* filename: index.d.ts
|
|
3
|
-
* version : 20.
|
|
3
|
+
* version : 20.4.38
|
|
4
4
|
* Copyright Syncfusion Inc. 2001 - 2020. All rights reserved.
|
|
5
5
|
* Use of this code is subject to the terms of our license.
|
|
6
6
|
* A copy of the current license can be obtained at any time by e-mailing
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_from": "@syncfusion/ej2-schedule@*",
|
|
3
|
-
"_id": "@syncfusion/ej2-schedule@20.
|
|
3
|
+
"_id": "@syncfusion/ej2-schedule@20.5.7",
|
|
4
4
|
"_inBundle": false,
|
|
5
|
-
"_integrity": "sha512-
|
|
5
|
+
"_integrity": "sha512-qajhFVIbVBCkvwjV/ML2AK+TS8uLEVZSV4Jn2vtDkT7suKgmtNVuK/ZvKWjYB7h4hoe33QQE3LXC5GRe3NOYVg==",
|
|
6
6
|
"_location": "/@syncfusion/ej2-schedule",
|
|
7
7
|
"_phantomChildren": {},
|
|
8
8
|
"_requested": {
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"/@syncfusion/ej2-react-schedule",
|
|
24
24
|
"/@syncfusion/ej2-vue-schedule"
|
|
25
25
|
],
|
|
26
|
-
"_resolved": "https://nexus.syncfusion.com/repository/ej2-
|
|
27
|
-
"_shasum": "
|
|
26
|
+
"_resolved": "https://nexus.syncfusion.com/repository/ej2-release/@syncfusion/ej2-schedule/-/ej2-schedule-20.5.7.tgz",
|
|
27
|
+
"_shasum": "28559de82dfe255f876566b637f67a14947838c5",
|
|
28
28
|
"_spec": "@syncfusion/ej2-schedule@*",
|
|
29
29
|
"_where": "/jenkins/workspace/ease-automation_release_19.1.0.1/packages/included",
|
|
30
30
|
"author": {
|
|
@@ -35,16 +35,16 @@
|
|
|
35
35
|
},
|
|
36
36
|
"bundleDependencies": false,
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@syncfusion/ej2-base": "~20.
|
|
39
|
-
"@syncfusion/ej2-buttons": "~20.
|
|
40
|
-
"@syncfusion/ej2-calendars": "~20.
|
|
41
|
-
"@syncfusion/ej2-data": "~20.
|
|
42
|
-
"@syncfusion/ej2-dropdowns": "~20.
|
|
43
|
-
"@syncfusion/ej2-excel-export": "~20.
|
|
44
|
-
"@syncfusion/ej2-inputs": "~20.
|
|
45
|
-
"@syncfusion/ej2-lists": "~20.
|
|
46
|
-
"@syncfusion/ej2-navigations": "~20.
|
|
47
|
-
"@syncfusion/ej2-popups": "~20.
|
|
38
|
+
"@syncfusion/ej2-base": "~20.4.38",
|
|
39
|
+
"@syncfusion/ej2-buttons": "~20.4.38",
|
|
40
|
+
"@syncfusion/ej2-calendars": "~20.4.38",
|
|
41
|
+
"@syncfusion/ej2-data": "~20.4.38",
|
|
42
|
+
"@syncfusion/ej2-dropdowns": "~20.4.38",
|
|
43
|
+
"@syncfusion/ej2-excel-export": "~20.4.38",
|
|
44
|
+
"@syncfusion/ej2-inputs": "~20.4.38",
|
|
45
|
+
"@syncfusion/ej2-lists": "~20.4.38",
|
|
46
|
+
"@syncfusion/ej2-navigations": "~20.4.38",
|
|
47
|
+
"@syncfusion/ej2-popups": "~20.4.38"
|
|
48
48
|
},
|
|
49
49
|
"deprecated": false,
|
|
50
50
|
"description": "Flexible scheduling library with more built-in features and enhanced customization options similar to outlook and google calendar, allowing the users to plan and manage their appointments with efficient data-binding support.",
|
|
@@ -54,23 +54,15 @@
|
|
|
54
54
|
"keywords": [
|
|
55
55
|
"ej2",
|
|
56
56
|
"syncfusion",
|
|
57
|
-
"
|
|
57
|
+
"JavaScript",
|
|
58
58
|
"TypeScript",
|
|
59
59
|
"schedule",
|
|
60
|
-
"
|
|
61
|
-
"
|
|
62
|
-
"
|
|
63
|
-
"
|
|
64
|
-
"
|
|
65
|
-
"
|
|
66
|
-
"appointments",
|
|
67
|
-
"events",
|
|
68
|
-
"tasks",
|
|
69
|
-
"recurrence",
|
|
70
|
-
"data-binding",
|
|
71
|
-
"timezone",
|
|
72
|
-
"recurrence-editor",
|
|
73
|
-
"agenda"
|
|
60
|
+
"scheduler",
|
|
61
|
+
"events-calendar",
|
|
62
|
+
"events-scheduler",
|
|
63
|
+
"appointment-calendar",
|
|
64
|
+
"appointments-planner",
|
|
65
|
+
"resources-scheduler"
|
|
74
66
|
],
|
|
75
67
|
"license": "SEE LICENSE IN license",
|
|
76
68
|
"main": "./dist/ej2-schedule.umd.min.js",
|
|
@@ -81,6 +73,6 @@
|
|
|
81
73
|
"url": "git+https://github.com/syncfusion/ej2-javascript-ui-controls.git"
|
|
82
74
|
},
|
|
83
75
|
"typings": "index.d.ts",
|
|
84
|
-
"version": "20.
|
|
76
|
+
"version": "20.4.38",
|
|
85
77
|
"sideEffects": false
|
|
86
78
|
}
|
|
@@ -157,7 +157,7 @@ var Islamic = /** @class */ (function () {
|
|
|
157
157
|
var hDate = this.getHijriDate(date);
|
|
158
158
|
var day = [];
|
|
159
159
|
for (var i = 0; i < days.length; i++) {
|
|
160
|
-
var gDate = HijriParser.toGregorian(hDate.year, hDate.month, days[i]);
|
|
160
|
+
var gDate = HijriParser.toGregorian(hDate.year, hDate.month, days[parseInt(i.toString(), 10)]);
|
|
161
161
|
day.push(gDate.getDate());
|
|
162
162
|
}
|
|
163
163
|
return day;
|
|
@@ -46,7 +46,7 @@ export function generateSummary(rule, localeObject, locale, calendarType) {
|
|
|
46
46
|
case 'WEEKLY':
|
|
47
47
|
summary += localeObject.getConstant(WEEKS) + ' ' + localeObject.getConstant(ON) + ' ';
|
|
48
48
|
ruleObject.day.forEach(function (day, index) {
|
|
49
|
-
summary += capitalizeFirstWord(getValue(DAYINDEXOBJECT[day], cldrObj), 'single');
|
|
49
|
+
summary += capitalizeFirstWord(getValue(DAYINDEXOBJECT["" + day], cldrObj), 'single');
|
|
50
50
|
summary += (((ruleObject.day.length - 1) === index) ? '' : ', ');
|
|
51
51
|
});
|
|
52
52
|
break;
|
|
@@ -144,7 +144,7 @@ export function generate(startDate, rule, excludeDate, startDayOfWeek, maximumCo
|
|
|
144
144
|
return data;
|
|
145
145
|
}
|
|
146
146
|
maxOccurrence = maximumCount;
|
|
147
|
-
setFirstDayOfWeek(DAYINDEX[startDayOfWeek]);
|
|
147
|
+
setFirstDayOfWeek(DAYINDEX[parseInt(startDayOfWeek.toString(), 10)]);
|
|
148
148
|
if (ruleObject.until) {
|
|
149
149
|
var end = resetTime(ruleObject.until);
|
|
150
150
|
ruleObject.until = new Date(end.getFullYear(), end.getMonth(), end.getDate(), 23, 59, 59);
|
|
@@ -420,7 +420,7 @@ function processWeekNo(startDate, endDate, data, ruleObject) {
|
|
|
420
420
|
startDay = dayIndex.indexOf(DAYINDEX[stDate.getDay()]);
|
|
421
421
|
firstWeekSpan = (6 - startDay) + 1;
|
|
422
422
|
for (var index = 0; index < weekNos.length; index++) {
|
|
423
|
-
weekNo = weekNos[index];
|
|
423
|
+
weekNo = weekNos[parseInt(index.toString(), 10)];
|
|
424
424
|
weekNo = (weekNo > 0) ? weekNo : 53 + weekNo + 1;
|
|
425
425
|
maxDate = (weekNo === 1) ? firstWeekSpan : firstWeekSpan + ((weekNo - 1) * 7);
|
|
426
426
|
minDate = (weekNo === 1) ? firstWeekSpan - 7 : firstWeekSpan + ((weekNo - 2) * 7);
|
|
@@ -467,7 +467,7 @@ function processYearDay(startDate, endDate, data, ruleObject) {
|
|
|
467
467
|
var expectedDays = ruleObject.day;
|
|
468
468
|
while (compareDates(stDate, endDate)) {
|
|
469
469
|
for (var index = 0; index < ruleObject.yearDay.length; index++) {
|
|
470
|
-
date = ruleObject.yearDay[index];
|
|
470
|
+
date = ruleObject.yearDay[parseInt(index.toString(), 10)];
|
|
471
471
|
tempDate = new Date(stDate.getTime());
|
|
472
472
|
if ((date === calendarUtil.getLeapYearDaysCount() || date === -calendarUtil.getLeapYearDaysCount()) &&
|
|
473
473
|
(!calendarUtil.isLeapYear(calendarUtil.getFullYear(tempDate), 1))) {
|
|
@@ -627,7 +627,7 @@ function monthlyDateTypeProcessforMonthFreq(startDate, endDate, data, ruleObject
|
|
|
627
627
|
*/
|
|
628
628
|
function processDateCollectionForByMonthDay(ruleObject, recRuleVariables, endDate, isByMonth, startDate, data) {
|
|
629
629
|
for (var index = 0; index < ruleObject.monthDay.length; index++) {
|
|
630
|
-
recRuleVariables.date = ruleObject.monthDay[index];
|
|
630
|
+
recRuleVariables.date = ruleObject.monthDay[parseInt(index.toString(), 10)];
|
|
631
631
|
recRuleVariables.tempDate = calendarUtil.getMonthStartDate(recRuleVariables.tempDate);
|
|
632
632
|
var maxDate = calendarUtil.getMonthDaysCount(recRuleVariables.tempDate);
|
|
633
633
|
recRuleVariables.date = recRuleVariables.date > 0 ? recRuleVariables.date : (maxDate + recRuleVariables.date + 1);
|
|
@@ -671,7 +671,7 @@ function setNextValidDate(tempDate, ruleObject, monthInit, beginDate, interval)
|
|
|
671
671
|
if (ruleObject.month.length) {
|
|
672
672
|
monthInit++;
|
|
673
673
|
monthInit = monthInit % ruleObject.month.length;
|
|
674
|
-
calendarUtil.setMonth(tempDate, ruleObject.month[monthInit], 1);
|
|
674
|
+
calendarUtil.setMonth(tempDate, ruleObject.month[parseInt(monthInit.toString(), 10)], 1);
|
|
675
675
|
if (monthInit === 0) {
|
|
676
676
|
calendarUtil.addYears(tempDate, interval, ruleObject.month[0]);
|
|
677
677
|
}
|
|
@@ -716,7 +716,7 @@ function getMonthCollection(startDate, endDate, data, ruleObject) {
|
|
|
716
716
|
var isHavingNumber = expectedDays.map(function (item) { return HASNUMBER.test(item); });
|
|
717
717
|
if (isHavingNumber.indexOf(true) > -1) {
|
|
718
718
|
for (var j = 0; j <= expectedDays.length - 1; j++) {
|
|
719
|
-
var expectedDaysArray = expectedDays[j].match(SPLITNUMBERANDSTRING);
|
|
719
|
+
var expectedDaysArray = expectedDays[parseInt(j.toString(), 10)].match(SPLITNUMBERANDSTRING);
|
|
720
720
|
var position = parseInt(expectedDaysArray[0], 10);
|
|
721
721
|
tempDate = new Date(tempDate.getTime());
|
|
722
722
|
tempDate = calendarUtil.getMonthStartDate(tempDate);
|
|
@@ -777,8 +777,8 @@ function getMonthCollection(startDate, endDate, data, ruleObject) {
|
|
|
777
777
|
index = 0;
|
|
778
778
|
var datas = [];
|
|
779
779
|
for (var week = 0; week < monthCollection.length; week++) {
|
|
780
|
-
for (var row = 0; row < monthCollection[week].length; row++) {
|
|
781
|
-
datas.push(monthCollection[week][row]);
|
|
780
|
+
for (var row = 0; row < monthCollection[parseInt(week.toString(), 10)].length; row++) {
|
|
781
|
+
datas.push(monthCollection[parseInt(week.toString(), 10)][parseInt(row.toString(), 10)]);
|
|
782
782
|
}
|
|
783
783
|
}
|
|
784
784
|
monthCollection = [datas];
|
|
@@ -970,8 +970,8 @@ function processDateCollectionforByDayWithInteger(startDate, endDate, data, rule
|
|
|
970
970
|
while (calendarUtil.isSameYear(currentMonthDate, tempDate)) {
|
|
971
971
|
currentMonthDate = new Date(tempDate.getTime());
|
|
972
972
|
if (ruleObject.month.length === 0 ||
|
|
973
|
-
(ruleObject.month.length > 0 && ruleObject.month[i] === calendarUtil.getMonth(currentMonthDate))) {
|
|
974
|
-
var expectedDaysArray = expectedDays[j].match(SPLITNUMBERANDSTRING);
|
|
973
|
+
(ruleObject.month.length > 0 && ruleObject.month[parseInt(i.toString(), 10)] === calendarUtil.getMonth(currentMonthDate))) {
|
|
974
|
+
var expectedDaysArray = expectedDays[parseInt(j.toString(), 10)].match(SPLITNUMBERANDSTRING);
|
|
975
975
|
var position = parseInt(expectedDaysArray[0], 10);
|
|
976
976
|
currentDate = new Date(tempDate.getTime());
|
|
977
977
|
while (calendarUtil.isSameYear(currentDate, tempDate)
|
|
@@ -1090,8 +1090,8 @@ function insertDataCollection(dateCollection, state, startDate, endDate, data, r
|
|
|
1090
1090
|
function getDateCollectionforBySetPosNull(monthCollection) {
|
|
1091
1091
|
var datas = [];
|
|
1092
1092
|
for (var week = 0; week < monthCollection.length; week++) {
|
|
1093
|
-
for (var row = 0; row < monthCollection[week].length; row++) {
|
|
1094
|
-
datas.push(new Date(monthCollection[week][row]).getTime());
|
|
1093
|
+
for (var row = 0; row < monthCollection[parseInt(week.toString(), 10)].length; row++) {
|
|
1094
|
+
datas.push(new Date(monthCollection[parseInt(week.toString(), 10)][parseInt(row.toString(), 10)]).getTime());
|
|
1095
1095
|
}
|
|
1096
1096
|
}
|
|
1097
1097
|
monthCollection = datas.length > 0 ? [datas] : [];
|
|
@@ -1137,8 +1137,8 @@ function insertDateCollectionBasedonIndex(monthCollection, startDate, endDate, d
|
|
|
1137
1137
|
* @private
|
|
1138
1138
|
*/
|
|
1139
1139
|
function filterDateCollectionByIndex(monthCollection, index, datas) {
|
|
1140
|
-
for (var week = 0; week < monthCollection[index].length; week++) {
|
|
1141
|
-
datas.push(monthCollection[index][week]);
|
|
1140
|
+
for (var week = 0; week < monthCollection[parseInt(index.toString(), 10)].length; week++) {
|
|
1141
|
+
datas.push(monthCollection[parseInt(index.toString(), 10)][parseInt(week.toString(), 10)]);
|
|
1142
1142
|
}
|
|
1143
1143
|
return datas;
|
|
1144
1144
|
}
|
|
@@ -1182,7 +1182,7 @@ function weekCount(year, startDayOfWeek, monthCollection, week, ruleObject) {
|
|
|
1182
1182
|
var firstWeekDay = (firstOfMonth.getDay() - firstDayOfWeek + 7) % 7;
|
|
1183
1183
|
var used = firstWeekDay + numberOfDaysInMonth;
|
|
1184
1184
|
var count = Math.ceil(used / 7) - 1;
|
|
1185
|
-
var dayData = monthCollection[week][count];
|
|
1185
|
+
var dayData = monthCollection[parseInt(week.toString(), 10)][parseInt(count.toString(), 10)];
|
|
1186
1186
|
var chDate = new Date(dayData);
|
|
1187
1187
|
var state = validateRules(chDate, ruleObject);
|
|
1188
1188
|
return (state) ? count : count - 1;
|
|
@@ -1202,15 +1202,15 @@ function weekCount(year, startDayOfWeek, monthCollection, week, ruleObject) {
|
|
|
1202
1202
|
function insertDateCollectionBasedonBySetPos(monthCollection, state, startDate, endDate, data, ruleObject) {
|
|
1203
1203
|
if (monthCollection.length > 0) {
|
|
1204
1204
|
for (var week = 0; week < monthCollection.length; week++) {
|
|
1205
|
-
monthCollection[week].sort();
|
|
1205
|
+
monthCollection[parseInt(week.toString(), 10)].sort();
|
|
1206
1206
|
var expectedDays = ruleObject.day;
|
|
1207
1207
|
var isHavingNumber = expectedDays.map(function (item) { return HASNUMBER.test(item); });
|
|
1208
1208
|
var weekIndex = (ruleObject.freq === 'YEARLY' && (ruleObject.validRules.indexOf('BYMONTH') > -1) &&
|
|
1209
1209
|
!(isHavingNumber.indexOf(true) > -1)) ?
|
|
1210
1210
|
weekCount(new Date(monthCollection[0][0]).getFullYear(), 0, monthCollection, week, ruleObject)
|
|
1211
|
-
: (monthCollection[week].length + ruleObject.setPosition);
|
|
1211
|
+
: (monthCollection[parseInt(week.toString(), 10)].length + ruleObject.setPosition);
|
|
1212
1212
|
var index = ((ruleObject.setPosition < 1) ? weekIndex : ruleObject.setPosition - 1);
|
|
1213
|
-
var dayData = monthCollection[week][index];
|
|
1213
|
+
var dayData = monthCollection[parseInt(week.toString(), 10)][parseInt(index.toString(), 10)];
|
|
1214
1214
|
insertDateCollection(state, startDate, endDate, data, ruleObject, dayData);
|
|
1215
1215
|
}
|
|
1216
1216
|
}
|
|
@@ -1233,9 +1233,9 @@ function insertDatasIntoExistingCollection(monthCollection, state, startDate, en
|
|
|
1233
1233
|
index = !isNullOrUndefined(index) ? index :
|
|
1234
1234
|
((ruleObject.setPosition < 1)
|
|
1235
1235
|
? (monthCollection.length + ruleObject.setPosition) : ruleObject.setPosition - 1);
|
|
1236
|
-
monthCollection[index].sort();
|
|
1237
|
-
for (var week = 0; week < monthCollection[index].length; week++) {
|
|
1238
|
-
var dayData = monthCollection[index][week];
|
|
1236
|
+
monthCollection[parseInt(index.toString(), 10)].sort();
|
|
1237
|
+
for (var week = 0; week < monthCollection[parseInt(index.toString(), 10)].length; week++) {
|
|
1238
|
+
var dayData = monthCollection[parseInt(index.toString(), 10)][parseInt(week.toString(), 10)];
|
|
1239
1239
|
insertDateCollection(state, startDate, endDate, data, ruleObject, dayData);
|
|
1240
1240
|
}
|
|
1241
1241
|
}
|
|
@@ -1282,7 +1282,7 @@ function checkDayIndex(day, expectedDays) {
|
|
|
1282
1282
|
sortedExpectedDays.push(expectedDaysNumberSplit[0]);
|
|
1283
1283
|
}
|
|
1284
1284
|
});
|
|
1285
|
-
return (sortedExpectedDays.indexOf(DAYINDEX[day]) === -1);
|
|
1285
|
+
return (sortedExpectedDays.indexOf(DAYINDEX[parseInt(day.toString(), 10)]) === -1);
|
|
1286
1286
|
}
|
|
1287
1287
|
/**
|
|
1288
1288
|
* Internal method to get start date of week
|
|
@@ -1298,7 +1298,7 @@ function getStartDateForWeek(startDate, expectedDays) {
|
|
|
1298
1298
|
if (expectedDays.length > 0) {
|
|
1299
1299
|
var expectedDaysArr = [];
|
|
1300
1300
|
for (var i = 0; i <= expectedDays.length - 1; i++) {
|
|
1301
|
-
newstr = getDayString(expectedDays[i]);
|
|
1301
|
+
newstr = getDayString(expectedDays[parseInt(i.toString(), 10)]);
|
|
1302
1302
|
expectedDaysArr.push(newstr);
|
|
1303
1303
|
}
|
|
1304
1304
|
if (expectedDaysArr.indexOf(DAYINDEX[tempDate.getDay()]) === -1) {
|
|
@@ -1412,10 +1412,10 @@ function processWeekDays(expectedDays) {
|
|
|
1412
1412
|
while (temp % 7 !== dayIndex.indexOf(expectedDays[0])) {
|
|
1413
1413
|
temp++;
|
|
1414
1414
|
}
|
|
1415
|
-
dayCycle[element] = temp - startIndex;
|
|
1415
|
+
dayCycle["" + element] = temp - startIndex;
|
|
1416
1416
|
}
|
|
1417
1417
|
else {
|
|
1418
|
-
dayCycle[element] = dayIndex.indexOf(expectedDays[(index + 1)]) - dayIndex.indexOf(element);
|
|
1418
|
+
dayCycle["" + element] = dayIndex.indexOf(expectedDays[(index + 1)]) - dayIndex.indexOf(element);
|
|
1419
1419
|
}
|
|
1420
1420
|
});
|
|
1421
1421
|
return dayCycle;
|
|
@@ -671,7 +671,7 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
671
671
|
var self = this;
|
|
672
672
|
var dataSource = [];
|
|
673
673
|
monthpos.forEach(function (data) {
|
|
674
|
-
dataSource.push({ text: self.localeObj.getConstant(data), value: monthposValue[data] });
|
|
674
|
+
dataSource.push({ text: self.localeObj.getConstant(data), value: monthposValue["" + data] });
|
|
675
675
|
});
|
|
676
676
|
return dataSource;
|
|
677
677
|
};
|
|
@@ -691,7 +691,7 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
691
691
|
for (var _i = 0, weekday_1 = weekday; _i < weekday_1.length; _i++) {
|
|
692
692
|
var obj = weekday_1[_i];
|
|
693
693
|
var day = getValue(obj, cldrObj);
|
|
694
|
-
dayData.push({ text: format === 'narrow' ? day : capitalizeFirstWord(day, 'single'), value: valueData[obj] });
|
|
694
|
+
dayData.push({ text: format === 'narrow' ? day : capitalizeFirstWord(day, 'single'), value: valueData["" + obj] });
|
|
695
695
|
}
|
|
696
696
|
return dayData;
|
|
697
697
|
};
|
|
@@ -781,7 +781,7 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
781
781
|
var weekday = [RULESUNDAY, RULEMONDAY, RULETUESDAY, RULEWEDNESDAY, RULETHURSDAY, RULEFRIDAY, RULESATURDAY];
|
|
782
782
|
this.rotateArray(weekday, this.firstDayOfWeek);
|
|
783
783
|
for (var index = 0; index < elements.length; index++) {
|
|
784
|
-
ruleData += weekday[parseInt(elements[index].getAttribute('data-index'), 10)] + (index === (elements.length - 1) ? '' : COMMA);
|
|
784
|
+
ruleData += weekday[parseInt(elements[parseInt(index.toString(), 10)].getAttribute('data-index'), 10)] + (index === (elements.length - 1) ? '' : COMMA);
|
|
785
785
|
}
|
|
786
786
|
return ruleData + SEMICOLON;
|
|
787
787
|
};
|
|
@@ -811,7 +811,7 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
811
811
|
for (var _i = 0, _a = this.dayButtons; _i < _a.length; _i++) {
|
|
812
812
|
var obj = _a[_i];
|
|
813
813
|
var index = parseInt(obj.element.getAttribute('data-index'), 10);
|
|
814
|
-
if (keys.indexOf(weekday[index]) !== -1) {
|
|
814
|
+
if (keys.indexOf(weekday[parseInt(index.toString(), 10)]) !== -1) {
|
|
815
815
|
obj.setProperties({ isPrimary: true });
|
|
816
816
|
}
|
|
817
817
|
else {
|
|
@@ -829,7 +829,7 @@ var RecurrenceEditor = /** @class */ (function (_super) {
|
|
|
829
829
|
this.monthWeekPos.setProperties({ value: this.ruleObject.setPosition });
|
|
830
830
|
for (var _i = 0, _a = Object.keys(valueData); _i < _a.length; _i++) {
|
|
831
831
|
var key = _a[_i];
|
|
832
|
-
if (valueData[key] === this.ruleObject.day[0]) {
|
|
832
|
+
if (valueData["" + key] === this.ruleObject.day[0]) {
|
|
833
833
|
this.monthWeekDays.setProperties({ value: this.ruleObject.day[0] });
|
|
834
834
|
break;
|
|
835
835
|
}
|
|
@@ -140,8 +140,8 @@ var ActionBase = /** @class */ (function () {
|
|
|
140
140
|
var startTime = this.actionObj.start;
|
|
141
141
|
var endTime = this.actionObj.end;
|
|
142
142
|
if (multiData && multiData.length > 0) {
|
|
143
|
-
startTime = multiData[index][this.parent.eventFields.startTime];
|
|
144
|
-
endTime = multiData[index][this.parent.eventFields.endTime];
|
|
143
|
+
startTime = multiData[parseInt(index.toString(), 10)][this.parent.eventFields.startTime];
|
|
144
|
+
endTime = multiData[parseInt(index.toString(), 10)][this.parent.eventFields.endTime];
|
|
145
145
|
}
|
|
146
146
|
timeElement.innerHTML = this.parent.getTimeString(startTime) + ' - ' +
|
|
147
147
|
this.parent.getTimeString(endTime);
|
|
@@ -439,7 +439,7 @@ var ActionBase = /** @class */ (function () {
|
|
|
439
439
|
addClass([appointmentElement], cls.CLONE_ELEMENT_CLASS);
|
|
440
440
|
this.monthEvent.applyResourceColor(appointmentElement, event_1, 'backgroundColor', groupOrder);
|
|
441
441
|
setStyleAttribute(appointmentElement, { 'width': appWidth + 'px', 'border': '0px', 'pointer-events': 'none' });
|
|
442
|
-
var cellTd = workCells[day];
|
|
442
|
+
var cellTd = workCells[parseInt(day.toString(), 10)];
|
|
443
443
|
if (cellTd && isNullOrUndefined(this.parent.eventDragArea)) {
|
|
444
444
|
this.monthEvent.renderElement(cellTd, appointmentElement, true);
|
|
445
445
|
this.actionObj.cloneElement.push(appointmentElement);
|
|
@@ -74,10 +74,10 @@ var Crud = /** @class */ (function () {
|
|
|
74
74
|
['Agenda', 'MonthAgenda', 'Year', 'TimelineYear'].indexOf(this.parent.currentView) === -1) {
|
|
75
75
|
templateNames = [];
|
|
76
76
|
for (var i = 0, len = this.crudObj.sourceEvent.length; i < len; i++) {
|
|
77
|
-
templateNames.push('eventTemplate_' + this.crudObj.sourceEvent[i].groupIndex);
|
|
78
|
-
if (this.crudObj.targetEvent[i] && this.crudObj.sourceEvent[i].groupIndex !==
|
|
79
|
-
this.crudObj.targetEvent[i].groupIndex) {
|
|
80
|
-
templateNames.push('eventTemplate_' + this.crudObj.targetEvent[i].groupIndex);
|
|
77
|
+
templateNames.push('eventTemplate_' + this.crudObj.sourceEvent[parseInt(i.toString(), 10)].groupIndex);
|
|
78
|
+
if (this.crudObj.targetEvent[parseInt(i.toString(), 10)] && this.crudObj.sourceEvent[parseInt(i.toString(), 10)].groupIndex !==
|
|
79
|
+
this.crudObj.targetEvent[parseInt(i.toString(), 10)].groupIndex) {
|
|
80
|
+
templateNames.push('eventTemplate_' + this.crudObj.targetEvent[parseInt(i.toString(), 10)].groupIndex);
|
|
81
81
|
}
|
|
82
82
|
}
|
|
83
83
|
}
|
|
@@ -118,7 +118,7 @@ var Crud = /** @class */ (function () {
|
|
|
118
118
|
var groupIndex = this_1.parent.eventBase.getGroupIndexFromEvent(data);
|
|
119
119
|
if (groupIndex > -1 && this_1.parent.crudModule.crudObj.sourceEvent.filter(function (tdData) { return tdData.groupIndex === groupIndex; }).length === 0
|
|
120
120
|
&& this_1.crudObj.isCrudAction) {
|
|
121
|
-
this_1.crudObj.sourceEvent.push(this_1.parent.resourceBase.lastResourceLevel[groupIndex]);
|
|
121
|
+
this_1.crudObj.sourceEvent.push(this_1.parent.resourceBase.lastResourceLevel[parseInt(groupIndex.toString(), 10)]);
|
|
122
122
|
}
|
|
123
123
|
};
|
|
124
124
|
var this_1 = this;
|
|
@@ -336,8 +336,8 @@ var Crud = /** @class */ (function () {
|
|
|
336
336
|
var editParams = { addedRecords: [], changedRecords: [], deletedRecords: [] };
|
|
337
337
|
var occurrenceEvents = (occurrenceData instanceof Array ? occurrenceData : [occurrenceData]);
|
|
338
338
|
var _loop_2 = function (a, count) {
|
|
339
|
-
var childEvent = occurrenceArgs.changedRecords[a];
|
|
340
|
-
var parentEvent = occurrenceEvents[a].parent;
|
|
339
|
+
var childEvent = occurrenceArgs.changedRecords[parseInt(a.toString(), 10)];
|
|
340
|
+
var parentEvent = occurrenceEvents[parseInt(a.toString(), 10)].parent;
|
|
341
341
|
var parentException = parentEvent[fields.recurrenceException];
|
|
342
342
|
var editedData = void 0;
|
|
343
343
|
var exceptionDate = void 0;
|
|
@@ -408,8 +408,8 @@ var Crud = /** @class */ (function () {
|
|
|
408
408
|
var editParams = { addedRecords: [], changedRecords: [], deletedRecords: [] };
|
|
409
409
|
var followEvents = followData instanceof Array ? followData : [followData];
|
|
410
410
|
var _loop_3 = function (a, count) {
|
|
411
|
-
var childEvent = followArgs.changedRecords[a];
|
|
412
|
-
var parentEvent = followEvents[a].parent;
|
|
411
|
+
var childEvent = followArgs.changedRecords[parseInt(a.toString(), 10)];
|
|
412
|
+
var parentEvent = followEvents[parseInt(a.toString(), 10)].parent;
|
|
413
413
|
var followData_1 = _this.parent.eventBase.getEventCollections(parentEvent, childEvent);
|
|
414
414
|
var isSpanned = void 0;
|
|
415
415
|
switch (action) {
|
|
@@ -485,8 +485,8 @@ var Crud = /** @class */ (function () {
|
|
|
485
485
|
var editParams = { addedRecords: [], changedRecords: [], deletedRecords: [] };
|
|
486
486
|
var seriesEvents = seriesData instanceof Array ? seriesData : [seriesData];
|
|
487
487
|
var _loop_4 = function (a, count) {
|
|
488
|
-
var childEvent = seriesArgs.changedRecords[a];
|
|
489
|
-
var parentEvent = seriesEvents[a];
|
|
488
|
+
var childEvent = seriesArgs.changedRecords[parseInt(a.toString(), 10)];
|
|
489
|
+
var parentEvent = seriesEvents[parseInt(a.toString(), 10)];
|
|
490
490
|
var eventCollections = _this.parent.eventBase.getEventCollections(parentEvent);
|
|
491
491
|
var deletedEvents = eventCollections.follow.concat(eventCollections.occurrence);
|
|
492
492
|
switch (action) {
|
|
@@ -551,13 +551,13 @@ var Crud = /** @class */ (function () {
|
|
|
551
551
|
var fields_3 = _this.parent.eventFields;
|
|
552
552
|
var editParams = { addedRecords: [], changedRecords: [], deletedRecords: [] };
|
|
553
553
|
var _loop_5 = function (a, count) {
|
|
554
|
-
var isDelete = isNullOrUndefined(deleteArgs.deletedRecords[a][_this.parent.eventFields.recurrenceRule]);
|
|
554
|
+
var isDelete = isNullOrUndefined(deleteArgs.deletedRecords[parseInt(a.toString(), 10)][_this.parent.eventFields.recurrenceRule]);
|
|
555
555
|
if (!isDelete) {
|
|
556
|
-
var parentEvent_1 = deleteData[a].parent;
|
|
556
|
+
var parentEvent_1 = deleteData[parseInt(a.toString(), 10)].parent;
|
|
557
557
|
var isEdited = editParams.changedRecords.filter(function (obj) {
|
|
558
558
|
return obj[fields_3.id] === parentEvent_1[fields_3.id];
|
|
559
559
|
});
|
|
560
|
-
var editedDate = deleteArgs.deletedRecords[a][fields_3.startTime];
|
|
560
|
+
var editedDate = deleteArgs.deletedRecords[parseInt(a.toString(), 10)][fields_3.startTime];
|
|
561
561
|
if (isEdited.length > 0) {
|
|
562
562
|
var editedData = isEdited[0];
|
|
563
563
|
editedData[fields_3.recurrenceException] =
|
|
@@ -570,10 +570,10 @@ var Crud = /** @class */ (function () {
|
|
|
570
570
|
if (isEdited.length === 0) {
|
|
571
571
|
editParams.changedRecords.push(_this.parent.eventBase.processTimezone(parentEvent_1, true));
|
|
572
572
|
}
|
|
573
|
-
isDelete = deleteArgs.deletedRecords[a][fields_3.id] !== parentEvent_1[fields_3.id];
|
|
573
|
+
isDelete = deleteArgs.deletedRecords[parseInt(a.toString(), 10)][fields_3.id] !== parentEvent_1[fields_3.id];
|
|
574
574
|
}
|
|
575
575
|
if (isDelete) {
|
|
576
|
-
editParams.deletedRecords.push(deleteArgs.deletedRecords[a]);
|
|
576
|
+
editParams.deletedRecords.push(deleteArgs.deletedRecords[parseInt(a.toString(), 10)]);
|
|
577
577
|
}
|
|
578
578
|
};
|
|
579
579
|
for (var a = 0, count = deleteArgs.deletedRecords.length; a < count; a++) {
|
|
@@ -395,7 +395,8 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
395
395
|
_this.parent.crudModule.crudObj.sourceEvent =
|
|
396
396
|
[_this.parent.resourceBase.lastResourceLevel[parseInt(dragArgs.element.getAttribute('data-group-index'), 10)]];
|
|
397
397
|
var currentGroupIndex = parseInt(dragArgs.target.getAttribute('data-group-index'), 10) || _this.actionObj.groupIndex;
|
|
398
|
-
_this.parent.crudModule.crudObj.targetEvent =
|
|
398
|
+
_this.parent.crudModule.crudObj.targetEvent =
|
|
399
|
+
[_this.parent.resourceBase.lastResourceLevel[parseInt(currentGroupIndex.toString(), 10)]];
|
|
399
400
|
}
|
|
400
401
|
_this.saveChangedData(dragEventArgs, _this.isMultiSelect);
|
|
401
402
|
});
|
|
@@ -590,7 +591,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
590
591
|
}
|
|
591
592
|
else {
|
|
592
593
|
var trCollections = [].slice.call(this.parent.getContentTable().querySelectorAll('tr'));
|
|
593
|
-
tr = trCollections[rowIndex];
|
|
594
|
+
tr = trCollections[parseInt(rowIndex.toString(), 10)];
|
|
594
595
|
}
|
|
595
596
|
var index;
|
|
596
597
|
if (closest(this.actionObj.target, 'td').classList.contains(cls.WORK_CELLS_CLASS) ||
|
|
@@ -602,7 +603,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
602
603
|
if (isNullOrUndefined(tr)) {
|
|
603
604
|
return;
|
|
604
605
|
}
|
|
605
|
-
var td = tr.children[colIndex];
|
|
606
|
+
var td = tr.children[parseInt(colIndex.toString(), 10)];
|
|
606
607
|
if (this.parent.activeViewOptions.group.resources.length > 0 && !this.parent.uiStateValues.isGroupAdaptive) {
|
|
607
608
|
this.actionObj.groupIndex = parseInt(td.getAttribute('data-group-index'), 10);
|
|
608
609
|
}
|
|
@@ -667,16 +668,17 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
667
668
|
}
|
|
668
669
|
var startTimeDiff = event[this.parent.eventFields.startTime].getTime() - this.startTime;
|
|
669
670
|
for (var index_2 = 0; index_2 < this.multiData.length; index_2++) {
|
|
670
|
-
this.updatedData[index_2
|
|
671
|
-
|
|
671
|
+
this.updatedData[parseInt(index_2.toString(), 10)] =
|
|
672
|
+
this.updateMultipleData(this.multiData[parseInt(index_2.toString(), 10)], startTimeDiff);
|
|
673
|
+
var dayIndex = this.getDayIndex(this.updatedData[parseInt(index_2.toString(), 10)]);
|
|
672
674
|
if (dayIndex >= 0) {
|
|
673
|
-
var wrapper = this.getEventWrapper(dayIndex, this.updatedData[index_2][this.parent.eventFields.isAllDay]);
|
|
674
|
-
this.appendCloneElement(wrapper, this.actionObj.cloneElement[index_2]);
|
|
675
|
-
this.updateEventHeight(this.updatedData[index_2], index_2, dayIndex);
|
|
675
|
+
var wrapper = this.getEventWrapper(dayIndex, this.updatedData[parseInt(index_2.toString(), 10)][this.parent.eventFields.isAllDay]);
|
|
676
|
+
this.appendCloneElement(wrapper, this.actionObj.cloneElement[parseInt(index_2.toString(), 10)]);
|
|
677
|
+
this.updateEventHeight(this.updatedData[parseInt(index_2.toString(), 10)], index_2, dayIndex);
|
|
676
678
|
}
|
|
677
679
|
else {
|
|
678
|
-
if (!isNullOrUndefined(this.actionObj.cloneElement[index_2].parentNode)) {
|
|
679
|
-
remove(this.actionObj.cloneElement[index_2]);
|
|
680
|
+
if (!isNullOrUndefined(this.actionObj.cloneElement[parseInt(index_2.toString(), 10)].parentNode)) {
|
|
681
|
+
remove(this.actionObj.cloneElement[parseInt(index_2.toString(), 10)]);
|
|
680
682
|
}
|
|
681
683
|
}
|
|
682
684
|
}
|
|
@@ -704,7 +706,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
704
706
|
}
|
|
705
707
|
var index = eventData.length - 1;
|
|
706
708
|
eventData[0][eventFields.startTime] = startTime;
|
|
707
|
-
eventData[index][eventFields.endTime] = endTime;
|
|
709
|
+
eventData[parseInt(index.toString(), 10)][eventFields.endTime] = endTime;
|
|
708
710
|
}
|
|
709
711
|
else {
|
|
710
712
|
eventData.push(event);
|
|
@@ -761,8 +763,8 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
761
763
|
var datesCount = this.verticalEvent.getStartCount();
|
|
762
764
|
if (!this.parent.uiStateValues.isGroupAdaptive) {
|
|
763
765
|
for (var i = 0; i < this.actionObj.groupIndex; i++) {
|
|
764
|
-
if (this.verticalEvent.dateRender[i]) {
|
|
765
|
-
datesCount = datesCount + this.verticalEvent.dateRender[i].length;
|
|
766
|
+
if (this.verticalEvent.dateRender[parseInt(i.toString(), 10)]) {
|
|
767
|
+
datesCount = datesCount + this.verticalEvent.dateRender[parseInt(i.toString(), 10)].length;
|
|
766
768
|
}
|
|
767
769
|
}
|
|
768
770
|
}
|
|
@@ -773,7 +775,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
773
775
|
var dynamicIndex = -1;
|
|
774
776
|
var dayIndex = !this.parent.activeViewOptions.group.byDate ?
|
|
775
777
|
isNullOrUndefined(index) ? this.actionObj.index - datesCount : colIndex - datesCount
|
|
776
|
-
: this.parent.getIndexOfDate(this.verticalEvent.dateRender[indexGroup], util.resetTime(
|
|
778
|
+
: this.parent.getIndexOfDate(this.verticalEvent.dateRender[parseInt(indexGroup.toString(), 10)], util.resetTime(
|
|
777
779
|
// eslint-disable-next-line max-len
|
|
778
780
|
this.parent.getDateFromElement(isNullOrUndefined(index) ? this.actionObj.target : this.targetTd)));
|
|
779
781
|
var splitEvents = this.splitEvent(event);
|
|
@@ -781,7 +783,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
781
783
|
this.parent.eventSettings.spannedEventPlacement !== 'TimeSlot' ? [event] : splitEvents;
|
|
782
784
|
for (var i = 0; i < events_1.length; i++) {
|
|
783
785
|
if (i > 0) {
|
|
784
|
-
var filterQuery = ".e-day-wrapper[data-date=\"" + util.resetTime(events_1[i][this.parent.eventFields.startTime]).getTime() + "\"]";
|
|
786
|
+
var filterQuery = ".e-day-wrapper[data-date=\"" + util.resetTime(events_1[parseInt(i.toString(), 10)][this.parent.eventFields.startTime]).getTime() + "\"]";
|
|
785
787
|
if (this.parent.activeViewOptions.group.resources.length > 0) {
|
|
786
788
|
filterQuery = filterQuery.concat('[data-group-index = "' + this.actionObj.groupIndex + '"]');
|
|
787
789
|
}
|
|
@@ -795,7 +797,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
795
797
|
}
|
|
796
798
|
}
|
|
797
799
|
if (dayIndex >= 0) {
|
|
798
|
-
var record = this.verticalEvent.isSpannedEvent(events_1[i], dayIndex, indexGroup);
|
|
800
|
+
var record = this.verticalEvent.isSpannedEvent(events_1[parseInt(i.toString(), 10)], dayIndex, indexGroup);
|
|
799
801
|
var eStart = record[this.verticalEvent.fields.startTime];
|
|
800
802
|
var eEnd = record[this.verticalEvent.fields.endTime];
|
|
801
803
|
var appHeight = this.parent.activeViewOptions.timeScale.enable ? this.verticalEvent.getHeight(eStart, eEnd) :
|
|
@@ -823,12 +825,12 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
823
825
|
appWidth = (allDayDifference * this.actionObj.cellWidth);
|
|
824
826
|
}
|
|
825
827
|
}
|
|
826
|
-
if (this.actionObj.cloneElement[index]) {
|
|
828
|
+
if (this.actionObj.cloneElement[parseInt(index.toString(), 10)]) {
|
|
827
829
|
if (i === 0) {
|
|
828
|
-
this.actionObj.cloneElement[index].style.top = formatUnit(topValue);
|
|
829
|
-
this.actionObj.cloneElement[index].style.height = formatUnit(appHeight);
|
|
830
|
-
this.actionObj.cloneElement[index].style.width = formatUnit(appWidth);
|
|
831
|
-
this.actionObj.cloneElement[index].style.left = formatUnit(0);
|
|
830
|
+
this.actionObj.cloneElement[parseInt(index.toString(), 10)].style.top = formatUnit(topValue);
|
|
831
|
+
this.actionObj.cloneElement[parseInt(index.toString(), 10)].style.height = formatUnit(appHeight);
|
|
832
|
+
this.actionObj.cloneElement[parseInt(index.toString(), 10)].style.width = formatUnit(appWidth);
|
|
833
|
+
this.actionObj.cloneElement[parseInt(index.toString(), 10)].style.left = formatUnit(0);
|
|
832
834
|
}
|
|
833
835
|
else {
|
|
834
836
|
this.renderSpannedEvents(record, dynamicIndex, topValue, appHeight);
|
|
@@ -853,7 +855,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
853
855
|
'border': '0px'
|
|
854
856
|
});
|
|
855
857
|
var appointmentWrap = [].slice.call(this.parent.element.querySelectorAll('.' + cls.APPOINTMENT_WRAPPER_CLASS));
|
|
856
|
-
appointmentWrap[index].appendChild(appointmentElement);
|
|
858
|
+
appointmentWrap[parseInt(index.toString(), 10)].appendChild(appointmentElement);
|
|
857
859
|
}
|
|
858
860
|
};
|
|
859
861
|
DragAndDrop.prototype.getRenderedDates = function () {
|
|
@@ -971,12 +973,13 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
971
973
|
startTimeDiff += startTime.getMonth();
|
|
972
974
|
}
|
|
973
975
|
for (var index = 0; index < this.multiData.length; index++) {
|
|
974
|
-
this.updatedData[index
|
|
976
|
+
this.updatedData[parseInt(index.toString(), 10)] =
|
|
977
|
+
this.updateMultipleVerticalDate(this.multiData[parseInt(index.toString(), 10)], startTimeDiff);
|
|
975
978
|
if (this.parent.currentView === 'TimelineYear') {
|
|
976
|
-
this.dynamicYearlyEventsRendering(this.updatedData[index]);
|
|
979
|
+
this.dynamicYearlyEventsRendering(this.updatedData[parseInt(index.toString(), 10)]);
|
|
977
980
|
}
|
|
978
981
|
else {
|
|
979
|
-
this.dynamicEventsRendering(this.updatedData[index]);
|
|
982
|
+
this.dynamicEventsRendering(this.updatedData[parseInt(index.toString(), 10)]);
|
|
980
983
|
}
|
|
981
984
|
}
|
|
982
985
|
}
|
|
@@ -1039,8 +1042,8 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
1039
1042
|
var tr = this.parent.getContentTable().querySelector('tr');
|
|
1040
1043
|
var index = this.getCursorCurrentIndex(colIndex, cloneIndex, tr);
|
|
1041
1044
|
index = index < 0 ? 0 : index;
|
|
1042
|
-
var eventStart = this.isHeaderRows ? new Date(this.timelineEventModule.dateRender[index].getTime()) :
|
|
1043
|
-
this.parent.getDateFromElement(tr.children[index]);
|
|
1045
|
+
var eventStart = this.isHeaderRows ? new Date(this.timelineEventModule.dateRender[parseInt(index.toString(), 10)].getTime()) :
|
|
1046
|
+
this.parent.getDateFromElement(tr.children[parseInt(index.toString(), 10)]);
|
|
1044
1047
|
if (this.isStepDragging) {
|
|
1045
1048
|
var widthDiff = this.getWidthDiff(tr, index);
|
|
1046
1049
|
if (widthDiff !== 0) {
|
|
@@ -1091,12 +1094,13 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
1091
1094
|
if (this.multiData.length > 0) {
|
|
1092
1095
|
var startTimeDiff = eventsData[0][this.parent.eventFields.startTime].getTime() - this.startTime;
|
|
1093
1096
|
for (var i = 0; i < this.multiData.length; i++) {
|
|
1094
|
-
this.updatedData[i
|
|
1097
|
+
this.updatedData[parseInt(i.toString(), 10)] =
|
|
1098
|
+
this.updateMultipleData(this.multiData[parseInt(i.toString(), 10)], startTimeDiff);
|
|
1095
1099
|
}
|
|
1096
1100
|
eventsData = this.updatedData;
|
|
1097
1101
|
}
|
|
1098
1102
|
for (var dataIndex = 0; dataIndex < eventsData.length; dataIndex++) {
|
|
1099
|
-
var events_2 = this.timelineEventModule.splitEvent(eventsData[dataIndex], this.timelineEventModule.dateRender);
|
|
1103
|
+
var events_2 = this.timelineEventModule.splitEvent(eventsData[parseInt(dataIndex.toString(), 10)], this.timelineEventModule.dateRender);
|
|
1100
1104
|
var eventData = events_2[0].data;
|
|
1101
1105
|
var startTime = this.timelineEventModule.getStartTime(events_2[0], eventData);
|
|
1102
1106
|
var endTime = this.timelineEventModule.getEndTime(events_2[0], eventData);
|
|
@@ -1106,7 +1110,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
1106
1110
|
var day = this.parent.getIndexOfDate(this.timelineEventModule.dateRender, util.resetTime(new Date(startTime.getTime())));
|
|
1107
1111
|
day = day < 0 ? 0 : day;
|
|
1108
1112
|
var left = this.timelineEventModule.getPosition(startTime, endTime, eventObj[this.parent.eventFields.isAllDay], day);
|
|
1109
|
-
var cloneElement = this.multiData.length > 0 ? this.actionObj.cloneElement[dataIndex] : this.actionObj.clone;
|
|
1113
|
+
var cloneElement = this.multiData.length > 0 ? this.actionObj.cloneElement[parseInt(dataIndex.toString(), 10)] : this.actionObj.clone;
|
|
1110
1114
|
if (this.parent.enableRtl) {
|
|
1111
1115
|
cloneElement.style.right = formatUnit(left);
|
|
1112
1116
|
}
|
|
@@ -1166,7 +1170,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
1166
1170
|
DragAndDrop.prototype.getWidthDiff = function (tr, index) {
|
|
1167
1171
|
var pages = this.scrollArgs.element.getBoundingClientRect();
|
|
1168
1172
|
if (pages.left <= this.actionObj.pageX && pages.right >= this.actionObj.pageX) {
|
|
1169
|
-
var targetLeft = tr.children[index].offsetLeft;
|
|
1173
|
+
var targetLeft = tr.children[parseInt(index.toString(), 10)].offsetLeft;
|
|
1170
1174
|
var pageX = this.actionObj.pageX - pages.left;
|
|
1171
1175
|
if (this.parent.enableRtl) {
|
|
1172
1176
|
return (targetLeft + this.actionObj.cellWidth) - (this.scrollArgs.element.scrollLeft + pageX);
|
|
@@ -1236,7 +1240,7 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
1236
1240
|
var td = closest(this.actionObj.target, 'td');
|
|
1237
1241
|
this.actionObj.groupIndex = (td && !isNaN(parseInt(td.getAttribute('data-group-index'), 10)))
|
|
1238
1242
|
? parseInt(td.getAttribute('data-group-index'), 10) : this.actionObj.groupIndex;
|
|
1239
|
-
var top = trCollection[rowIndex].getBoundingClientRect().height * rowIndex;
|
|
1243
|
+
var top = trCollection[parseInt(rowIndex.toString(), 10)].getBoundingClientRect().height * rowIndex;
|
|
1240
1244
|
if (this.parent.rowAutoHeight) {
|
|
1241
1245
|
var cursorElement = this.getCursorElement(e);
|
|
1242
1246
|
if (cursorElement) {
|