nuxeo-development-framework 5.6.5 → 5.6.7

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.
@@ -18701,6 +18701,7 @@
18701
18701
  }
18702
18702
  var _vals = Array.isArray(_values) ? _values : [_values];
18703
18703
  this.internalValue = _values;
18704
+ this.selectionModel.clear();
18704
18705
  (_b = this.selectionModel).select.apply(_b, __spreadArray([], __read(_vals)));
18705
18706
  this._isFieldDirty = true;
18706
18707
  this.cdr.markForCheck();
@@ -19334,7 +19335,7 @@
19334
19335
  useExisting: i0.forwardRef(function () { return AggregationCheckboxComponent; }),
19335
19336
  multi: true
19336
19337
  }
19337
- ], usesInheritance: true, ngImport: i0__namespace, template: "<ng-container *ngIf=\"options$ | async as options\">\r\n\t<field-header *ngIf=\"fieldConfig.label && !renderOptions?.hideLabel\" class=\"filter-checkbox__header\">\r\n\t\t<span>\r\n\t\t\t{{ fieldConfig.label | translate }}\r\n\t\t</span>\r\n\t\t<filter-options-sort *ngIf=\"renderOptions?.sort\" (sortChange)=\"sortChange($event)\"></filter-options-sort>\r\n\t</field-header>\r\n\r\n\t<filter-search-input\r\n\t\tclass=\"filter-checkbox__filter\"\r\n\t\t*ngIf=\"renderOptions?.filter\"\r\n\t\t[(searchText)]=\"searchText\"\r\n\t></filter-search-input>\r\n\r\n\t<filter-autocomplete-input\r\n\t\t*ngIf=\"renderOptions?.search\"\r\n\t\t[fieldConfig]=\"fieldConfig\"\r\n\t\t[language]=\"language\"\r\n\t\t[direction]=\"direction\"\r\n\t\t(searchChange)=\"emitValue($event)\"\r\n\t></filter-autocomplete-input>\r\n\r\n\t<ng-container *ngIf=\"options | filter: searchText | sortList: sort as filteredOptions\">\r\n\t\t<div class=\"filter-checkbox__wrapper\">\r\n\t\t\t<mat-checkbox\r\n\t\t\t\tclass=\"filter-checkbox__item\"\r\n\t\t\t\t*ngFor=\"let option of filteredOptions; index as index\"\r\n\t\t\t\t[checked]=\"selectionModel.isSelected(option.value)\"\r\n\t\t\t\t(change)=\"selectionModel.toggle(option.value)\"\r\n\t\t\t\t[class.checkedBox]=\"selectionModel.isSelected(option.value)\"\r\n\t\t\t\t[class.unCheckedBox]=\"!selectionModel.isSelected(option.value)\"\r\n\t\t\t\t[class.hidden]=\"renderOptions?.collapse && index + 1 > visibleItemsCount\"\r\n\t\t\t>\r\n\t\t\t\t<ng-container\r\n\t\t\t\t\t[ngTemplateOutlet]=\"contentTemplate || defaultTemplate\"\r\n\t\t\t\t\t[ngTemplateOutletContext]=\"{ $implicit: option, fieldConfig, aggregation }\"\r\n\t\t\t\t></ng-container>\r\n\r\n\t\t\t\t<ng-template #defaultTemplate>\r\n\t\t\t\t\t<filter-option-text\r\n\t\t\t\t\t\t[option]=\"option\"\r\n\t\t\t\t\t\t[language]=\"language\"\r\n\t\t\t\t\t\t[showCount]=\"renderOptions?.showTotal\"\r\n\t\t\t\t\t></filter-option-text>\r\n\t\t\t\t</ng-template>\r\n\t\t\t</mat-checkbox>\r\n\t\t</div>\r\n\r\n\t\t<filter-empty-message *ngIf=\"!filteredOptions.length\" class=\"filter-checkbox__empty\"></filter-empty-message>\r\n\r\n\t\t<filter-collapse-control\r\n\t\t\tclass=\"filter-checkbox__collapse\"\r\n\t\t\t*ngIf=\"renderOptions?.collapse\"\r\n\t\t\t[minCount]=\"expandedCount\"\r\n\t\t\t[(visibleCount)]=\"visibleItemsCount\"\r\n\t\t\t[totalItems]=\"filteredOptions.length\"\r\n\t\t></filter-collapse-control>\r\n\t</ng-container>\r\n</ng-container>\r\n", styles: [".filter-checkbox{display:var(--fc-display, block)}.filter-checkbox__wrapper{display:var(--fc-wrapper-display, flex);flex-direction:var(--fc-wrapper-direction, column)}.filter-checkbox__item{margin-bottom:var(--filter-row-margin-bottom, .3rem)}.filter-checkbox__item.hidden{display:none}.filter-checkbox__item .mat-checkbox-layout{display:flex}.filter-checkbox__item .mat-checkbox-layout .mat-checkbox-label{flex-grow:1}\n"], components: [{ type: FieldHeaderComponent, selector: "field-header" }, { type: FilterOptionsSortComponent, selector: "filter-options-sort", inputs: ["options", "sort"], outputs: ["sortChange"] }, { type: FilterSearchInputComponent, selector: "filter-search-input", inputs: ["searchText"], outputs: ["searchTextChange"] }, { type: FilterAutocompleteInputComponent, selector: "filter-autocomplete-input", inputs: ["direction", "language", "fieldConfig"], outputs: ["searchChange"] }, { type: i5__namespace$1.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "id", "labelPosition", "name", "required", "checked", "disabled", "indeterminate", "aria-describedby", "value"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { type: FilterOptionTextComponent, selector: "filter-option-text", inputs: ["option", "showCount", "language"] }, { type: FilterEmptyMessageComponent, selector: "filter-empty-message", inputs: ["message"] }, { type: FilterCollapseControlComponent, selector: "filter-collapse-control", inputs: ["minCount", "totalItems", "visibleCount"], outputs: ["visibleCountChange"] }], directives: [{ type: i4__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4__namespace$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i4__namespace$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }], pipes: { "async": i4__namespace$1.AsyncPipe, "translate": i1__namespace.TranslatePipe, "sortList": SortListPipe, "filter": FilterPipe }, changeDetection: i0__namespace.ChangeDetectionStrategy.Default, encapsulation: i0__namespace.ViewEncapsulation.None });
19338
+ ], usesInheritance: true, ngImport: i0__namespace, template: "<ng-container *ngIf=\"options$ | async as options\">\r\n\t<field-header *ngIf=\"fieldConfig.label && !renderOptions?.hideLabel\" class=\"filter-checkbox__header\">\r\n\t\t<span>\r\n\t\t\t{{ fieldConfig.label | translate }}\r\n\t\t</span>\r\n\t\t<filter-options-sort *ngIf=\"renderOptions?.sort\" (sortChange)=\"sortChange($event)\"></filter-options-sort>\r\n\t</field-header>\r\n\r\n\t<filter-search-input\r\n\t\tclass=\"filter-checkbox__filter\"\r\n\t\t*ngIf=\"renderOptions?.filter\"\r\n\t\t[(searchText)]=\"searchText\"\r\n\t></filter-search-input>\r\n\r\n\t<filter-autocomplete-input\r\n\t\t*ngIf=\"renderOptions?.search\"\r\n\t\t[fieldConfig]=\"fieldConfig\"\r\n\t\t[language]=\"language\"\r\n\t\t[direction]=\"direction\"\r\n\t\t(searchChange)=\"emitValue($event)\"\r\n\t></filter-autocomplete-input>\r\n\r\n\t<ng-container *ngIf=\"options | filter: searchText | sortList: sort as filteredOptions\">\r\n\t\t<div class=\"filter-checkbox__wrapper\">\r\n\t\t\t<mat-checkbox\r\n\t\t\t\tclass=\"filter-checkbox__item\"\r\n\t\t\t\t*ngFor=\"let option of filteredOptions; index as index ;\"\r\n\t\t\t\t[checked]=\"selectionModel.isSelected(option.value)\"\r\n\t\t\t\t(change)=\"selectionModel.toggle(option.value)\"\r\n\t\t\t\t[class.checkedBox]=\"selectionModel.isSelected(option.value)\"\r\n\t\t\t\t[class.unCheckedBox]=\"!selectionModel.isSelected(option.value)\"\r\n\t\t\t\t[class.hidden]=\"renderOptions?.collapse && index + 1 > visibleItemsCount\"\r\n\t\t\t>\r\n\t\t\t\t<ng-container\r\n\t\t\t\t\t[ngTemplateOutlet]=\"contentTemplate || defaultTemplate\"\r\n\t\t\t\t\t[ngTemplateOutletContext]=\"{ $implicit: option, fieldConfig, aggregation }\"\r\n\t\t\t\t></ng-container>\r\n\r\n\t\t\t\t<ng-template #defaultTemplate>\r\n\t\t\t\t\t<filter-option-text\r\n\t\t\t\t\t\t[option]=\"option\"\r\n\t\t\t\t\t\t[language]=\"language\"\r\n\t\t\t\t\t\t[showCount]=\"renderOptions?.showTotal\"\r\n\t\t\t\t\t></filter-option-text>\r\n\t\t\t\t</ng-template>\r\n\t\t\t</mat-checkbox>\r\n\t\t</div>\r\n\r\n\t\t<filter-empty-message *ngIf=\"!filteredOptions.length\" class=\"filter-checkbox__empty\"></filter-empty-message>\r\n\r\n\t\t<filter-collapse-control\r\n\t\t\tclass=\"filter-checkbox__collapse\"\r\n\t\t\t*ngIf=\"renderOptions?.collapse\"\r\n\t\t\t[minCount]=\"expandedCount\"\r\n\t\t\t[(visibleCount)]=\"visibleItemsCount\"\r\n\t\t\t[totalItems]=\"filteredOptions.length\"\r\n\t\t></filter-collapse-control>\r\n\t</ng-container>\r\n</ng-container>\r\n\r\n", styles: [".filter-checkbox{display:var(--fc-display, block)}.filter-checkbox__wrapper{display:var(--fc-wrapper-display, flex);flex-direction:var(--fc-wrapper-direction, column)}.filter-checkbox__item{margin-bottom:var(--filter-row-margin-bottom, .3rem)}.filter-checkbox__item.hidden{display:none}.filter-checkbox__item .mat-checkbox-layout{display:flex}.filter-checkbox__item .mat-checkbox-layout .mat-checkbox-label{flex-grow:1}\n"], components: [{ type: FieldHeaderComponent, selector: "field-header" }, { type: FilterOptionsSortComponent, selector: "filter-options-sort", inputs: ["options", "sort"], outputs: ["sortChange"] }, { type: FilterSearchInputComponent, selector: "filter-search-input", inputs: ["searchText"], outputs: ["searchTextChange"] }, { type: FilterAutocompleteInputComponent, selector: "filter-autocomplete-input", inputs: ["direction", "language", "fieldConfig"], outputs: ["searchChange"] }, { type: i5__namespace$1.MatCheckbox, selector: "mat-checkbox", inputs: ["disableRipple", "color", "tabIndex", "aria-label", "aria-labelledby", "id", "labelPosition", "name", "required", "checked", "disabled", "indeterminate", "aria-describedby", "value"], outputs: ["change", "indeterminateChange"], exportAs: ["matCheckbox"] }, { type: FilterOptionTextComponent, selector: "filter-option-text", inputs: ["option", "showCount", "language"] }, { type: FilterEmptyMessageComponent, selector: "filter-empty-message", inputs: ["message"] }, { type: FilterCollapseControlComponent, selector: "filter-collapse-control", inputs: ["minCount", "totalItems", "visibleCount"], outputs: ["visibleCountChange"] }], directives: [{ type: i4__namespace$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4__namespace$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i4__namespace$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }], pipes: { "async": i4__namespace$1.AsyncPipe, "translate": i1__namespace.TranslatePipe, "sortList": SortListPipe, "filter": FilterPipe }, changeDetection: i0__namespace.ChangeDetectionStrategy.Default, encapsulation: i0__namespace.ViewEncapsulation.None });
19338
19339
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: AggregationCheckboxComponent, decorators: [{
19339
19340
  type: i0.Component,
19340
19341
  args: [{
@@ -21158,6 +21159,7 @@
21158
21159
  return field === null || field === void 0 ? void 0 : field.fieldKey;
21159
21160
  };
21160
21161
  AggregationGroupComponent.prototype.writeValue = function (value) {
21162
+ var _a;
21161
21163
  if (value) {
21162
21164
  var _values = this._getValues(value);
21163
21165
  if (___default["default"].isEqual(_values, this.internalValue)) {
@@ -21166,6 +21168,12 @@
21166
21168
  this.internalValue = _values;
21167
21169
  this.formItems.clear();
21168
21170
  this._prepareFormFields(this.internalValue);
21171
+ return;
21172
+ }
21173
+ else if (!!((_a = this.internalValue) === null || _a === void 0 ? void 0 : _a.length)) {
21174
+ this.internalValue = [];
21175
+ this._resetFormArray();
21176
+ this._prepareFormFields(this.internalValue);
21169
21177
  }
21170
21178
  };
21171
21179
  AggregationGroupComponent.prototype.ngOnInit = function () {
@@ -21189,7 +21197,6 @@
21189
21197
  var _a;
21190
21198
  var items = ((_a = this.options) === null || _a === void 0 ? void 0 : _a.aggregations) || [];
21191
21199
  if (!!items.length) {
21192
- this.formItems.clear();
21193
21200
  items.forEach(function (item) {
21194
21201
  _this.formItems.push(new i2.FormControl(values));
21195
21202
  });
@@ -21208,6 +21215,10 @@
21208
21215
  var _a;
21209
21216
  return Array.isArray(values) ? values : ((_a = values) === null || _a === void 0 ? void 0 : _a.value) || [];
21210
21217
  };
21218
+ AggregationGroupComponent.prototype._resetFormArray = function () {
21219
+ this.formItems = new i2.FormArray([]);
21220
+ this.formGroup.setControl('items', this.formItems);
21221
+ };
21211
21222
  return AggregationGroupComponent;
21212
21223
  }(BaseCustomField));
21213
21224
  AggregationGroupComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: AggregationGroupComponent, deps: null, target: i0__namespace.ɵɵFactoryTarget.Component });
@@ -26872,11 +26883,13 @@
26872
26883
  _this.chartObj = new Chart.Chart(ctx, options);
26873
26884
  }
26874
26885
  else {
26875
- _this.chartObj.chart.data = chartData;
26886
+ _this.chartObj.data = chartData;
26887
+ // this.chartObj.chart.data = chartData;
26876
26888
  _this.chartObj.update();
26877
26889
  }
26878
26890
  }
26879
26891
  else {
26892
+ _this.isFetching = false;
26880
26893
  // const ctx = this.chart.nativeElement.getContext('2d');
26881
26894
  // let noOptions = {
26882
26895
  // type: options.type,
@@ -26917,7 +26930,7 @@
26917
26930
  _this.isFetching = false;
26918
26931
  }
26919
26932
  else {
26920
- _this.chartObj.chart.data = chartData;
26933
+ _this.chartObj.data = chartData;
26921
26934
  _this.chartObj.update();
26922
26935
  _this.isFetching = false;
26923
26936
  }
@@ -47452,11 +47465,11 @@
47452
47465
  var value = ___default["default"].cloneDeep(config);
47453
47466
  this._checkConfigChange(value);
47454
47467
  this._configSubject.next(value);
47455
- if (value === null || value === void 0 ? void 0 : value.activeQuery) {
47468
+ if ((value === null || value === void 0 ? void 0 : value.activeQuery) && !!Object.keys(value === null || value === void 0 ? void 0 : value.activeQuery).length) {
47456
47469
  this._updateActiveQuery(value === null || value === void 0 ? void 0 : value.activeQuery);
47457
47470
  this._filtersCriteriaSubject.next(this._prepareMappedQuery(value === null || value === void 0 ? void 0 : value.activeQuery, this.filtersConfig.mode));
47458
47471
  }
47459
- else if (!!Object.keys(this.activeQuery).length) {
47472
+ else if (!this.activeQuery || Object.keys(this.activeQuery).length == 0) {
47460
47473
  this._resetQueryAndFiltersCriteria();
47461
47474
  }
47462
47475
  this.isPanelOpened = false;