@colijnit/corecomponents_v12 258.1.2 → 258.1.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.
@@ -6555,9 +6555,14 @@ class CalendarTemplateComponent {
6555
6555
  }
6556
6556
  selectDate(day) {
6557
6557
  if (day) {
6558
- this.selectedDate = day;
6559
- this._fillDatesBetweenSelected();
6560
- if (this.doubleCalendar) {
6558
+ if (!this.doubleCalendar) {
6559
+ // Single calendar → select and close
6560
+ this.selectedDate = day;
6561
+ this.setAndClose();
6562
+ }
6563
+ else {
6564
+ this.selectedDate = day;
6565
+ this._fillDatesBetweenSelected();
6561
6566
  this.dateSelected.emit(new Date(this.selectedDate));
6562
6567
  }
6563
6568
  }
@@ -6757,8 +6762,8 @@ CalendarTemplateComponent.decorators = [
6757
6762
  </div>
6758
6763
  </div>
6759
6764
  <div class="calendar-action-buttons" *ngIf="showButtons">
6760
- <span class="set-and-close-button" (click)="setAndClose()">Instellen</span>
6761
- <span class="clear-date-button" (click)="clearDate()">Wissen</span>
6765
+ <span class="set-and-close-button" *ngIf="this.doubleCalendar" (click)="setAndClose()">Instellen</span>
6766
+ <span class="clear-date-button" *ngIf="this.selectedDate" (click)="clearDate()">Wissen</span>
6762
6767
  <span class="cancel-button" (click)="closeDate()">Annuleren</span>
6763
6768
  </div>
6764
6769
  </div>
@@ -12340,7 +12345,12 @@ class FilterItemComponent {
12340
12345
  let filterRange = [];
12341
12346
  this.collection.forEach((viewModel) => {
12342
12347
  if (viewModel.checked) {
12343
- filterRange.push(viewModel.code.toString());
12348
+ if (typeof viewModel.code === 'string') {
12349
+ filterRange.push(viewModel.code.toString());
12350
+ }
12351
+ else if (typeof viewModel.code === 'number') {
12352
+ filterRange.push(viewModel.code);
12353
+ }
12344
12354
  }
12345
12355
  });
12346
12356
  if (filterRange.length > 0) {
@@ -12471,11 +12481,11 @@ class FilterItemComponent {
12471
12481
  this._model = collectionModel;
12472
12482
  if (collectionModel !== null && collectionModel !== undefined && this.collection !== null && this.collection !== undefined) {
12473
12483
  this.collection.forEach((viewModel) => {
12474
- if (collectionModel.indexOf(viewModel.code.toString()) > -1) {
12475
- viewModel.checked = true;
12484
+ if (typeof collectionModel.indexOf(viewModel.code) === 'string') {
12485
+ viewModel.checked = collectionModel.indexOf(viewModel.code.toString()) > -1;
12476
12486
  }
12477
- else {
12478
- viewModel.checked = false;
12487
+ else if (typeof collectionModel.indexOf(viewModel.code) === 'number') {
12488
+ viewModel.checked = collectionModel.indexOf(viewModel.code) > -1;
12479
12489
  }
12480
12490
  });
12481
12491
  }