@syncfusion/ej2-schedule 28.1.39 → 28.2.4

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.
@@ -1508,6 +1508,7 @@ class HeaderRenderer {
1508
1508
  min: this.parent.minDate,
1509
1509
  max: this.parent.maxDate,
1510
1510
  firstDayOfWeek: this.parent.activeViewOptions.firstDayOfWeek,
1511
+ weekNumber: this.parent.activeViewOptions.showWeekNumber,
1511
1512
  enableRtl: this.parent.enableRtl,
1512
1513
  locale: this.parent.locale,
1513
1514
  depth: calendarView,
@@ -9118,8 +9119,8 @@ class TimelineEvent extends MonthEvent {
9118
9119
  return slotTd;
9119
9120
  }
9120
9121
  else {
9121
- const daySlot = Math.round((((getUniversalTime(schedule.endHour) - getUniversalTime(schedule.startHour)) /
9122
- MS_PER_MINUTE) / this.getIntervalInMinutes(startTime)) * this.slotCount);
9122
+ const daySlot = Math.round(((getUniversalTime(schedule.endHour) - getUniversalTime(schedule.startHour)) /
9123
+ this.interval / MS_PER_MINUTE) * this.slotCount);
9123
9124
  return (daySlot * day) + slotTd;
9124
9125
  }
9125
9126
  }
@@ -10860,7 +10861,7 @@ class QuickPopups {
10860
10861
  documentClick(e) {
10861
10862
  const target = e.event.target;
10862
10863
  const classNames = '.' + POPUP_WRAPPER_CLASS + ',.' + HEADER_CELLS_CLASS + ',.' + ALLDAY_CELLS_CLASS +
10863
- ',.' + WORK_CELLS_CLASS + ',.' + APPOINTMENT_CLASS + ',.e-popup';
10864
+ ',.' + WORK_CELLS_CLASS + ',.' + APPOINTMENT_CLASS;
10864
10865
  const popupWrap = this.parent.element.querySelector('.' + POPUP_WRAPPER_CLASS);
10865
10866
  if ((popupWrap && popupWrap.childElementCount > 0 && !closest(target, classNames)) || !closest(target, classNames)) {
10866
10867
  this.quickPopupHide();
@@ -10875,7 +10876,8 @@ class QuickPopups {
10875
10876
  }
10876
10877
  if (!closest(target, '.' + MORE_POPUP_WRAPPER_CLASS) && (target.classList &&
10877
10878
  !target.classList.contains(MORE_INDICATOR_CLASS))
10878
- && (!closest(target, '.' + POPUP_OPEN)) && !closest(target, '.' + WORK_CELLS_CLASS)) {
10879
+ && (!closest(target, '.' + MORE_POPUP_WRAPPER_CLASS + '.' + POPUP_OPEN))
10880
+ && !closest(target, '.' + WORK_CELLS_CLASS)) {
10879
10881
  this.morePopup.hide();
10880
10882
  }
10881
10883
  }
@@ -15378,7 +15380,7 @@ class Crud {
15378
15380
  editParams.changedRecords.push(this.parent.eventBase.processTimezone(parentEvent, true));
15379
15381
  }
15380
15382
  if (childEvent[fields.id] !== parentEvent[fields.id]) {
15381
- editParams.deletedRecords.push(childEvent);
15383
+ editParams.deletedRecords.push(this.parent.eventBase.processTimezone(childEvent, true));
15382
15384
  isDeletedRecords = true;
15383
15385
  }
15384
15386
  break;
@@ -15528,7 +15530,7 @@ class Crud {
15528
15530
  this.parent.uiStateValues.isIgnoreOccurrence = false;
15529
15531
  break;
15530
15532
  case 'DeleteSeries':
15531
- editParams.deletedRecords = editParams.deletedRecords.concat(deletedEvents.concat(parentEvent));
15533
+ editParams.deletedRecords = editParams.deletedRecords.concat(deletedEvents.concat(this.parent.eventBase.processTimezone(parentEvent, true)));
15532
15534
  isDeletedRecords = true;
15533
15535
  break;
15534
15536
  }
@@ -15585,11 +15587,17 @@ class Crud {
15585
15587
  isDelete = deleteArgs.deletedRecords[parseInt(a.toString(), 10)][fields.id] !== parentEvent[fields.id];
15586
15588
  }
15587
15589
  if (isDelete) {
15590
+ if (deleteArgs.deletedRecords instanceof Array) {
15591
+ for (const event of deleteArgs.deletedRecords) {
15592
+ this.parent.eventBase.processTimezone(event, true);
15593
+ }
15594
+ }
15588
15595
  editParams.deletedRecords.push(deleteArgs.deletedRecords[parseInt(a.toString(), 10)]);
15589
15596
  }
15590
15597
  }
15591
15598
  const promise = this.parent.dataModule.dataManager.saveChanges(editParams, fields.id, this.getTable(), this.getQuery());
15592
- this.parent.eventBase.selectWorkCellByTime(deleteArgs.deletedRecords);
15599
+ const cloneEvent = extend({}, deleteArgs.deletedRecords[deleteArgs.deletedRecords.length - 1], null, true);
15600
+ this.parent.eventBase.selectWorkCellByTime([this.parent.eventBase.processTimezone(cloneEvent)]);
15593
15601
  const crudArgs = {
15594
15602
  requestType: 'eventRemoved', cancel: false, data: deleteArgs.deletedRecords, promise: promise, editParams: editParams
15595
15603
  };
@@ -25468,9 +25476,11 @@ class Month extends ViewBase {
25468
25476
  }
25469
25477
  }
25470
25478
  getMonthStart(currentDate) {
25471
- const useDisplayDate = this.parent.currentView === 'Month' && !isNullOrUndefined(this.parent.activeViewOptions.displayDate) && (this.parent.uiStateValues.isCustomMonth || this.isCustomRange());
25479
+ const useDisplayDate = this.parent.currentView === 'Month' && !isNullOrUndefined(this.parent.activeViewOptions.displayDate) && !(this.parent.uiStateValues.isSwipeScroll) &&
25480
+ (this.parent.uiStateValues.isCustomMonth || this.isCustomRange());
25472
25481
  const date = useDisplayDate ? this.parent.activeViewOptions.displayDate : !(this.parent.uiStateValues.isCustomMonth ||
25473
- this.isCustomRange()) && this.isCustomMonth() ? currentDate : this.parent.calendarUtil.firstDateOfMonth(currentDate);
25482
+ (!this.parent.uiStateValues.isSwipeScroll && this.isCustomRange())) && this.isCustomMonth() ? currentDate :
25483
+ this.parent.calendarUtil.firstDateOfMonth(currentDate);
25474
25484
  const monthStart = getWeekFirstDate(date, this.parent.activeViewOptions.firstDayOfWeek);
25475
25485
  return new Date(monthStart.getFullYear(), monthStart.getMonth(), monthStart.getDate());
25476
25486
  }