@acorex/components 3.0.42 → 3.0.46
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/acorex-components.metadata.json +1 -1
- package/bundles/acorex-components.umd.js +55 -34
- package/bundles/acorex-components.umd.js.map +1 -1
- package/bundles/acorex-components.umd.min.js +1 -1
- package/bundles/acorex-components.umd.min.js.map +1 -1
- package/esm2015/lib/checkbox/checkbox.component.js +17 -17
- package/esm2015/lib/date-picker/date-picker.component.js +5 -4
- package/esm2015/lib/number-box/number-box.component.js +16 -6
- package/esm2015/lib/query-builder/query-builder-group.component.js +2 -2
- package/esm2015/lib/query-builder/query-builder.service.js +4 -4
- package/esm2015/lib/selectbox/selectbox.component.js +6 -3
- package/esm2015/lib/tree-view/tree-view.component.js +12 -4
- package/esm5/lib/checkbox/checkbox.component.js +17 -18
- package/esm5/lib/date-picker/date-picker.component.js +5 -4
- package/esm5/lib/number-box/number-box.component.js +16 -6
- package/esm5/lib/query-builder/query-builder-group.component.js +2 -2
- package/esm5/lib/query-builder/query-builder.service.js +4 -4
- package/esm5/lib/selectbox/selectbox.component.js +6 -3
- package/esm5/lib/tree-view/tree-view.component.js +12 -4
- package/fesm2015/acorex-components.js +55 -33
- package/fesm2015/acorex-components.js.map +1 -1
- package/fesm5/acorex-components.js +55 -34
- package/fesm5/acorex-components.js.map +1 -1
- package/lib/number-box/number-box.component.d.ts +1 -0
- package/lib/tree-view/tree-view.component.d.ts +1 -0
- package/package.json +1 -1
|
@@ -3729,7 +3729,7 @@
|
|
|
3729
3729
|
return this._value;
|
|
3730
3730
|
},
|
|
3731
3731
|
set: function (v) {
|
|
3732
|
-
if (v != this._value
|
|
3732
|
+
if (v != this._value && v !== undefined) {
|
|
3733
3733
|
var old = this._value;
|
|
3734
3734
|
this._value = v;
|
|
3735
3735
|
this.valueChange.emit(v);
|
|
@@ -3754,21 +3754,20 @@
|
|
|
3754
3754
|
}
|
|
3755
3755
|
};
|
|
3756
3756
|
AXCheckBoxComponent.prototype.handleClick = function (e) {
|
|
3757
|
-
|
|
3758
|
-
|
|
3759
|
-
//
|
|
3760
|
-
|
|
3761
|
-
|
|
3762
|
-
|
|
3763
|
-
|
|
3764
|
-
|
|
3765
|
-
|
|
3766
|
-
|
|
3767
|
-
|
|
3768
|
-
|
|
3769
|
-
|
|
3770
|
-
|
|
3771
|
-
}, 100);
|
|
3757
|
+
e.preventDefault();
|
|
3758
|
+
e.stopPropagation();
|
|
3759
|
+
// setTimeout(() => {
|
|
3760
|
+
if (!this.disabled && !this.readonly) {
|
|
3761
|
+
//TODO: check intermddiate;
|
|
3762
|
+
this.value = !this.value;
|
|
3763
|
+
this.onClick.emit({
|
|
3764
|
+
component: this,
|
|
3765
|
+
htmlElement: this.ref.nativeElement,
|
|
3766
|
+
htmlEvent: e,
|
|
3767
|
+
value: this.value
|
|
3768
|
+
});
|
|
3769
|
+
}
|
|
3770
|
+
// }, 100);
|
|
3772
3771
|
};
|
|
3773
3772
|
AXCheckBoxComponent.ctorParameters = function () { return [
|
|
3774
3773
|
{ type: core.ChangeDetectorRef },
|
|
@@ -3822,7 +3821,7 @@
|
|
|
3822
3821
|
AXCheckBoxComponent = __decorate([
|
|
3823
3822
|
core.Component({
|
|
3824
3823
|
selector: 'ax-check-box',
|
|
3825
|
-
template: "<!-- <label class=\"ax checkbox {{size}}\" for=\"{{uid}}\" [ngClass]=\"{ 'disabled': disabled, 'readonly': readonly }\"\r\n (click)=\"handleClick($event)\">\r\n {{ label }}\r\n <input #input type=\"checkbox\" id=\"{{uid}}\" [readonly]=\"readonly\" [checked]=\"value\"\r\n [disabled]=\"disabled || readonly\" />\r\n <span class=\"checkmark\" [ngClass]=\"{'indeterminate': indeterminate && value == null}\"></span>\r\n\r\n</label> -->\r\n\r\n
|
|
3824
|
+
template: "<!-- <label class=\"ax checkbox {{size}}\" for=\"{{uid}}\" [ngClass]=\"{ 'disabled': disabled, 'readonly': readonly }\"\r\n (click)=\"handleClick($event)\">\r\n {{ label }}\r\n <input #input type=\"checkbox\" id=\"{{uid}}\" [readonly]=\"readonly\" [checked]=\"value\"\r\n [disabled]=\"disabled || readonly\" />\r\n <span class=\"checkmark\" [ngClass]=\"{'indeterminate': indeterminate && value == null}\"></span>\r\n\r\n</label> -->\r\n\r\n\r\n<!-- [(ngModel)]=\"value\" -->\r\n<!-- (click)=\"handleClick($event)\" -->\r\n\r\n<label class=\"ax-checkbox-container\" for=\"{{uid}}\" [ngClass]=\"{ 'disabled': disabled, 'readonly': readonly }\">\r\n\r\n <input #input class=\"ax-checkbox\" type=\"checkbox\" id=\"{{uid}}\" [readonly]=\"readonly\" [class.checked]=\"value\"\r\n [checked]=\"value\" [ngClass]=\"{'indeterminate': indeterminate && value == null}\" (click)=\"handleClick($event)\"\r\n [disabled]=\"disabled || readonly\" />\r\n\r\n\r\n <span>{{ label ? label : ' ' }}</span>\r\n</label>",
|
|
3826
3825
|
encapsulation: core.ViewEncapsulation.None,
|
|
3827
3826
|
changeDetection: core.ChangeDetectionStrategy.OnPush
|
|
3828
3827
|
}),
|
|
@@ -5765,8 +5764,9 @@
|
|
|
5765
5764
|
if (_this.showToday && !_this.value) {
|
|
5766
5765
|
_this.selectToday();
|
|
5767
5766
|
}
|
|
5768
|
-
|
|
5769
|
-
|
|
5767
|
+
console.log(Boolean(_this.dropdown.dropdownWidth > 200));
|
|
5768
|
+
if (_this.dropdown.dropdownWidth > 200) {
|
|
5769
|
+
_this.dropdown.dropdownWidth = 250;
|
|
5770
5770
|
}
|
|
5771
5771
|
_this.cdr.markForCheck();
|
|
5772
5772
|
});
|
|
@@ -6394,7 +6394,7 @@
|
|
|
6394
6394
|
AXDatePickerComponent = AXDatePickerComponent_1 = __decorate([
|
|
6395
6395
|
core.Component({
|
|
6396
6396
|
selector: 'ax-date-picker',
|
|
6397
|
-
template: "<ax-drop-down [readonly]=\"readonly\" [size]=\"size\" [showDropDownButton]=\"false\" icon=\"far fa-calendar-alt\" #dropdown maxHeight=\"unset\">\r\n <ng-container start>\r\n <ng-content select=\"[start]\">\r\n </ng-content>\r\n </ng-container>\r\n <ng-container header>\r\n <ax-text-box #input [textAlign]=\"textAlign\" [(value)]=\"text\" [readonly]=\"false\" [textMask]=\"dateType\" [disabled]=\"disabled\" [placeholder]=\"placeholder\" [size]=\"size\" (onkey)=\"handleKeyPress($event)\" (onFocus)=\"handleInputFocus()\" (click)=\"handleClick()\"\r\n (onBlur)=\"handleInputBlur()\" (onValueChanged)=\"textChange($event)\"></ax-text-box>\r\n </ng-container>\r\n <ng-container panel>\r\n <ax-calendar-box *ngIf=\"_renderPicker\" [showTodayButton]=\"showTodayButton\" [selectableHoliday]=\"selectableHoliday\" [min]=\"min\" [max]=\"max\" [size]=\"size\" (onClick)=\"onClick($event)\" (onValueChanged)=\"onDateChange($event)\" [type]=\"type\" [(value)]=\"value\"\r\n [dayStyle]=\"dayStyle\">\r\n </ax-calendar-box>\r\n </ng-container>\r\n <ng-container end>\r\n <ax-button end *ngIf=\"allowClear && value\" [disabled]=\"disabled\" icon=\"far fa-times icon\" type=\"blank danger\" (click)=\"clear()\" [size]=\"size\" [tabIndex]=\"-1\">\r\n </ax-button>\r\n <ax-button end icon=\"far fa-calendar-alt icon\" type=\"light blank\" (click)=\"handleButtonClick()\" [disabled]=\"disabled\" [size]=\"size\" [tabIndex]=\"-1\"></ax-button>\r\n <ng-content select=\"[end]\">\r\n </ng-content>\r\n </ng-container>\r\n\r\n</ax-drop-down>",
|
|
6397
|
+
template: "<ax-drop-down [readonly]=\"readonly\" [fitParent]=\"true\" [size]=\"size\" [showDropDownButton]=\"false\" icon=\"far fa-calendar-alt\" #dropdown maxHeight=\"unset\">\r\n <ng-container start>\r\n <ng-content select=\"[start]\">\r\n </ng-content>\r\n </ng-container>\r\n <ng-container header>\r\n <ax-text-box #input [textAlign]=\"textAlign\" [(value)]=\"text\" [readonly]=\"false\" [textMask]=\"dateType\" [disabled]=\"disabled\" [placeholder]=\"placeholder\" [size]=\"size\" (onkey)=\"handleKeyPress($event)\" (onFocus)=\"handleInputFocus()\" (click)=\"handleClick()\"\r\n (onBlur)=\"handleInputBlur()\" (onValueChanged)=\"textChange($event)\"></ax-text-box>\r\n </ng-container>\r\n <ng-container panel>\r\n <ax-calendar-box *ngIf=\"_renderPicker\" [showTodayButton]=\"showTodayButton\" [selectableHoliday]=\"selectableHoliday\" [min]=\"min\" [max]=\"max\" [size]=\"size\" (onClick)=\"onClick($event)\" (onValueChanged)=\"onDateChange($event)\" [type]=\"type\" [(value)]=\"value\"\r\n [dayStyle]=\"dayStyle\">\r\n </ax-calendar-box>\r\n </ng-container>\r\n <ng-container end>\r\n <ax-button end *ngIf=\"allowClear && value\" [disabled]=\"disabled\" icon=\"far fa-times icon\" type=\"blank danger\" (click)=\"clear()\" [size]=\"size\" [tabIndex]=\"-1\">\r\n </ax-button>\r\n <ax-button end icon=\"far fa-calendar-alt icon\" type=\"light blank\" (click)=\"handleButtonClick()\" [disabled]=\"disabled\" [size]=\"size\" [tabIndex]=\"-1\"></ax-button>\r\n <ng-content select=\"[end]\">\r\n </ng-content>\r\n </ng-container>\r\n\r\n</ax-drop-down>",
|
|
6398
6398
|
encapsulation: core.ViewEncapsulation.None,
|
|
6399
6399
|
providers: [{ provide: AXValidatableComponent, useExisting: AXDatePickerComponent_1 }],
|
|
6400
6400
|
host: { style: 'width: 100%' },
|
|
@@ -7778,7 +7778,7 @@
|
|
|
7778
7778
|
});
|
|
7779
7779
|
AXNumberBoxComponent.prototype.calcSeparator = function (num) {
|
|
7780
7780
|
if (this.showSeparator) {
|
|
7781
|
-
return num +
|
|
7781
|
+
return num + +(num / 3);
|
|
7782
7782
|
}
|
|
7783
7783
|
else {
|
|
7784
7784
|
return num;
|
|
@@ -7803,9 +7803,11 @@
|
|
|
7803
7803
|
if (this.disabled === false) {
|
|
7804
7804
|
if (this.scrollWeel === true) {
|
|
7805
7805
|
setTimeout(function () {
|
|
7806
|
-
_this.
|
|
7807
|
-
_this.
|
|
7808
|
-
|
|
7806
|
+
if (_this.readonly === false) {
|
|
7807
|
+
_this.input.nativeElement.addEventListener('wheel', function (e) {
|
|
7808
|
+
_this.handleWheel(e);
|
|
7809
|
+
});
|
|
7810
|
+
}
|
|
7809
7811
|
}, 500);
|
|
7810
7812
|
}
|
|
7811
7813
|
}
|
|
@@ -8216,6 +8218,14 @@
|
|
|
8216
8218
|
}
|
|
8217
8219
|
}
|
|
8218
8220
|
};
|
|
8221
|
+
AXNumberBoxComponent.prototype.handleInputBlur = function (e) {
|
|
8222
|
+
this.checkMinMax(this.textValue);
|
|
8223
|
+
this.onBlur.emit({
|
|
8224
|
+
component: this,
|
|
8225
|
+
htmlElement: this.ref.nativeElement,
|
|
8226
|
+
htmlEvent: e
|
|
8227
|
+
});
|
|
8228
|
+
};
|
|
8219
8229
|
var AXNumberBoxComponent_1;
|
|
8220
8230
|
AXNumberBoxComponent.ctorParameters = function () { return [
|
|
8221
8231
|
{ type: core.ChangeDetectorRef },
|
|
@@ -8268,7 +8278,7 @@
|
|
|
8268
8278
|
AXNumberBoxComponent = AXNumberBoxComponent_1 = __decorate([
|
|
8269
8279
|
core.Component({
|
|
8270
8280
|
selector: 'ax-number-box',
|
|
8271
|
-
template: "<div class=\"ax form-item\" [class.disabled]=\"disabled\" [attr.id]=\"uid\" #fc>\r\n <div class=\"ax items-wrapper\">\r\n <ng-content select=\"[start]\">\r\n </ng-content>\r\n <ax-button icon=\"far fa-plus\" type=\"success blank\" (click)=\"upStepHandel()\" [disabled]=\"disabled\" *ngIf=\"showDoubleCounter\"></ax-button>\r\n </div>\r\n <div class=\"content\" #content>\r\n <div class=\"ax form-control input {{size}}\" [class.disabled]=\"disabled\" [class.readonly]=\"readonly\"\r\n [class.icon]=\"icon\">\r\n <input #input type=\"text\" class=\"ax {{size}}\" [maxlength]=\"calcSeparator(maxLength)\" [(ngModel)]=\"textValue\" placeholder=\"{{placeholder}}\"\r\n [readonly]=\"readonly\" [disabled]=\"disabled\" [ngClass]=\"setTextAlign()\"\r\n [class.clear]=\"value && allowClear\" (focus)=\"handleInputFocus($event)\" (blur)=\"handleInputBlur($event)\"\r\n (keypress)=\"handleKeyPress($event)\" (ngModelChange)=\"this.userQuestionUpdate.next($event)\"\r\n (keydown)=\"handleKeyDown($event)\" (click)=\"handleClick()\" (keyup)=\"handleKeyUp($event)\">\r\n <i class=\"{{icon}}\" *ngIf=\"icon\"></i>\r\n </div>\r\n </div>\r\n <div class=\"ax items-wrapper\">\r\n <ax-button *ngIf=\"value && allowClear\" [disabled]=\"disabled\" icon=\"far fa-times\" type=\"danger blank\"\r\n (click)=\"clear()\"></ax-button>\r\n <ax-button icon=\"far fa-minus\" type=\"danger blank\" (click)=\"downStepHandel()\" [disabled]=\"disabled\" *ngIf=\"showDoubleCounter\"></ax-button>\r\n <ng-content select=\"[end]\">\r\n </ng-content>\r\n <div class=\"arrow-number\" *ngIf=\"showCounter && !showDoubleCounter\" >\r\n <ax-button type=\"light blank\" [disabled]=\"disabled\" icon=\"fas fa-angle-up\" [size]=\"size\"\r\n (mousedown)=\"upStepHandel()\" (mouseup)=\"delaySearch()\" [tabIndex]=\"-1\"></ax-button>\r\n <ax-button type=\"light blank\" [disabled]=\"disabled\" icon=\"fas fa-angle-down\" [size]=\"size\"\r\n (mousedown)=\"downStepHandel()\" (mouseup)=\"delaySearch()\" [tabIndex]=\"-1\"></ax-button>\r\n </div>\r\n </div>\r\n\r\n</div>\r\n",
|
|
8281
|
+
template: "<div class=\"ax form-item\" [class.disabled]=\"disabled\" [attr.id]=\"uid\" #fc>\r\n <div class=\"ax items-wrapper\">\r\n <ng-content select=\"[start]\">\r\n </ng-content>\r\n <ax-button icon=\"far fa-plus\" type=\"success blank\" (click)=\"upStepHandel()\" [disabled]=\"disabled\" *ngIf=\"showDoubleCounter\"></ax-button>\r\n </div>\r\n <div class=\"content\" #content>\r\n <div class=\"ax form-control input {{size}}\" [class.disabled]=\"disabled\" [class.readonly]=\"readonly\"\r\n [class.icon]=\"icon\">\r\n <input #input type=\"text\" class=\"ax {{size}}\" [maxlength]=\"calcSeparator(maxLength)\" [(ngModel)]=\"textValue\" placeholder=\"{{placeholder}}\"\r\n [readonly]=\"readonly\" [disabled]=\"disabled\" [ngClass]=\"setTextAlign()\"\r\n [class.clear]=\"value && allowClear\" (focus)=\"handleInputFocus($event)\" (blur)=\"handleInputBlur($event)\"\r\n (keypress)=\"handleKeyPress($event)\" (ngModelChange)=\"this.userQuestionUpdate.next($event)\"\r\n (keydown)=\"handleKeyDown($event)\" (click)=\"handleClick()\" (keyup)=\"handleKeyUp($event)\">\r\n <i class=\"{{icon}}\" *ngIf=\"icon\"></i>\r\n </div>\r\n </div>\r\n <div class=\"ax items-wrapper\">\r\n <ax-button *ngIf=\"value && allowClear\" [disabled]=\"disabled\" icon=\"far fa-times\" type=\"danger blank\"\r\n (click)=\"clear()\"></ax-button>\r\n <ax-button icon=\"far fa-minus\" type=\"danger blank\" (click)=\"downStepHandel()\" [disabled]=\"disabled\" *ngIf=\"showDoubleCounter\"></ax-button>\r\n <ng-content select=\"[end]\">\r\n </ng-content>\r\n <div class=\"arrow-number\" *ngIf=\"showCounter && !showDoubleCounter && !readonly\" >\r\n <ax-button type=\"light blank\" [disabled]=\"disabled\" icon=\"fas fa-angle-up\" [size]=\"size\"\r\n (mousedown)=\"upStepHandel()\" (mouseup)=\"delaySearch()\" [tabIndex]=\"-1\"></ax-button>\r\n <ax-button type=\"light blank\" [disabled]=\"disabled\" icon=\"fas fa-angle-down\" [size]=\"size\"\r\n (mousedown)=\"downStepHandel()\" (mouseup)=\"delaySearch()\" [tabIndex]=\"-1\"></ax-button>\r\n </div>\r\n </div>\r\n\r\n</div>\r\n",
|
|
8272
8282
|
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
|
8273
8283
|
host: { style: 'width: 100%' },
|
|
8274
8284
|
providers: [{ provide: AXValidatableComponent, useExisting: AXNumberBoxComponent_1 }]
|
|
@@ -8710,7 +8720,10 @@
|
|
|
8710
8720
|
v = [];
|
|
8711
8721
|
}
|
|
8712
8722
|
// const old = this.selectedItems;
|
|
8713
|
-
|
|
8723
|
+
var f = lodash.differenceBy(old, v, this.valueField);
|
|
8724
|
+
var s = lodash.differenceBy(v, old, this.valueField);
|
|
8725
|
+
// if (JSON.stringify(old) !== JSON.stringify(v)) {
|
|
8726
|
+
if (f.length != 0 || s.length != 0) {
|
|
8714
8727
|
this._selectedItems = this.mode == 'single' ? v.slice(0, 1) : __spread(new Set(v)); //[...new Set(v[0])] : [...new Set(v)];
|
|
8715
8728
|
this._selectedItems.forEach(function (c) { return (c.selected = true); });
|
|
8716
8729
|
this.selectedItemsChange.emit(this._selectedItems);
|
|
@@ -9617,7 +9630,7 @@
|
|
|
9617
9630
|
AXSelectBoxComponent = AXSelectBoxComponent_1 = __decorate([
|
|
9618
9631
|
core.Component({
|
|
9619
9632
|
selector: 'ax-select-box',
|
|
9620
|
-
template: "<ax-drop-down [size]=\"size\" [rtl]=\"rtl\" [showDropDownButton]=\"showDropDownButton\" [disabled]=\"disabled\"\r\n [readonly]=\"readonly\" #d (dropdownToggle)=\"dropdownToggleSelecBox($event)\">\r\n <ng-container start>\r\n <ng-content select=\"[start]\">\r\n </ng-content>\r\n </ng-container>\r\n <ng-container header>\r\n <div class=\"ax chips-container\" [horizontalScroll]=\"40\">\r\n <div class=\"chips\" [class.chips-blank]=\"mode === 'single'\" [title]=\"item[textField]\"\r\n *ngFor=\"let item of selectedItems\">\r\n <span class=\"chips-text\">\r\n {{item[textField]}}\r\n </span>\r\n <span class=\"close-icon\" (click)=\"handleItemRemoveClick(item)\"\r\n *ngIf=\"(readonly!=true || itemRemove ==true)&& disabled!=true && (allowNull==true || (selectedItems.length > 1))\">\r\n <i class=\"far fa-times-circle close\"></i>\r\n </span>\r\n </div>\r\n <div class=\"search-wrapper\" (click)=\"onTextBoxClick($event)\">\r\n <ax-text-box #textBoxSelectBox [textAlign]=\"textAlign\"\r\n [placeholder]=\"selectedItems.length == 0 ? placeholder : ''\" [readonly]=\"readonly\"\r\n [disabled]=\"disabled\" (onkey)=\"handleKeyEvent($event)\" [size]=\"size\"\r\n (onFocus)=\"onFocusTextBox($event)\">\r\n </ax-text-box>\r\n </div>\r\n </div>\r\n </ng-container>\r\n <ng-container end>\r\n <ng-content select=\"[end]\">\r\n </ng-content>\r\n </ng-container>\r\n\r\n <ng-container panel>\r\n <div *ngIf=\"allowSearch\" class=\"search-wrapper\" style=\"padding: 0.7em;\">\r\n <ax-search-box #serchBox [(value)]=\"text\" (onkey)=\"handleKeyEventSearch($event)\"\r\n (textChanged)=\"textChanged($event)\" (onButtonClick)=\"textChanged($event)\">\r\n </ax-search-box>\r\n </div>\r\n <div class=\"ax list-container\">\r\n <div #listContainer style=\"max-height: 300px;overflow-y: auto;width: 100%;\" (scroll)=\"scrolled($event)\">\r\n <ng-container *ngIf=\"getItems().length>0; then thenTemplate; else elseTemplate\"></ng-container>\r\n <ng-template #thenTemplate>\r\n <div class=\"list-item\" *ngFor=\"let item of getItems();let i = index\"\r\n [class.focused]=\"i==currentfocusedIndex\" [class.selected]=\"isItemSelected(item)\"\r\n (click)=\"handleItemClick($event,item)\">\r\n <div style=\"display: flex;\">\r\n <ax-check-box *ngIf=\"showCheckBox\" [size]=\"size\" [value]=\"isItemSelected(item)\"\r\n [disabled]=\"!allowNull && selectedItems.length === 1 && isItemSelected(item)\">\r\n </ax-check-box>\r\n <ng-container *ngIf=\"rowTemplate; else elseTemplate\">\r\n <div style=\"white-space: nowrap;text-overflow: ellipsis;overflow: hidden;\"\r\n [title]=\"item[textField]\"\r\n [ngStyle]=\"(showCheckBox) ? {'padding-inline-start': '0.5rem'}:''\">\r\n <ng-container *ngTemplateOutlet=\"rowTemplate; context:{ $implicit: item }\">\r\n </ng-container>\r\n </div>\r\n\r\n </ng-container>\r\n <ng-template #elseTemplate>\r\n <div style=\"white-space: nowrap;text-overflow: ellipsis;overflow: hidden;\"\r\n [title]=\"item[textField]\"\r\n [ngStyle]=\"(showCheckBox) ? {'padding-inline-start': '0.5rem'}:''\">\r\n {{ item[textField] }}\r\n </div>\r\n </ng-template>\r\n\r\n </div>\r\n\r\n </div>\r\n\r\n </ng-template>\r\n <div *ngIf=\"showLoading\" class=\"ax-pad-sm\" style=\"text-align: center;\">\r\n <i class=\"far fa-spinner-third fa-pulse fa-2x\" style=\"color: var(--ax-primary-color);\"></i>\r\n\r\n </div>\r\n <!-- <ax-loading-indicator ></ax-loading-indicator> -->\r\n <ng-template #elseTemplate>\r\n <ng-container *ngIf=\"showLoading == true; then searchTemplate else noDataTemplate\"></ng-container>\r\n <ng-template #searchTemplate>\r\n <div class=\"list-item\">\r\n {{'common.searching' | trans}}\r\n </div>\r\n </ng-template>\r\n <ng-template #noDataTemplate>\r\n <div class=\"list-item\">\r\n {{'common.noDataFound' | trans}}\r\n </div>\r\n </ng-template>\r\n\r\n </ng-template>\r\n\r\n </div>\r\n\r\n </div>\r\n </ng-container>\r\n\r\n</ax-drop-down>",
|
|
9633
|
+
template: "<ax-drop-down [size]=\"size\" [rtl]=\"rtl\" [showDropDownButton]=\"showDropDownButton\" [disabled]=\"disabled\"\r\n [readonly]=\"readonly\" #d (dropdownToggle)=\"dropdownToggleSelecBox($event)\">\r\n <ng-container start>\r\n <ng-content select=\"[start]\">\r\n </ng-content>\r\n </ng-container>\r\n <ng-container header>\r\n <div class=\"ax chips-container\" [horizontalScroll]=\"40\">\r\n <div class=\"chips\" [class.chips-blank]=\"mode === 'single'\" [title]=\"item[textField]\"\r\n *ngFor=\"let item of selectedItems\">\r\n <span class=\"chips-text\">\r\n {{item[textField]}}\r\n </span>\r\n <span class=\"close-icon\" (click)=\"handleItemRemoveClick(item)\"\r\n *ngIf=\"(readonly!=true || itemRemove ==true)&& disabled!=true && (allowNull==true || (selectedItems.length > 1))\">\r\n <i class=\"far fa-times-circle close\"></i>\r\n </span>\r\n </div>\r\n <div class=\"search-wrapper\" (click)=\"onTextBoxClick($event)\">\r\n <ax-text-box #textBoxSelectBox [textAlign]=\"textAlign\"\r\n [placeholder]=\"selectedItems.length == 0 ? placeholder : ''\" [readonly]=\"readonly\"\r\n [disabled]=\"disabled\" (onkey)=\"handleKeyEvent($event)\" [size]=\"size\"\r\n (onFocus)=\"onFocusTextBox($event)\">\r\n </ax-text-box>\r\n </div>\r\n </div>\r\n </ng-container>\r\n <ng-container end>\r\n <ng-content select=\"[end]\">\r\n </ng-content>\r\n </ng-container>\r\n\r\n <ng-container panel>\r\n <div *ngIf=\"allowSearch\" class=\"search-wrapper\" style=\"padding: 0.7em;\">\r\n <ax-search-box #serchBox [(value)]=\"text\" (onkey)=\"handleKeyEventSearch($event)\"\r\n (textChanged)=\"textChanged($event)\" (onButtonClick)=\"textChanged($event)\">\r\n </ax-search-box>\r\n </div>\r\n <div class=\"ax list-container\">\r\n <div #listContainer style=\"max-height: 300px;overflow-y: auto;width: 100%;\" (scroll)=\"scrolled($event)\">\r\n <ng-container *ngIf=\"getItems().length>0; then thenTemplate; else elseTemplate\"></ng-container>\r\n <ng-template #thenTemplate>\r\n <div class=\"list-item\" *ngFor=\"let item of getItems();let i = index\"\r\n [class.focused]=\"i==currentfocusedIndex\" [class.selected]=\"isItemSelected(item)\"\r\n (click)=\"handleItemClick($event,item)\">\r\n <div style=\"display: flex;\">\r\n <ax-check-box *ngIf=\"showCheckBox\" [size]=\"size\" [value]=\"isItemSelected(item)\"\r\n [disabled]=\"!allowNull && selectedItems.length === 1 && isItemSelected(item)\"\r\n (onClick)=\"handleItemClick($event,item)\">\r\n </ax-check-box>\r\n <ng-container *ngIf=\"rowTemplate; else elseTemplate\">\r\n <div style=\"white-space: nowrap;text-overflow: ellipsis;overflow: hidden;\"\r\n [title]=\"item[textField]\"\r\n [ngStyle]=\"(showCheckBox) ? {'padding-inline-start': '0.5rem'}:''\">\r\n <ng-container *ngTemplateOutlet=\"rowTemplate; context:{ $implicit: item }\">\r\n </ng-container>\r\n </div>\r\n\r\n </ng-container>\r\n <ng-template #elseTemplate>\r\n <div style=\"white-space: nowrap;text-overflow: ellipsis;overflow: hidden;\"\r\n [title]=\"item[textField]\"\r\n [ngStyle]=\"(showCheckBox) ? {'padding-inline-start': '0.5rem'}:''\">\r\n {{ item[textField] }}\r\n </div>\r\n </ng-template>\r\n\r\n </div>\r\n\r\n </div>\r\n\r\n </ng-template>\r\n <div *ngIf=\"showLoading\" class=\"ax-pad-sm\" style=\"text-align: center;\">\r\n <i class=\"far fa-spinner-third fa-pulse fa-2x\" style=\"color: var(--ax-primary-color);\"></i>\r\n\r\n </div>\r\n <!-- <ax-loading-indicator ></ax-loading-indicator> -->\r\n <ng-template #elseTemplate>\r\n <ng-container *ngIf=\"showLoading == true; then searchTemplate else noDataTemplate\"></ng-container>\r\n <ng-template #searchTemplate>\r\n <div class=\"list-item\">\r\n {{'common.searching' | trans}}\r\n </div>\r\n </ng-template>\r\n <ng-template #noDataTemplate>\r\n <div class=\"list-item\">\r\n {{'common.noDataFound' | trans}}\r\n </div>\r\n </ng-template>\r\n\r\n </ng-template>\r\n\r\n </div>\r\n\r\n </div>\r\n </ng-container>\r\n\r\n</ax-drop-down>",
|
|
9621
9634
|
encapsulation: core.ViewEncapsulation.None,
|
|
9622
9635
|
changeDetection: core.ChangeDetectionStrategy.OnPush,
|
|
9623
9636
|
host: { style: 'width: 100%' },
|
|
@@ -10227,7 +10240,7 @@
|
|
|
10227
10240
|
return __generator(this, function (_d) {
|
|
10228
10241
|
switch (_d.label) {
|
|
10229
10242
|
case 0:
|
|
10230
|
-
|
|
10243
|
+
;
|
|
10231
10244
|
if (group.items.length > 0) {
|
|
10232
10245
|
query = ' ( ';
|
|
10233
10246
|
}
|
|
@@ -10286,7 +10299,7 @@
|
|
|
10286
10299
|
codeOperator = item.operator;
|
|
10287
10300
|
break;
|
|
10288
10301
|
}
|
|
10289
|
-
|
|
10302
|
+
;
|
|
10290
10303
|
query = query + ' ' + item.caption + ' ' + codeOperator + ' ' + item.text;
|
|
10291
10304
|
_d.label = 6;
|
|
10292
10305
|
case 6:
|
|
@@ -10329,7 +10342,7 @@
|
|
|
10329
10342
|
var query = '';
|
|
10330
10343
|
switch (type) {
|
|
10331
10344
|
case 'simple':
|
|
10332
|
-
|
|
10345
|
+
;
|
|
10333
10346
|
if (group.items.length > 0) {
|
|
10334
10347
|
query = ' ( ';
|
|
10335
10348
|
}
|
|
@@ -10471,7 +10484,7 @@
|
|
|
10471
10484
|
};
|
|
10472
10485
|
AXQueryBuilderGroupComponent.prototype.ruleChanged = function (e) {
|
|
10473
10486
|
var _this = this;
|
|
10474
|
-
|
|
10487
|
+
;
|
|
10475
10488
|
// this.group.queryString = this.qs.getQueryString(this.group, 'simple');
|
|
10476
10489
|
this.qs.getQueryStringSimple(this.group).then(function (c) {
|
|
10477
10490
|
_this.group.queryString = c;
|
|
@@ -14181,6 +14194,14 @@
|
|
|
14181
14194
|
flag: flag
|
|
14182
14195
|
});
|
|
14183
14196
|
};
|
|
14197
|
+
AXTreeViewComponent.prototype.nodeClick = function (item) {
|
|
14198
|
+
if (item[this.hasChildField] == true) {
|
|
14199
|
+
this.toggleNode(item, true);
|
|
14200
|
+
}
|
|
14201
|
+
else {
|
|
14202
|
+
this.internalSelectItem(item, true);
|
|
14203
|
+
}
|
|
14204
|
+
};
|
|
14184
14205
|
AXTreeViewComponent.prototype.toggleNode = function (item, flag) {
|
|
14185
14206
|
if (flag === void 0) { flag = false; }
|
|
14186
14207
|
//item[this.hasChildField] === false &&
|
|
@@ -14238,7 +14259,7 @@
|
|
|
14238
14259
|
_this.seletedKeyFields.forEach(function (n) {
|
|
14239
14260
|
if (n.includes(el[_this.keyField])) {
|
|
14240
14261
|
if (el[_this.hasChildField] == true) {
|
|
14241
|
-
if (_this.checkParents == false && _this.checkChilds == false) {
|
|
14262
|
+
if ((_this.checkParents == false && _this.checkChilds == false) || _this.checkChilds == false) {
|
|
14242
14263
|
//select parent when check child and check parent is false TODO check this Action
|
|
14243
14264
|
_this.selectItem(el);
|
|
14244
14265
|
}
|
|
@@ -14253,7 +14274,7 @@
|
|
|
14253
14274
|
}
|
|
14254
14275
|
else if (_this.selectedFieldName != null) {
|
|
14255
14276
|
if (el[_this.hasChildField] == true && el[_this.selectedFieldName] == true) {
|
|
14256
|
-
if (_this.checkParents == false && _this.checkChilds == false) {
|
|
14277
|
+
if ((_this.checkParents == false && _this.checkChilds == false) || _this.checkChilds == false) {
|
|
14257
14278
|
//select parent when check child and check parent is false TODO check this Action
|
|
14258
14279
|
_this.selectItem(el);
|
|
14259
14280
|
}
|
|
@@ -14665,7 +14686,7 @@
|
|
|
14665
14686
|
AXTreeViewComponent = __decorate([
|
|
14666
14687
|
core.Component({
|
|
14667
14688
|
selector: 'ax-tree-view',
|
|
14668
|
-
template: "<ul class=\"ax treeview {{size}}\">\r\n <ng-template #recursiveList let-list>\r\n <ng-container *ngFor=\"let item of list\">\r\n <li class=\"active {{item[hasChildField] ? '':'node'}}\" [class.bordered]=\"bordered\"
|
|
14689
|
+
template: "<ul class=\"ax treeview {{size}}\">\r\n <ng-template #recursiveList let-list>\r\n <ng-container *ngFor=\"let item of list\">\r\n <li class=\"active {{item[hasChildField] ? '':'node'}}\" [class.bordered]=\"bordered\"\r\n [class.selected]=\"item.select\" [draggable]=\"allowDrag\" (dragstart)=\"onDragStart($event, item)\"\r\n [attr.data-id]=\"item[keyField]\" (dragleave)=\"onDragEnd($event,item)\" (dragend)=drop($event)>\r\n <div axContextMenu [contextDataItem]=\"item\" [contextMenuItems]=\"contextMenuItems\" [contextMenu]=\"menu\"\r\n (onContextMenuItemClick)=\"handleOnContextMenuItem($event)\"\r\n style=\"display: flex; cursor: pointer;align-items: center;\">\r\n <div class=\"start-side\">\r\n <div *ngIf=\"item[hasChildField]\" class=\"collapse-icon\"\r\n (click)=\"handleOnNodeClick($event,item,true)\">\r\n <i class=\"fal\"\r\n [ngClass]=\"{'fa-minus': !!item.toggle , 'fa-plus': !item.toggle , 'fa-spinner fa-spin':item.loading }\"></i>\r\n </div>\r\n\r\n <ax-check-box *ngIf=\"showSelectBox\" [disabled]=\"item.disabledCheckBox\" [size]=\"size\"\r\n [indeterminate]=\"true\" [value]=\"item.select\" (onClick)=\"internalSelectItem(item)\">\r\n </ax-check-box>\r\n\r\n\r\n </div>\r\n <div class=\"text-list\" (click)=\"nodeClick(item)\" (dblclick)=\"itemdbClick($event,item)\">\r\n <ng-container *ngIf=\"nodeTemplate; else elseTemplate\">\r\n <ng-container *ngTemplateOutlet=\"nodeTemplate; context:{ $implicit: item }\"></ng-container>\r\n </ng-container>\r\n <ng-template #elseTemplate>\r\n {{item.title}}\r\n </ng-template>\r\n </div>\r\n </div>\r\n <ul *ngIf=\"item.loading\">\r\n <i class=\"far \"></i>\r\n </ul>\r\n <ul class=\"child\" *ngIf=\"item.toggle\" style=\"background-color: white !important;\">\r\n <ng-container *ngTemplateOutlet=\"recursiveList; context:{ $implicit: item.childeren }\">\r\n </ng-container>\r\n </ul>\r\n </li>\r\n </ng-container>\r\n </ng-template>\r\n <ng-container *ngTemplateOutlet=\"recursiveList; context:{ $implicit: list }\"></ng-container>\r\n</ul>\r\n\r\n<ax-context-menu #menu></ax-context-menu>",
|
|
14669
14690
|
encapsulation: core.ViewEncapsulation.None
|
|
14670
14691
|
}),
|
|
14671
14692
|
__metadata("design:paramtypes", [core.ElementRef])
|