@syncfusion/ej2-schedule 20.1.59 → 20.2.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/CHANGELOG.md +35 -0
- 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 +250 -68
- package/dist/es6/ej2-schedule.es2015.js.map +1 -1
- package/dist/es6/ej2-schedule.es5.js +254 -67
- 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/helpers/e2e/index.js +9 -7
- package/helpers/e2e/recurrence-editor.js +41 -25
- package/helpers/e2e/schedule.js +44 -28
- package/package.json +15 -15
- package/src/recurrence-editor/recurrence-editor.js +4 -1
- package/src/schedule/actions/action-base.d.ts +1 -0
- package/src/schedule/actions/action-base.js +3 -2
- package/src/schedule/actions/crud.js +9 -7
- package/src/schedule/actions/drag.js +1 -1
- package/src/schedule/base/interface.d.ts +6 -0
- package/src/schedule/base/schedule.d.ts +8 -0
- package/src/schedule/base/schedule.js +66 -0
- package/src/schedule/event-renderer/agenda-base.js +6 -6
- package/src/schedule/event-renderer/event-base.d.ts +2 -0
- package/src/schedule/event-renderer/event-base.js +23 -4
- package/src/schedule/event-renderer/month.js +3 -6
- package/src/schedule/event-renderer/vertical-view.js +3 -3
- package/src/schedule/event-renderer/year.js +2 -2
- package/src/schedule/exports/calendar-export.js +1 -1
- package/src/schedule/exports/calendar-import.js +32 -18
- package/src/schedule/exports/excel-export.js +8 -4
- package/src/schedule/popups/event-window.js +3 -1
- package/src/schedule/popups/quick-popups.js +5 -4
- package/src/schedule/renderer/agenda.js +2 -2
- package/src/schedule/renderer/timeline-month.d.ts +1 -0
- package/src/schedule/renderer/timeline-month.js +9 -0
- package/src/schedule/renderer/timeline-view.d.ts +1 -0
- package/src/schedule/renderer/timeline-view.js +14 -0
- package/src/schedule/renderer/timeline-year.js +3 -0
- package/src/schedule/renderer/vertical-view.d.ts +2 -0
- package/src/schedule/renderer/vertical-view.js +37 -5
- package/src/schedule/renderer/view-base.d.ts +1 -0
- package/src/schedule/renderer/view-base.js +19 -0
- package/src/schedule/renderer/year.js +2 -1
- package/styles/bootstrap-dark.css +6 -5
- package/styles/bootstrap.css +6 -5
- package/styles/bootstrap4.css +6 -5
- package/styles/bootstrap5-dark.css +5 -3
- package/styles/bootstrap5.css +6 -5
- package/styles/fabric-dark.css +6 -5
- package/styles/fabric.css +6 -5
- package/styles/fluent-dark.css +20 -18
- package/styles/fluent.css +8 -7
- package/styles/highcontrast-light.css +6 -5
- package/styles/highcontrast.css +6 -5
- package/styles/material-dark.css +6 -5
- package/styles/material.css +6 -5
- package/styles/recurrence-editor/_fusionnew-definition.scss +15 -0
- package/styles/recurrence-editor/_material3-definition.scss +15 -0
- package/styles/schedule/_fluent-definition.scss +1 -1
- package/styles/schedule/_fusionnew-definition.scss +224 -0
- package/styles/schedule/_layout.scss +6 -2
- package/styles/schedule/_material3-definition.scss +224 -0
- package/styles/schedule/bootstrap-dark.css +6 -5
- package/styles/schedule/bootstrap.css +6 -5
- package/styles/schedule/bootstrap4.css +6 -5
- package/styles/schedule/bootstrap5-dark.css +5 -3
- package/styles/schedule/bootstrap5.css +6 -5
- package/styles/schedule/fabric-dark.css +6 -5
- package/styles/schedule/fabric.css +6 -5
- package/styles/schedule/fluent-dark.css +20 -18
- package/styles/schedule/fluent.css +8 -7
- package/styles/schedule/highcontrast-light.css +6 -5
- package/styles/schedule/highcontrast.css +6 -5
- package/styles/schedule/icons/_fusionnew.scss +232 -0
- package/styles/schedule/icons/_material3.scss +232 -0
- package/styles/schedule/material-dark.css +6 -5
- package/styles/schedule/material.css +6 -5
- package/styles/schedule/tailwind-dark.css +5 -3
- package/styles/schedule/tailwind.css +6 -5
- package/styles/tailwind-dark.css +5 -3
- package/styles/tailwind.css +6 -5
|
@@ -5666,7 +5666,7 @@ var EventBase = /** @__PURE__ @class */ (function () {
|
|
|
5666
5666
|
var selectedAppointments = this.getSelectedAppointments();
|
|
5667
5667
|
for (var _i = 0, selectedAppointments_1 = selectedAppointments; _i < selectedAppointments_1.length; _i++) {
|
|
5668
5668
|
var appointment = selectedAppointments_1[_i];
|
|
5669
|
-
appointment.setAttribute('aria-
|
|
5669
|
+
appointment.setAttribute('aria-pressed', 'false');
|
|
5670
5670
|
}
|
|
5671
5671
|
removeClass(selectedAppointments, APPOINTMENT_BORDER);
|
|
5672
5672
|
if (this.parent.currentView === 'Agenda' || this.parent.currentView === 'MonthAgenda') {
|
|
@@ -5676,7 +5676,7 @@ var EventBase = /** @__PURE__ @class */ (function () {
|
|
|
5676
5676
|
EventBase.prototype.addSelectedAppointments = function (cells) {
|
|
5677
5677
|
for (var _i = 0, cells_1 = cells; _i < cells_1.length; _i++) {
|
|
5678
5678
|
var cell = cells_1[_i];
|
|
5679
|
-
cell.setAttribute('aria-
|
|
5679
|
+
cell.setAttribute('aria-pressed', 'true');
|
|
5680
5680
|
}
|
|
5681
5681
|
if (this.parent.currentView !== 'MonthAgenda') {
|
|
5682
5682
|
this.parent.removeSelectedClass();
|
|
@@ -5804,6 +5804,7 @@ var EventBase = /** @__PURE__ @class */ (function () {
|
|
|
5804
5804
|
}
|
|
5805
5805
|
else if (!closest(element, '.' + POPUP_OPEN)) {
|
|
5806
5806
|
this.removeSelectedAppointmentClass();
|
|
5807
|
+
this.parent.selectedElements = [];
|
|
5807
5808
|
}
|
|
5808
5809
|
};
|
|
5809
5810
|
EventBase.prototype.wireAppointmentEvents = function (element, event, isPreventCrud) {
|
|
@@ -5909,6 +5910,7 @@ var EventBase = /** @__PURE__ @class */ (function () {
|
|
|
5909
5910
|
this.parent.trigger(eventClick, args, function (eventClickArgs) {
|
|
5910
5911
|
if (eventClickArgs.cancel) {
|
|
5911
5912
|
_this.removeSelectedAppointmentClass();
|
|
5913
|
+
_this.parent.selectedElements = [];
|
|
5912
5914
|
if (_this.parent.quickPopup) {
|
|
5913
5915
|
_this.parent.quickPopup.quickPopupHide();
|
|
5914
5916
|
}
|
|
@@ -5940,6 +5942,7 @@ var EventBase = /** @__PURE__ @class */ (function () {
|
|
|
5940
5942
|
this.activeEventData(e, true);
|
|
5941
5943
|
}
|
|
5942
5944
|
this.removeSelectedAppointmentClass();
|
|
5945
|
+
this.parent.selectedElements = [];
|
|
5943
5946
|
if (this.parent.activeEventData.element.classList.contains(INLINE_APPOINTMENT_CLASS) ||
|
|
5944
5947
|
this.parent.activeEventData.element.querySelector('.' + INLINE_SUBJECT_CLASS)) {
|
|
5945
5948
|
return;
|
|
@@ -6021,7 +6024,7 @@ var EventBase = /** @__PURE__ @class */ (function () {
|
|
|
6021
6024
|
var exception = event[this.parent.eventFields.recurrenceException];
|
|
6022
6025
|
var maxCount;
|
|
6023
6026
|
if (this.parent.currentView !== 'Agenda' && isMaxCount) {
|
|
6024
|
-
maxCount = getDateCount(
|
|
6027
|
+
maxCount = getDateCount(viewDate, this.parent.activeView.endDate()) + 1;
|
|
6025
6028
|
}
|
|
6026
6029
|
var newTimezone = this.parent.timezone || this.parent.tzModule.getLocalTimezoneName();
|
|
6027
6030
|
var firstDay = this.parent.activeViewOptions.firstDayOfWeek;
|
|
@@ -6044,6 +6047,7 @@ var EventBase = /** @__PURE__ @class */ (function () {
|
|
|
6044
6047
|
for (var _i = 0, dates_1 = dates; _i < dates_1.length; _i++) {
|
|
6045
6048
|
var date = dates_1[_i];
|
|
6046
6049
|
var clonedObject = extend({}, event, null, true);
|
|
6050
|
+
date = this.getDSTAdjustedTime(date, clonedObject);
|
|
6047
6051
|
clonedObject[this.parent.eventFields.startTime] = new Date(date);
|
|
6048
6052
|
clonedObject[this.parent.eventFields.endTime] = new Date(new Date(date).setMilliseconds(duration));
|
|
6049
6053
|
clonedObject[this.parent.eventFields.recurrenceID] = clonedObject[this.parent.eventFields.id];
|
|
@@ -6054,6 +6058,21 @@ var EventBase = /** @__PURE__ @class */ (function () {
|
|
|
6054
6058
|
}
|
|
6055
6059
|
return occurrenceCollection;
|
|
6056
6060
|
};
|
|
6061
|
+
EventBase.prototype.getDSTAdjustedTime = function (date, event) {
|
|
6062
|
+
var occurDate = date;
|
|
6063
|
+
if (this.parent.timezone &&
|
|
6064
|
+
(event[this.parent.eventFields.startTimezone] || event[this.parent.eventFields.endTimezone])) {
|
|
6065
|
+
var eventOffset = this.getDSTDiff(event[this.parent.eventFields.startTime], new Date(date), event[this.parent.eventFields.startTimezone]);
|
|
6066
|
+
var schOffset = this.getDSTDiff(event[this.parent.eventFields.startTime], new Date(date), this.parent.timezone);
|
|
6067
|
+
occurDate = (new Date(date).getTime() - (eventOffset - schOffset) * 60000);
|
|
6068
|
+
}
|
|
6069
|
+
return occurDate;
|
|
6070
|
+
};
|
|
6071
|
+
EventBase.prototype.getDSTDiff = function (startDate, occurDate, timezone) {
|
|
6072
|
+
var startOffset = this.parent.tzModule.offset(new Date(startDate), timezone);
|
|
6073
|
+
var occurOffset = this.parent.tzModule.offset(new Date(occurDate), timezone);
|
|
6074
|
+
return startOffset - occurOffset;
|
|
6075
|
+
};
|
|
6057
6076
|
EventBase.prototype.getParentEvent = function (eventObj, isParent) {
|
|
6058
6077
|
if (isParent === void 0) { isParent = false; }
|
|
6059
6078
|
var parentEvent;
|
|
@@ -6220,7 +6239,7 @@ var EventBase = /** @__PURE__ @class */ (function () {
|
|
|
6220
6239
|
className: BLOCK_APPOINTMENT_CLASS,
|
|
6221
6240
|
attrs: {
|
|
6222
6241
|
'data-id': 'Appointment_' + record[this.parent.eventFields.id],
|
|
6223
|
-
'aria-
|
|
6242
|
+
'aria-disabled': 'true', 'aria-pressed': 'false'
|
|
6224
6243
|
}
|
|
6225
6244
|
});
|
|
6226
6245
|
var templateElement;
|
|
@@ -6676,8 +6695,8 @@ var VerticalEvent = /** @__PURE__ @class */ (function (_super) {
|
|
|
6676
6695
|
'data-guid': record.Guid,
|
|
6677
6696
|
'role': 'button',
|
|
6678
6697
|
'tabindex': '0',
|
|
6679
|
-
'aria-
|
|
6680
|
-
'aria-
|
|
6698
|
+
'aria-disabled': this.parent.eventBase.getReadonlyAttribute(record),
|
|
6699
|
+
'aria-pressed': 'false',
|
|
6681
6700
|
'aria-grabbed': 'true',
|
|
6682
6701
|
'aria-label': this.parent.getAnnouncementString(record)
|
|
6683
6702
|
}
|
|
@@ -6772,7 +6791,7 @@ var VerticalEvent = /** @__PURE__ @class */ (function (_super) {
|
|
|
6772
6791
|
});
|
|
6773
6792
|
var moreIndicatorElement = createElement('div', {
|
|
6774
6793
|
className: MORE_INDICATOR_CLASS,
|
|
6775
|
-
attrs: { 'tabindex': '0', '
|
|
6794
|
+
attrs: { 'tabindex': '0', 'data-index': index.toString(), 'data-count': '1' },
|
|
6776
6795
|
innerHTML: '+1 ' + (this.parent.isAdaptive ? '' : this.parent.localeObj.getConstant('more'))
|
|
6777
6796
|
});
|
|
6778
6797
|
innerCountWrap.appendChild(moreIndicatorElement);
|
|
@@ -7396,9 +7415,7 @@ var MonthEvent = /** @__PURE__ @class */ (function (_super) {
|
|
|
7396
7415
|
this.sortByDateTime(blockList);
|
|
7397
7416
|
if (this.parent.currentView === 'Month' && this.parent.rowAutoHeight && this.parent.activeViewOptions.group.resources.length === 0) {
|
|
7398
7417
|
var totalCells = [].slice.call(this.parent.element.querySelectorAll('.e-content-wrap table tr td:first-child'));
|
|
7399
|
-
var height_1 = this.parent.
|
|
7400
|
-
this.parent.element.querySelector('.e-date-header-wrap').clientHeight) / totalCells.length
|
|
7401
|
-
: this.parent.element.querySelector('.e-schedule-table').clientHeight / totalCells.length;
|
|
7418
|
+
var height_1 = this.parent.element.querySelector('.' + CONTENT_TABLE_CLASS).clientHeight / totalCells.length;
|
|
7402
7419
|
totalCells.forEach(function (cell) {
|
|
7403
7420
|
setStyleAttribute(cell, { 'height': height_1 + 'px' });
|
|
7404
7421
|
});
|
|
@@ -7609,7 +7626,7 @@ var MonthEvent = /** @__PURE__ @class */ (function (_super) {
|
|
|
7609
7626
|
var attrs = {
|
|
7610
7627
|
'data-id': 'Appointment_' + record[this.fields.id],
|
|
7611
7628
|
'role': 'button', 'tabindex': '0',
|
|
7612
|
-
'aria-
|
|
7629
|
+
'aria-disabled': this.parent.eventBase.getReadonlyAttribute(record), 'aria-pressed': 'false', 'aria-grabbed': 'true',
|
|
7613
7630
|
'aria-label': this.parent.getAnnouncementString(newRecord, eventSubject)
|
|
7614
7631
|
};
|
|
7615
7632
|
if (!isCloneElement) {
|
|
@@ -7904,8 +7921,7 @@ var MonthEvent = /** @__PURE__ @class */ (function (_super) {
|
|
|
7904
7921
|
'tabindex': '0',
|
|
7905
7922
|
'data-count': count.toString(),
|
|
7906
7923
|
'data-start-date': startDate.getTime().toString(),
|
|
7907
|
-
'data-end-date': endDate.getTime().toString()
|
|
7908
|
-
'role': 'list'
|
|
7924
|
+
'data-end-date': endDate.getTime().toString()
|
|
7909
7925
|
}
|
|
7910
7926
|
});
|
|
7911
7927
|
return moreIndicatorElement;
|
|
@@ -9104,8 +9120,8 @@ var QuickPopups = /** @__PURE__ @class */ (function () {
|
|
|
9104
9120
|
attrs: {
|
|
9105
9121
|
'data-id': '' + eventData[fields.id],
|
|
9106
9122
|
'data-guid': eventData.Guid, 'role': 'button', 'tabindex': '0',
|
|
9107
|
-
'aria-
|
|
9108
|
-
'aria-
|
|
9123
|
+
'aria-disabled': this_1.parent.eventBase.getReadonlyAttribute(eventData),
|
|
9124
|
+
'aria-pressed': 'false', 'aria-grabbed': 'true', 'aria-label': this_1.parent.getAnnouncementString(eventData)
|
|
9109
9125
|
}
|
|
9110
9126
|
});
|
|
9111
9127
|
var templateElement = void 0;
|
|
@@ -9201,7 +9217,7 @@ var QuickPopups = /** @__PURE__ @class */ (function () {
|
|
|
9201
9217
|
this.quickPopupHide();
|
|
9202
9218
|
return;
|
|
9203
9219
|
}
|
|
9204
|
-
var targetEle = args.event.target;
|
|
9220
|
+
var targetEle = !isNullOrUndefined(args.event) ? args.event.target : args.element;
|
|
9205
9221
|
if (this.parent.isAdaptive) {
|
|
9206
9222
|
this.quickPopupHide();
|
|
9207
9223
|
var newEventClone = this.parent.element.querySelector('.' + NEW_EVENT_CLASS);
|
|
@@ -9297,6 +9313,7 @@ var QuickPopups = /** @__PURE__ @class */ (function () {
|
|
|
9297
9313
|
}
|
|
9298
9314
|
else {
|
|
9299
9315
|
var isSameTarget = this.isSameEventClick(events);
|
|
9316
|
+
this.parent.selectedElements = [];
|
|
9300
9317
|
if (isSameTarget) {
|
|
9301
9318
|
return;
|
|
9302
9319
|
}
|
|
@@ -9362,7 +9379,7 @@ var QuickPopups = /** @__PURE__ @class */ (function () {
|
|
|
9362
9379
|
("<button class=\"" + (DELETE_CLASS + ' ' + ICON) + "\" title=\"" + this.l10n.getConstant('delete') + "\"></button>") +
|
|
9363
9380
|
("<button class=\"" + CLOSE_CLASS + "\" title=\"" + this.l10n.getConstant('close') + "\"></button></div>") +
|
|
9364
9381
|
("<div class=\"" + SUBJECT_WRAP + "\"><div class=\"" + SUBJECT_CLASS + " " + TEXT_ELLIPSIS + "\" ") +
|
|
9365
|
-
("title=\"" + args.eventSubject + "\">" + args.eventSubject + "</div></div >");
|
|
9382
|
+
("title=\"" + (args.eventSubject ? args.eventSubject.replaceAll('"', '\'') : args.eventSubject) + "\">" + args.eventSubject + "</div></div >");
|
|
9366
9383
|
break;
|
|
9367
9384
|
}
|
|
9368
9385
|
var templateWrapper = createElement('div', { innerHTML: header });
|
|
@@ -10621,7 +10638,7 @@ var RecurrenceEditor = /** @__PURE__ @class */ (function (_super) {
|
|
|
10621
10638
|
value: VALUEFIELD
|
|
10622
10639
|
},
|
|
10623
10640
|
placeholder: this.localeObj.getConstant(REPEAT),
|
|
10624
|
-
htmlAttributes: { 'title': this.localeObj.getConstant(REPEAT) },
|
|
10641
|
+
htmlAttributes: { 'title': this.localeObj.getConstant(REPEAT), role: 'option' },
|
|
10625
10642
|
change: function (args) {
|
|
10626
10643
|
self.setProperties({ selectedType: _this.frequencies.indexOf(args.value) }, false);
|
|
10627
10644
|
self.element.querySelector('.' + REPEATCONTENT).innerHTML =
|
|
@@ -10643,6 +10660,7 @@ var RecurrenceEditor = /** @__PURE__ @class */ (function (_super) {
|
|
|
10643
10660
|
text: TEXTFIELD,
|
|
10644
10661
|
value: VALUEFIELD
|
|
10645
10662
|
},
|
|
10663
|
+
htmlAttributes: { role: 'option' },
|
|
10646
10664
|
change: function (args) {
|
|
10647
10665
|
self.freshOnEndForm();
|
|
10648
10666
|
self.updateEndOnForm(args.value);
|
|
@@ -10660,6 +10678,7 @@ var RecurrenceEditor = /** @__PURE__ @class */ (function (_super) {
|
|
|
10660
10678
|
text: TEXTFIELD,
|
|
10661
10679
|
value: VALUEFIELD
|
|
10662
10680
|
},
|
|
10681
|
+
htmlAttributes: { role: 'option' },
|
|
10663
10682
|
index: 1,
|
|
10664
10683
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
10665
10684
|
change: function (args) {
|
|
@@ -10679,6 +10698,7 @@ var RecurrenceEditor = /** @__PURE__ @class */ (function (_super) {
|
|
|
10679
10698
|
text: TEXTFIELD,
|
|
10680
10699
|
value: VALUEFIELD
|
|
10681
10700
|
},
|
|
10701
|
+
htmlAttributes: { role: 'option' },
|
|
10682
10702
|
enableRtl: this.enableRtl,
|
|
10683
10703
|
index: 7,
|
|
10684
10704
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
@@ -11533,6 +11553,7 @@ var EventWindow = /** @__PURE__ @class */ (function () {
|
|
|
11533
11553
|
EventWindow.prototype.setDialogContent = function () {
|
|
11534
11554
|
this.dialogObject.content = this.getEventWindowContent();
|
|
11535
11555
|
this.dialogObject.dataBind();
|
|
11556
|
+
this.applyFormValidation();
|
|
11536
11557
|
};
|
|
11537
11558
|
EventWindow.prototype.preventEventSave = function (e) {
|
|
11538
11559
|
if (this.parent && !this.parent.allowKeyboardInteraction && e.code === 'Enter') {
|
|
@@ -11794,6 +11815,7 @@ var EventWindow = /** @__PURE__ @class */ (function () {
|
|
|
11794
11815
|
resourceData.colorField + '}"></div><div class="e-resource-text">${' + resourceData.textField + '}</div></div>';
|
|
11795
11816
|
if (resourceData.allowMultiple) {
|
|
11796
11817
|
var listObj = new MultiSelect({
|
|
11818
|
+
enableRtl: this.parent.enableRtl,
|
|
11797
11819
|
cssClass: this.parent.cssClass || '',
|
|
11798
11820
|
dataSource: resourceData.dataSource,
|
|
11799
11821
|
change: this.onMultiselectResourceChange.bind(this),
|
|
@@ -11852,7 +11874,7 @@ var EventWindow = /** @__PURE__ @class */ (function () {
|
|
|
11852
11874
|
query = (e.text !== '') ? query.where('Text', 'contains', e.text, true) : query;
|
|
11853
11875
|
e.updateData(_this.parent.timezoneDataSource, query);
|
|
11854
11876
|
},
|
|
11855
|
-
htmlAttributes: { 'title': this.getFieldLabel(value), 'name': fieldName },
|
|
11877
|
+
htmlAttributes: { 'title': this.getFieldLabel(value), 'name': fieldName, role: 'option' },
|
|
11856
11878
|
floatLabelType: 'Always',
|
|
11857
11879
|
placeholder: this.getFieldLabel(value),
|
|
11858
11880
|
popupHeight: '230px'
|
|
@@ -14350,13 +14372,15 @@ var Crud = /** @__PURE__ @class */ (function () {
|
|
|
14350
14372
|
else {
|
|
14351
14373
|
endDate = new Date(+followEvent[fields.startTime]);
|
|
14352
14374
|
var newRecurrenceRule = followEvent[fields.recurrenceRule];
|
|
14353
|
-
|
|
14354
|
-
|
|
14355
|
-
|
|
14356
|
-
|
|
14357
|
-
|
|
14358
|
-
|
|
14359
|
-
|
|
14375
|
+
if (newRecurrenceRule) {
|
|
14376
|
+
var startDate = parentEvent[fields.startTime];
|
|
14377
|
+
var ruleException = (this.parent.currentAction === 'DeleteFollowingEvents') ? followEvent[fields.recurrenceException] : null;
|
|
14378
|
+
var dateCollection = generate(startDate, newRecurrenceRule, ruleException, this.parent.activeViewOptions.firstDayOfWeek);
|
|
14379
|
+
var untilDate = new Date(dateCollection.slice(-1)[0]);
|
|
14380
|
+
untilDate.setHours(endDate.getHours(), endDate.getMinutes(), endDate.getSeconds());
|
|
14381
|
+
endDate.setHours(startDate.getHours(), startDate.getMinutes(), startDate.getSeconds());
|
|
14382
|
+
followEvent[fields.recurrenceRule] = this.getUpdatedRecurrenceRule(newRecurrenceRule, new Date(+untilDate), false);
|
|
14383
|
+
}
|
|
14360
14384
|
}
|
|
14361
14385
|
parentEvent[fields.recurrenceRule] = this.getUpdatedRecurrenceRule(recurrenceRule, addDays(new Date(endDate.getTime()), -1), true);
|
|
14362
14386
|
};
|
|
@@ -18237,6 +18261,72 @@ var Schedule = /** @__PURE__ @class */ (function (_super) {
|
|
|
18237
18261
|
this.eventWindow.dialogClose();
|
|
18238
18262
|
}
|
|
18239
18263
|
};
|
|
18264
|
+
/**
|
|
18265
|
+
* To manually open the quick info popup based on cell or event details.
|
|
18266
|
+
*
|
|
18267
|
+
* @param {object} data Defines the cell or event data. If the data contains valid ID, it will open event quick info popup,
|
|
18268
|
+
* otherwise cell quick info popup displayed.
|
|
18269
|
+
* @returns {void}
|
|
18270
|
+
*/
|
|
18271
|
+
Schedule.prototype.openQuickInfoPopup = function (data) {
|
|
18272
|
+
var _this = this;
|
|
18273
|
+
if (this.currentView === 'Year' || isNullOrUndefined(data)) {
|
|
18274
|
+
return;
|
|
18275
|
+
}
|
|
18276
|
+
if (isNullOrUndefined(data[this.eventFields.id])) {
|
|
18277
|
+
if (this.currentView === 'Agenda' || this.currentView === 'MonthAgenda' || isNullOrUndefined(this.activeView)) {
|
|
18278
|
+
return;
|
|
18279
|
+
}
|
|
18280
|
+
var cellData = {
|
|
18281
|
+
startTime: this.activeCellsData.startTime = this.getDateTime(data[this.eventFields.startTime]),
|
|
18282
|
+
endTime: this.activeCellsData.endTime = this.getDateTime(data[this.eventFields.endTime]),
|
|
18283
|
+
isAllDay: this.activeCellsData.isAllDay =
|
|
18284
|
+
!isNullOrUndefined(data[this.eventFields.isAllDay]) ? data[this.eventFields.isAllDay] : false
|
|
18285
|
+
};
|
|
18286
|
+
var startTime = this.activeView.getAdjustedDate(new Date(cellData.startTime));
|
|
18287
|
+
if (startTime) {
|
|
18288
|
+
var query = '.' + WORK_CELLS_CLASS + '[data-date="' + startTime.getTime() + '"]';
|
|
18289
|
+
if (this.activeViewOptions.group.resources.length > 0 && !this.uiStateValues.isGroupAdaptive
|
|
18290
|
+
&& this.resourceBase && this.eventBase) {
|
|
18291
|
+
cellData.groupIndex = this.eventBase.getGroupIndexFromEvent(data);
|
|
18292
|
+
query = '.' + WORK_CELLS_CLASS + '[data-date="' + startTime.getTime() + '"][data-group-index="' + cellData.groupIndex + '"]';
|
|
18293
|
+
}
|
|
18294
|
+
var workCell = this.element.querySelector(query);
|
|
18295
|
+
if (workCell) {
|
|
18296
|
+
workCell.focus();
|
|
18297
|
+
cellData.element = workCell;
|
|
18298
|
+
this.notify(cellClick, cellData);
|
|
18299
|
+
}
|
|
18300
|
+
}
|
|
18301
|
+
}
|
|
18302
|
+
else {
|
|
18303
|
+
var app = this.getCurrentViewEvents().filter(function (item) {
|
|
18304
|
+
return data[_this.eventFields.id] === item[_this.eventFields.id];
|
|
18305
|
+
});
|
|
18306
|
+
if (app.length <= 0) {
|
|
18307
|
+
return;
|
|
18308
|
+
}
|
|
18309
|
+
var selectEvent = app[0];
|
|
18310
|
+
if (data[this.eventFields.recurrenceRule]) {
|
|
18311
|
+
var occurence = app.filter(function (x) {
|
|
18312
|
+
return x[_this.eventFields.startTime].getTime() === data[_this.eventFields.startTime].getTime();
|
|
18313
|
+
});
|
|
18314
|
+
if (occurence.length > 0) {
|
|
18315
|
+
selectEvent = occurence[0];
|
|
18316
|
+
}
|
|
18317
|
+
}
|
|
18318
|
+
var element = this.element.querySelector('div[data-guid="' + selectEvent.Guid + '"]');
|
|
18319
|
+
if (element) {
|
|
18320
|
+
this.eventBase.removeSelectedAppointmentClass();
|
|
18321
|
+
this.eventBase.addSelectedAppointments([element]);
|
|
18322
|
+
this.activeEventData = { event: selectEvent, element: element };
|
|
18323
|
+
if (this.currentView === 'Agenda' || this.currentView === 'MonthAgenda') {
|
|
18324
|
+
addClass([this.activeEventData.element], AGENDA_SELECTED_CELL);
|
|
18325
|
+
}
|
|
18326
|
+
this.notify(eventClick, this.activeEventData);
|
|
18327
|
+
}
|
|
18328
|
+
}
|
|
18329
|
+
};
|
|
18240
18330
|
/**
|
|
18241
18331
|
* To manually close the quick info popup
|
|
18242
18332
|
*
|
|
@@ -18917,6 +19007,7 @@ var ActionBase = /** @__PURE__ @class */ (function () {
|
|
|
18917
19007
|
};
|
|
18918
19008
|
ActionBase.prototype.updateScrollPosition = function (e) {
|
|
18919
19009
|
var _this = this;
|
|
19010
|
+
this.scrollEventArgs = e;
|
|
18920
19011
|
if (this.actionObj.scroll.enable && isNullOrUndefined(this.actionObj.scrollInterval)) {
|
|
18921
19012
|
this.actionObj.scrollInterval = window.setInterval(function () {
|
|
18922
19013
|
if (_this.autoScrollValidation() && !_this.actionObj.clone.classList.contains(ALLDAY_APPOINTMENT_CLASS)) {
|
|
@@ -18926,10 +19017,10 @@ var ActionBase = /** @__PURE__ @class */ (function () {
|
|
|
18926
19017
|
}
|
|
18927
19018
|
_this.autoScroll();
|
|
18928
19019
|
if (_this.actionObj.action === 'drag') {
|
|
18929
|
-
_this.parent.dragAndDropModule.updateDraggingDateTime(
|
|
19020
|
+
_this.parent.dragAndDropModule.updateDraggingDateTime(_this.scrollEventArgs);
|
|
18930
19021
|
}
|
|
18931
19022
|
else {
|
|
18932
|
-
_this.parent.resizeModule.updateResizingDirection(
|
|
19023
|
+
_this.parent.resizeModule.updateResizingDirection(_this.scrollEventArgs);
|
|
18933
19024
|
}
|
|
18934
19025
|
}
|
|
18935
19026
|
}, this.actionObj.scroll.timeDelay);
|
|
@@ -19732,7 +19823,7 @@ var YearEvent = /** @__PURE__ @class */ (function (_super) {
|
|
|
19732
19823
|
}
|
|
19733
19824
|
};
|
|
19734
19825
|
YearEvent.prototype.timelineYearViewEvents = function () {
|
|
19735
|
-
var workCell = this.parent.element.querySelector('.' + WORK_CELLS_CLASS);
|
|
19826
|
+
var workCell = this.parent.element.querySelector('.' + WORK_CELLS_CLASS + ':not(.' + OTHERMONTH_CLASS + ')');
|
|
19736
19827
|
this.cellWidth = workCell.offsetWidth;
|
|
19737
19828
|
this.cellHeader = getOuterHeight(workCell.querySelector('.' + DATE_HEADER_CLASS));
|
|
19738
19829
|
var eventTable = this.parent.element.querySelector('.' + EVENT_TABLE_CLASS);
|
|
@@ -20017,7 +20108,7 @@ var YearEvent = /** @__PURE__ @class */ (function (_super) {
|
|
|
20017
20108
|
'data-id': 'Appointment_' + record[this.fields.id],
|
|
20018
20109
|
'data-guid': record.Guid,
|
|
20019
20110
|
'role': 'button', 'tabindex': '0',
|
|
20020
|
-
'aria-
|
|
20111
|
+
'aria-disabled': this.parent.eventBase.getReadonlyAttribute(record), 'aria-pressed': 'false', 'aria-grabbed': 'true',
|
|
20021
20112
|
'aria-label': this.parent.getAnnouncementString(record)
|
|
20022
20113
|
}
|
|
20023
20114
|
});
|
|
@@ -21402,7 +21493,7 @@ var DragAndDrop = /** @__PURE__ @class */ (function (_super) {
|
|
|
21402
21493
|
var cursorElement = this.getCursorElement(e);
|
|
21403
21494
|
if (cursorElement) {
|
|
21404
21495
|
top = cursorElement.classList.contains(WORK_CELLS_CLASS) ? cursorElement.offsetTop :
|
|
21405
|
-
cursorElement.offsetParent.classList.contains(APPOINTMENT_CLASS) ?
|
|
21496
|
+
(cursorElement.offsetParent && cursorElement.offsetParent.classList.contains(APPOINTMENT_CLASS)) ?
|
|
21406
21497
|
cursorElement.offsetParent.offsetTop : top;
|
|
21407
21498
|
}
|
|
21408
21499
|
}
|
|
@@ -21951,6 +22042,14 @@ var ViewBase = /** @__PURE__ @class */ (function () {
|
|
|
21951
22042
|
var tdDate = new Date(resetTime(new Date(+scrollDate)).getTime()).getTime();
|
|
21952
22043
|
var dateElement = scrollWrap.querySelector("." + WORK_CELLS_CLASS + "[data-date=\"" + tdDate + "\"]");
|
|
21953
22044
|
if (this.parent.currentView === 'Month' && dateElement) {
|
|
22045
|
+
if (scrollWrap.scrollWidth > scrollWrap.clientWidth) {
|
|
22046
|
+
if (!this.parent.enableRtl) {
|
|
22047
|
+
scrollWrap.scrollLeft = dateElement.offsetLeft;
|
|
22048
|
+
}
|
|
22049
|
+
else {
|
|
22050
|
+
scrollWrap.scrollLeft = -(this.parent.getContentTable().offsetWidth - dateElement.offsetLeft - dateElement.offsetWidth);
|
|
22051
|
+
}
|
|
22052
|
+
}
|
|
21954
22053
|
scrollWrap.scrollTop = dateElement.offsetTop;
|
|
21955
22054
|
}
|
|
21956
22055
|
if (this.parent.currentView === 'TimelineMonth' && dateElement) {
|
|
@@ -21994,6 +22093,17 @@ var ViewBase = /** @__PURE__ @class */ (function () {
|
|
|
21994
22093
|
}
|
|
21995
22094
|
return endDate;
|
|
21996
22095
|
};
|
|
22096
|
+
ViewBase.prototype.getAdjustedDate = function (startTime) {
|
|
22097
|
+
if (!this.parent.activeViewOptions.timeScale.enable || this.parent.currentView === 'Month' ||
|
|
22098
|
+
(this.parent.currentView === 'TimelineYear' && this.parent.activeViewOptions.group.resources.length === 0)) {
|
|
22099
|
+
return new Date(startTime.setHours(0, 0, 0, 0));
|
|
22100
|
+
}
|
|
22101
|
+
else if (this.parent.currentView === 'TimelineYear' && this.parent.activeViewOptions.group.resources.length > 0) {
|
|
22102
|
+
startTime.setHours(0, 0, 0, 0);
|
|
22103
|
+
return new Date(startTime.setDate(1));
|
|
22104
|
+
}
|
|
22105
|
+
return null;
|
|
22106
|
+
};
|
|
21997
22107
|
ViewBase.prototype.destroy = function () {
|
|
21998
22108
|
if (this.element && this.element.parentNode) {
|
|
21999
22109
|
remove(this.element);
|
|
@@ -22155,11 +22265,26 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
|
|
|
22155
22265
|
};
|
|
22156
22266
|
VerticalView.prototype.scrollToHour = function (hour, scrollDate) {
|
|
22157
22267
|
var date = this.parent.getStartEndTime(hour);
|
|
22158
|
-
if (
|
|
22268
|
+
if (!isNullOrUndefined(scrollDate)) {
|
|
22269
|
+
var headerElement = this.element.querySelector('.' + HEADER_CELLS_CLASS + '[data-date="' + new Date(resetTime(scrollDate)).getTime() + '"]');
|
|
22270
|
+
if (headerElement) {
|
|
22271
|
+
if (this.parent.enableRtl) {
|
|
22272
|
+
var conWrap = this.element.querySelector('.' + CONTENT_TABLE_CLASS);
|
|
22273
|
+
this.getScrollableElement().scrollLeft = -(conWrap.offsetWidth - headerElement.offsetLeft - headerElement.offsetWidth);
|
|
22274
|
+
}
|
|
22275
|
+
else {
|
|
22276
|
+
this.getScrollableElement().scrollLeft = headerElement.offsetLeft;
|
|
22277
|
+
}
|
|
22278
|
+
}
|
|
22279
|
+
}
|
|
22280
|
+
if (isNullOrUndefined(date)) {
|
|
22159
22281
|
return;
|
|
22160
22282
|
}
|
|
22161
22283
|
this.getScrollableElement().scrollTop = this.getTopFromDateTime(date);
|
|
22162
22284
|
};
|
|
22285
|
+
VerticalView.prototype.scrollToDate = function (scrollDate) {
|
|
22286
|
+
this.scrollToHour(null, scrollDate);
|
|
22287
|
+
};
|
|
22163
22288
|
VerticalView.prototype.generateColumnLevels = function () {
|
|
22164
22289
|
var level = this.getDateSlots(this.renderDates, this.parent.activeViewOptions.workDays);
|
|
22165
22290
|
var columnLevels = [];
|
|
@@ -22498,12 +22623,11 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
|
|
|
22498
22623
|
var wrap = createElement('div', { className: DATE_HEADER_WRAP_CLASS });
|
|
22499
22624
|
container.appendChild(wrap);
|
|
22500
22625
|
var tbl = this.createTableLayout();
|
|
22501
|
-
var trEle = createElement('tr');
|
|
22626
|
+
var trEle = createElement('tr', { className: HEADER_ROW_CLASS });
|
|
22502
22627
|
var rowCount = this.colLevels.length;
|
|
22503
22628
|
var lastLevel = this.colLevels[rowCount - 1];
|
|
22504
22629
|
for (var i = 0; i < rowCount; i++) {
|
|
22505
22630
|
var ntr = trEle.cloneNode();
|
|
22506
|
-
addClass([ntr], HEADER_ROW_CLASS);
|
|
22507
22631
|
var level = this.colLevels[i];
|
|
22508
22632
|
for (var j = 0; j < level.length; j++) {
|
|
22509
22633
|
ntr.appendChild(this.createTd(level[j]));
|
|
@@ -22516,13 +22640,13 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
|
|
|
22516
22640
|
return container;
|
|
22517
22641
|
};
|
|
22518
22642
|
VerticalView.prototype.createAllDayRow = function (table, tdData) {
|
|
22519
|
-
var ntr = createElement('tr');
|
|
22520
|
-
addClass([ntr], ALLDAY_ROW_CLASS);
|
|
22643
|
+
var ntr = createElement('tr', { className: ALLDAY_ROW_CLASS });
|
|
22521
22644
|
for (var j = 0; j < tdData.length; j++) {
|
|
22522
22645
|
var td = extend({}, tdData[j]);
|
|
22523
22646
|
td.className = [ALLDAY_CELLS_CLASS];
|
|
22524
22647
|
td.type = 'alldayCells';
|
|
22525
22648
|
var ntd = this.createTd(td);
|
|
22649
|
+
ntd.setAttribute('role', 'gridcell');
|
|
22526
22650
|
ntd.setAttribute('data-date', td.date.getTime().toString());
|
|
22527
22651
|
if (!isNullOrUndefined(td.groupIndex)) {
|
|
22528
22652
|
ntd.setAttribute('data-group-index', '' + td.groupIndex);
|
|
@@ -22555,6 +22679,7 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
|
|
|
22555
22679
|
}
|
|
22556
22680
|
if (td.type === 'dateHeader' && td.className.indexOf(HEADER_CELLS_CLASS) >= 0) {
|
|
22557
22681
|
tdEle.setAttribute('data-date', td.date.getTime().toString());
|
|
22682
|
+
tdEle.setAttribute('role', 'gridcell');
|
|
22558
22683
|
if (!isNullOrUndefined(td.groupIndex)) {
|
|
22559
22684
|
tdEle.setAttribute('data-group-index', '' + td.groupIndex);
|
|
22560
22685
|
}
|
|
@@ -22757,6 +22882,23 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
|
|
|
22757
22882
|
}
|
|
22758
22883
|
return rows;
|
|
22759
22884
|
};
|
|
22885
|
+
VerticalView.prototype.getAdjustedDate = function (startTime) {
|
|
22886
|
+
if (!this.parent.activeViewOptions.timeScale.enable) {
|
|
22887
|
+
return new Date(startTime.setHours(0, 0, 0, 0));
|
|
22888
|
+
}
|
|
22889
|
+
else {
|
|
22890
|
+
var timeSlots = this.getTimeSlotRows();
|
|
22891
|
+
var startDate = new Date(new Date(timeSlots[0].date.getTime()).
|
|
22892
|
+
setHours(startTime.getHours(), startTime.getMinutes(), startTime.getMilliseconds()));
|
|
22893
|
+
for (var i = 0; i < timeSlots.length; i++) {
|
|
22894
|
+
if (timeSlots[i].date.getTime() > startDate.getTime()) {
|
|
22895
|
+
startTime.setHours(timeSlots[i - 1].date.getHours(), timeSlots[i - 1].date.getMinutes(), timeSlots[i - 1].date.getMilliseconds());
|
|
22896
|
+
return new Date(startTime);
|
|
22897
|
+
}
|
|
22898
|
+
}
|
|
22899
|
+
}
|
|
22900
|
+
return null;
|
|
22901
|
+
};
|
|
22760
22902
|
VerticalView.prototype.destroy = function () {
|
|
22761
22903
|
if (!this.parent || this.parent && this.parent.isDestroyed) {
|
|
22762
22904
|
return;
|
|
@@ -23898,7 +24040,8 @@ var Year = /** @__PURE__ @class */ (function (_super) {
|
|
|
23898
24040
|
return this.parent.currentView === 'Year' ? getWeekFirstDate(this.getStartDate(), this.parent.firstDayOfWeek) : this.getStartDate();
|
|
23899
24041
|
};
|
|
23900
24042
|
Year.prototype.endDate = function () {
|
|
23901
|
-
return this.parent.currentView === 'Year' ? addDays(getWeekLastDate(this.getEndDate(), this.parent.firstDayOfWeek), 1) :
|
|
24043
|
+
return this.parent.currentView === 'Year' ? addDays(getWeekLastDate(this.getEndDate(), this.parent.firstDayOfWeek), 1) :
|
|
24044
|
+
addDays(this.getEndDate(), 1);
|
|
23902
24045
|
};
|
|
23903
24046
|
Year.prototype.getEndDateFromStartDate = function (start) {
|
|
23904
24047
|
var date = new Date(start.getTime());
|
|
@@ -24024,8 +24167,8 @@ var AgendaBase = /** @__PURE__ @class */ (function (_super) {
|
|
|
24024
24167
|
'data-guid': listData[li].Guid,
|
|
24025
24168
|
'role': 'button',
|
|
24026
24169
|
'tabindex': '0',
|
|
24027
|
-
'aria-
|
|
24028
|
-
'aria-
|
|
24170
|
+
'aria-disabled': _this.parent.eventBase.getReadonlyAttribute(listData[li]),
|
|
24171
|
+
'aria-pressed': 'false',
|
|
24029
24172
|
'aria-grabbed': 'true',
|
|
24030
24173
|
'aria-label': _this.parent.getAnnouncementString(listData[li])
|
|
24031
24174
|
}
|
|
@@ -24293,8 +24436,8 @@ var AgendaBase = /** @__PURE__ @class */ (function (_super) {
|
|
|
24293
24436
|
ntd.appendChild(this.createDateHeaderElement(tempData.date));
|
|
24294
24437
|
addClass([ntd], [AGENDA_CELLS_CLASS, AGENDA_DATE_CLASS, DATE_BORDER_CLASS]);
|
|
24295
24438
|
var daysCount = getDaysCount(this.parent.selectedDate.getTime(), tempData.date.getTime());
|
|
24296
|
-
ntr.setAttribute('
|
|
24297
|
-
if (this.parent.element.querySelector(".e-agenda-view tr[
|
|
24439
|
+
ntr.setAttribute('data-row-index', daysCount.toString());
|
|
24440
|
+
if (this.parent.element.querySelector(".e-agenda-view tr[data-row-index=\"" + daysCount + "\"]")) {
|
|
24298
24441
|
break;
|
|
24299
24442
|
}
|
|
24300
24443
|
ntr.insertBefore(ntd, ntr.childNodes[0]);
|
|
@@ -24330,13 +24473,13 @@ var AgendaBase = /** @__PURE__ @class */ (function (_super) {
|
|
|
24330
24473
|
};
|
|
24331
24474
|
AgendaBase.prototype.createTableRowElement = function (date, type) {
|
|
24332
24475
|
var daysCount = getDaysCount(this.parent.selectedDate.getTime(), date.getTime());
|
|
24333
|
-
var tr = createElement('tr', { attrs: { 'role': 'row', '
|
|
24476
|
+
var tr = createElement('tr', { attrs: { 'role': 'row', 'data-row-index': daysCount.toString() } });
|
|
24334
24477
|
var td = createElement('td', {
|
|
24335
24478
|
attrs: {
|
|
24336
24479
|
'class': (type === 'monthHeader') ? MONTH_HEADER_CLASS : AGENDA_CELLS_CLASS,
|
|
24337
24480
|
'role': 'gridcell',
|
|
24338
24481
|
'aria-selected': 'false',
|
|
24339
|
-
'
|
|
24482
|
+
'data-column-index': daysCount.toString(),
|
|
24340
24483
|
'data-date': date.getTime().toString()
|
|
24341
24484
|
}
|
|
24342
24485
|
});
|
|
@@ -24521,7 +24664,7 @@ var Agenda = /** @__PURE__ @class */ (function (_super) {
|
|
|
24521
24664
|
for (var day = 0; day < this.parent.agendaDaysCount; day++) {
|
|
24522
24665
|
var filterData = this.appointmentFiltering(agendaDate);
|
|
24523
24666
|
var nTr = this.createTableRowElement(agendaDate, 'data');
|
|
24524
|
-
if (this.element.querySelector('tr[
|
|
24667
|
+
if (this.element.querySelector('tr[data-row-index="' + parseInt(nTr.getAttribute('data-row-index'), 10) + '"]')) {
|
|
24525
24668
|
agendaDate = addDays(agendaDate, 1);
|
|
24526
24669
|
continue;
|
|
24527
24670
|
}
|
|
@@ -24585,7 +24728,7 @@ var Agenda = /** @__PURE__ @class */ (function (_super) {
|
|
|
24585
24728
|
prepend([].slice.call(emptyTBody.childNodes), tBody);
|
|
24586
24729
|
this.wireEventActions();
|
|
24587
24730
|
for (var s = 0, element = tBody.children; s < element.length; s++) {
|
|
24588
|
-
if (element[s].getAttribute('
|
|
24731
|
+
if (element[s].getAttribute('data-row-index') === topElement.getAttribute('data-column-index')) {
|
|
24589
24732
|
var scrollToValue = element[s].offsetTop -
|
|
24590
24733
|
this.element.querySelector('.e-agenda-item').offsetHeight;
|
|
24591
24734
|
target.scrollTop = scrollToValue;
|
|
@@ -25336,6 +25479,20 @@ var TimelineViews = /** @__PURE__ @class */ (function (_super) {
|
|
|
25336
25479
|
this.timelineAppointment.renderAppointments();
|
|
25337
25480
|
this.parent.notify(eventsLoaded, {});
|
|
25338
25481
|
};
|
|
25482
|
+
TimelineViews.prototype.getAdjustedDate = function (date) {
|
|
25483
|
+
if (!this.parent.activeViewOptions.timeScale.enable) {
|
|
25484
|
+
return new Date(date.setHours(0, 0, 0, 0));
|
|
25485
|
+
}
|
|
25486
|
+
else {
|
|
25487
|
+
var timeSlots = this.colLevels[this.colLevels.length - 1];
|
|
25488
|
+
for (var i = 0; i < timeSlots.length; i++) {
|
|
25489
|
+
if (timeSlots[i].date.getTime() > date.getTime()) {
|
|
25490
|
+
return timeSlots[i - 1].date;
|
|
25491
|
+
}
|
|
25492
|
+
}
|
|
25493
|
+
}
|
|
25494
|
+
return null;
|
|
25495
|
+
};
|
|
25339
25496
|
TimelineViews.prototype.destroy = function () {
|
|
25340
25497
|
if (!this.parent || this.parent && this.parent.isDestroyed) {
|
|
25341
25498
|
return;
|
|
@@ -25494,6 +25651,15 @@ var TimelineMonth = /** @__PURE__ @class */ (function (_super) {
|
|
|
25494
25651
|
this.colLevels = colLevels;
|
|
25495
25652
|
return colLevels;
|
|
25496
25653
|
};
|
|
25654
|
+
TimelineMonth.prototype.getAdjustedDate = function (startTime) {
|
|
25655
|
+
var timeSlots = this.colLevels[this.colLevels.length - 1];
|
|
25656
|
+
for (var i = 0; i < timeSlots.length; i++) {
|
|
25657
|
+
if (timeSlots[i].date.getTime() > startTime.getTime()) {
|
|
25658
|
+
return timeSlots[i - 1].date;
|
|
25659
|
+
}
|
|
25660
|
+
}
|
|
25661
|
+
return null;
|
|
25662
|
+
};
|
|
25497
25663
|
TimelineMonth.prototype.destroy = function () {
|
|
25498
25664
|
if (!this.parent || this.parent && this.parent.isDestroyed) {
|
|
25499
25665
|
return;
|
|
@@ -25781,6 +25947,9 @@ var TimelineYear = /** @__PURE__ @class */ (function (_super) {
|
|
|
25781
25947
|
else {
|
|
25782
25948
|
addClass([td], OTHERMONTH_CLASS);
|
|
25783
25949
|
}
|
|
25950
|
+
if (td.classList.contains(OTHERMONTH_CLASS)) {
|
|
25951
|
+
continue;
|
|
25952
|
+
}
|
|
25784
25953
|
td.appendChild(dateHeader);
|
|
25785
25954
|
if (isDateAvail) {
|
|
25786
25955
|
td.setAttribute('data-date', date.getTime().toString());
|
|
@@ -25968,7 +26137,7 @@ var ICalendarExport = /** @__PURE__ @class */ (function () {
|
|
|
25968
26137
|
var timeZone = this.parent.timezone || this.parent.tzModule.getLocalTimezoneName();
|
|
25969
26138
|
var fields = this.parent.eventFields;
|
|
25970
26139
|
eventsData.forEach(function (eventObj) {
|
|
25971
|
-
var uId = _this.parent.eventBase.generateGuid();
|
|
26140
|
+
var uId = eventObj[fields.id] || eventObj.Guid || _this.parent.eventBase.generateGuid();
|
|
25972
26141
|
var editedExDate = [];
|
|
25973
26142
|
if (eventObj[fields.recurrenceID]) {
|
|
25974
26143
|
var filter = _this.filterEvents(filterCollection, fields.id, eventObj[fields.recurrenceID]);
|
|
@@ -26172,8 +26341,16 @@ var ICalendarImport = /** @__PURE__ @class */ (function () {
|
|
|
26172
26341
|
break;
|
|
26173
26342
|
case 'UID':
|
|
26174
26343
|
curEvent[uId] = value;
|
|
26175
|
-
|
|
26176
|
-
|
|
26344
|
+
if (typeof (id) == 'number') {
|
|
26345
|
+
curEvent[fields.id] = parseInt(value, 10);
|
|
26346
|
+
if (isNaN(curEvent[fields.id])) {
|
|
26347
|
+
curEvent[fields.id] = id + count;
|
|
26348
|
+
count++;
|
|
26349
|
+
}
|
|
26350
|
+
}
|
|
26351
|
+
else {
|
|
26352
|
+
curEvent[fields.id] = value;
|
|
26353
|
+
}
|
|
26177
26354
|
break;
|
|
26178
26355
|
case 'SUMMARY':
|
|
26179
26356
|
curEvent[fields.subject] = value;
|
|
@@ -26209,6 +26386,10 @@ var ICalendarImport = /** @__PURE__ @class */ (function () {
|
|
|
26209
26386
|
var appoint = [];
|
|
26210
26387
|
var uId = 'UID';
|
|
26211
26388
|
var fields = this.parent.eventFields;
|
|
26389
|
+
var appointmentIds = [];
|
|
26390
|
+
this.parent.eventsData.forEach(function (eventObj) {
|
|
26391
|
+
appointmentIds.push(eventObj[fields.id]);
|
|
26392
|
+
});
|
|
26212
26393
|
app.forEach(function (eventObj) {
|
|
26213
26394
|
var parentObj;
|
|
26214
26395
|
var id;
|
|
@@ -26217,24 +26398,26 @@ var ICalendarImport = /** @__PURE__ @class */ (function () {
|
|
|
26217
26398
|
parentObj = eventObj;
|
|
26218
26399
|
id = eventObj[fields.id];
|
|
26219
26400
|
}
|
|
26220
|
-
|
|
26221
|
-
|
|
26222
|
-
|
|
26223
|
-
|
|
26224
|
-
|
|
26225
|
-
|
|
26226
|
-
|
|
26227
|
-
|
|
26228
|
-
|
|
26229
|
-
|
|
26230
|
-
|
|
26401
|
+
if (appointmentIds.indexOf(eventObj[fields.id]) < 0) {
|
|
26402
|
+
var data = app.filter(function (data) { return data.UID === eventObj[uId]; });
|
|
26403
|
+
if (data.length > 1 && isNullOrUndefined(eventObj[fields.recurrenceID])) {
|
|
26404
|
+
for (var i = 0; i < data.length; i++) {
|
|
26405
|
+
// eslint-disable-next-line no-prototype-builtins
|
|
26406
|
+
if (data[i].hasOwnProperty(fields.recurrenceID)) {
|
|
26407
|
+
var exdate = data[i][fields.recurrenceID];
|
|
26408
|
+
data[i][fields.recurrenceID] = id;
|
|
26409
|
+
data[i][fields.recurrenceException] = null;
|
|
26410
|
+
parentObj[fields.recurrenceException] = (isNullOrUndefined(parentObj[fields.recurrenceException])) ?
|
|
26411
|
+
exdate : parentObj[fields.recurrenceException] + ',' + exdate;
|
|
26412
|
+
appoint.push(data[i]);
|
|
26413
|
+
}
|
|
26231
26414
|
}
|
|
26415
|
+
appoint.push(parentObj);
|
|
26416
|
+
// eslint-disable-next-line no-prototype-builtins
|
|
26417
|
+
}
|
|
26418
|
+
else if (!eventObj.hasOwnProperty(fields.recurrenceID)) {
|
|
26419
|
+
appoint.push(eventObj);
|
|
26232
26420
|
}
|
|
26233
|
-
appoint.push(parentObj);
|
|
26234
|
-
// eslint-disable-next-line no-prototype-builtins
|
|
26235
|
-
}
|
|
26236
|
-
else if (!eventObj.hasOwnProperty(fields.recurrenceID)) {
|
|
26237
|
-
appoint.push(eventObj);
|
|
26238
26421
|
}
|
|
26239
26422
|
});
|
|
26240
26423
|
return appoint;
|
|
@@ -26294,6 +26477,10 @@ var ExcelExport = /** @__PURE__ @class */ (function () {
|
|
|
26294
26477
|
var exportName = excelExportOptions.fileName || 'Schedule';
|
|
26295
26478
|
var exportType = excelExportOptions.exportType || 'xlsx';
|
|
26296
26479
|
var isIncludeOccurrences = excelExportOptions.includeOccurrences || false;
|
|
26480
|
+
var separator;
|
|
26481
|
+
if (!isNullOrUndefined(excelExportOptions.separator) && excelExportOptions.separator !== ',') {
|
|
26482
|
+
separator = excelExportOptions.separator;
|
|
26483
|
+
}
|
|
26297
26484
|
var eventCollection;
|
|
26298
26485
|
if (excelExportOptions.customData) {
|
|
26299
26486
|
eventCollection = !isIncludeOccurrences ? excelExportOptions.customData :
|
|
@@ -26302,9 +26489,9 @@ var ExcelExport = /** @__PURE__ @class */ (function () {
|
|
|
26302
26489
|
else {
|
|
26303
26490
|
eventCollection = !isIncludeOccurrences ? this.parent.eventsData : this.parent.eventsProcessed;
|
|
26304
26491
|
}
|
|
26305
|
-
this.processWorkbook(exportColumns, exportName, exportType, eventCollection);
|
|
26492
|
+
this.processWorkbook(exportColumns, exportName, exportType, eventCollection, separator);
|
|
26306
26493
|
};
|
|
26307
|
-
ExcelExport.prototype.processWorkbook = function (fields, name, type, eventCollection) {
|
|
26494
|
+
ExcelExport.prototype.processWorkbook = function (fields, name, type, eventCollection, separator) {
|
|
26308
26495
|
var _this = this;
|
|
26309
26496
|
var columns = [];
|
|
26310
26497
|
var rows = [];
|
|
@@ -26326,7 +26513,7 @@ var ExcelExport = /** @__PURE__ @class */ (function () {
|
|
|
26326
26513
|
rows.push({ index: i + 2, cells: columnData });
|
|
26327
26514
|
});
|
|
26328
26515
|
var workSheet = [{ columns: columns, rows: rows }];
|
|
26329
|
-
var book = new Workbook({ worksheets: workSheet }, type, this.parent.locale);
|
|
26516
|
+
var book = new Workbook({ worksheets: workSheet }, type, this.parent.locale, undefined, separator);
|
|
26330
26517
|
book.save(name + '.' + type);
|
|
26331
26518
|
};
|
|
26332
26519
|
ExcelExport.prototype.getExportColumns = function (exportOptions) {
|