@smartbit4all/ng-client 3.3.49 → 3.3.50
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/esm2020/lib/session/api/api/session.service.mjs +1 -1
- package/esm2020/lib/session/api/encoder.mjs +1 -1
- package/esm2020/lib/session/api/model/accountInfo.mjs +1 -1
- package/esm2020/lib/session/api/model/apiError.mjs +1 -1
- package/esm2020/lib/session/api/model/authenticationProviderData.mjs +1 -1
- package/esm2020/lib/session/api/model/getAuthenticationProvidersResponse.mjs +1 -1
- package/esm2020/lib/session/api/model/models.mjs +1 -1
- package/esm2020/lib/session/api/model/refreshSessionRequest.mjs +1 -1
- package/esm2020/lib/session/api/model/session.mjs +1 -1
- package/esm2020/lib/session/api/model/sessionInfoData.mjs +1 -1
- package/esm2020/lib/session/api/model/userActivityLog.mjs +1 -1
- package/esm2020/lib/session/api/param.mjs +1 -1
- package/esm2020/lib/session/api/variables.mjs +1 -1
- package/esm2020/lib/shared/shared.module.mjs +1 -1
- package/esm2020/lib/shared/smart-tooltip.directive.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/api/api.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/api/default.service.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/api.module.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/configuration.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/encoder.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/index.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/model/componentType.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/model/componentWidgetType.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/model/layoutDirection.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/model/models.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/model/smartComponentLayoutDefinition.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/model/smartComponentWidgetDefinition.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/param.mjs +1 -1
- package/esm2020/lib/smart-component-layout/api/variables.mjs +1 -1
- package/esm2020/lib/smart-component-layout/smart-component-layout.component.mjs +2 -2
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionBoolOperator.mjs +6 -5
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionBuilderField.mjs +1 -1
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionBuilderGroup.mjs +8 -9
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionBuilderModel.mjs +1 -1
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionData.mjs +1 -1
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionDataType.mjs +9 -8
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionField.mjs +1 -1
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionFieldList.mjs +1 -1
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionFieldWidgetType.mjs +15 -14
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionList.mjs +1 -1
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionOperandData.mjs +1 -1
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionOperation.mjs +21 -20
- package/esm2020/lib/smart-filter/api/filter/model/filterExpressionOrderBy.mjs +7 -8
- package/esm2020/lib/smart-filter/smart-filter/components/smart-filter-simple/components/smart-filter-simple-field/smart-filter-simple-field.component.mjs +11 -10
- package/esm2020/lib/smart-filter-editor/api/model/filterExpressionOrderBy.mjs +19 -0
- package/esm2020/lib/smart-filter-editor/smart-filter-editor-content/smart-filter-editor-content.component.mjs +8 -8
- package/esm2020/lib/smart-grid/api/grid-api/model/gridModel.mjs +1 -1
- package/esm2020/lib/smart-grid/api/grid-api/model/gridRow.mjs +1 -1
- package/esm2020/lib/smart-grid/api/grid-api/model/gridUpdateData.mjs +1 -1
- package/esm2020/lib/smart-grid/api/grid-api/model/gridView.mjs +1 -1
- package/esm2020/lib/smart-grid/smart-grid.component.mjs +2 -2
- package/esm2020/lib/smart-tree/tree-api/api/tree.service.mjs +1 -1
- package/esm2020/lib/smart-tree/tree-api/configuration.mjs +1 -1
- package/esm2020/lib/smart-tree/tree-api/encoder.mjs +1 -1
- package/esm2020/lib/smart-tree/tree-api/param.mjs +1 -1
- package/esm2020/lib/smart-tree/tree-api/variables.mjs +1 -1
- package/esm2020/lib/view-context/api/model/openPendingData.mjs +1 -1
- package/esm2020/lib/view-context/api/model/uiAction.mjs +1 -1
- package/esm2020/lib/view-context/value-api/api/api.mjs +1 -1
- package/esm2020/lib/view-context/value-api/api/value.service.mjs +1 -1
- package/esm2020/lib/view-context/value-api/api.module.mjs +1 -1
- package/esm2020/lib/view-context/value-api/configuration.mjs +1 -1
- package/esm2020/lib/view-context/value-api/encoder.mjs +1 -1
- package/esm2020/lib/view-context/value-api/index.mjs +1 -1
- package/esm2020/lib/view-context/value-api/model/genericValue.mjs +1 -1
- package/esm2020/lib/view-context/value-api/model/models.mjs +1 -1
- package/esm2020/lib/view-context/value-api/model/value.mjs +1 -1
- package/esm2020/lib/view-context/value-api/model/valueSetDefinition.mjs +1 -1
- package/esm2020/lib/view-context/value-api/model/valueSetDefinitionIdentifier.mjs +1 -1
- package/esm2020/lib/view-context/value-api/model/valueSetOperand.mjs +1 -1
- package/esm2020/lib/view-context/value-api/param.mjs +1 -1
- package/esm2020/lib/view-context/value-api/variables.mjs +1 -1
- package/fesm2015/smartbit4all-ng-client.mjs +493 -471
- package/fesm2015/smartbit4all-ng-client.mjs.map +1 -1
- package/fesm2020/smartbit4all-ng-client.mjs +1747 -1725
- package/fesm2020/smartbit4all-ng-client.mjs.map +1 -1
- package/lib/smart-filter/api/filter/model/filterExpressionBoolOperator.d.ts +4 -5
- package/lib/smart-filter/api/filter/model/filterExpressionBuilderGroup.d.ts +5 -8
- package/lib/smart-filter/api/filter/model/filterExpressionBuilderModel.d.ts +6 -0
- package/lib/smart-filter/api/filter/model/filterExpressionDataType.d.ts +7 -8
- package/lib/smart-filter/api/filter/model/filterExpressionField.d.ts +3 -0
- package/lib/smart-filter/api/filter/model/filterExpressionFieldWidgetType.d.ts +13 -14
- package/lib/smart-filter/api/filter/model/filterExpressionOperation.d.ts +19 -20
- package/lib/smart-filter/api/filter/model/filterExpressionOrderBy.d.ts +4 -7
- package/lib/smart-filter-editor/api/model/filterExpressionOrderBy.d.ts +28 -0
- package/lib/smart-grid/api/grid-api/model/gridUpdateData.d.ts +1 -1
- package/lib/smart-grid/api/grid-api/model/gridView.d.ts +1 -1
- package/package.json +1 -1
- package/smartbit4all-ng-client-3.3.50.tgz +0 -0
- package/src/lib/session/api/README.md +226 -226
- package/src/lib/smart-component-layout/api/README.md +226 -226
- package/src/lib/smart-tree/tree-api/README.md +226 -226
- package/src/lib/view-context/value-api/README.md +226 -226
- package/smartbit4all-ng-client-3.3.49.tgz +0 -0
|
@@ -9513,127 +9513,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
|
|
|
9513
9513
|
args: ['forms']
|
|
9514
9514
|
}] } });
|
|
9515
9515
|
|
|
9516
|
-
class SmartFilterService {
|
|
9517
|
-
constructor() {
|
|
9518
|
-
this._destroy$ = new Subject();
|
|
9519
|
-
this.shouldSubmit = new Subject();
|
|
9520
|
-
this.reSubscribeToSubmit = new Subject();
|
|
9521
|
-
this.change = new Subject();
|
|
9522
|
-
}
|
|
9523
|
-
ngOnDestroy() {
|
|
9524
|
-
this._destroy$.next();
|
|
9525
|
-
this._destroy$.complete();
|
|
9526
|
-
}
|
|
9527
|
-
submit() {
|
|
9528
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
9529
|
-
this.shouldSubmit.next();
|
|
9530
|
-
yield this.shouldSubmit.pipe(takeUntil(this._destroy$)).toPromise();
|
|
9531
|
-
this.shouldSubmit = new Subject();
|
|
9532
|
-
this.reSubscribeToSubmit.next();
|
|
9533
|
-
return this.filter;
|
|
9534
|
-
});
|
|
9535
|
-
}
|
|
9536
|
-
}
|
|
9537
|
-
SmartFilterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
9538
|
-
SmartFilterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterService, providedIn: 'root' });
|
|
9539
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterService, decorators: [{
|
|
9540
|
-
type: Injectable,
|
|
9541
|
-
args: [{
|
|
9542
|
-
providedIn: 'root',
|
|
9543
|
-
}]
|
|
9544
|
-
}], ctorParameters: function () { return []; } });
|
|
9545
|
-
|
|
9546
|
-
/**
|
|
9547
|
-
* Filter API 2
|
|
9548
|
-
* Filter API 2
|
|
9549
|
-
*
|
|
9550
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9551
|
-
* Contact: info@it4all.hu
|
|
9552
|
-
*
|
|
9553
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9554
|
-
* https://openapi-generator.tech
|
|
9555
|
-
* Do not edit the class manually.
|
|
9556
|
-
*/
|
|
9557
|
-
const FilterExpressionBoolOperator$1 = {
|
|
9558
|
-
And: 'AND',
|
|
9559
|
-
Or: 'OR'
|
|
9560
|
-
};
|
|
9561
|
-
|
|
9562
|
-
/**
|
|
9563
|
-
* Filter API 2
|
|
9564
|
-
* Filter API 2
|
|
9565
|
-
*
|
|
9566
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9567
|
-
* Contact: info@it4all.hu
|
|
9568
|
-
*
|
|
9569
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9570
|
-
* https://openapi-generator.tech
|
|
9571
|
-
* Do not edit the class manually.
|
|
9572
|
-
*/
|
|
9573
|
-
const FilterExpressionDataType = {
|
|
9574
|
-
String: 'STRING',
|
|
9575
|
-
Number: 'NUMBER',
|
|
9576
|
-
Date: 'DATE',
|
|
9577
|
-
DateTime: 'DATE_TIME',
|
|
9578
|
-
Boolean: 'BOOLEAN'
|
|
9579
|
-
};
|
|
9580
|
-
|
|
9581
|
-
/**
|
|
9582
|
-
* Filter API 2
|
|
9583
|
-
* Filter API 2
|
|
9584
|
-
*
|
|
9585
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9586
|
-
* Contact: info@it4all.hu
|
|
9587
|
-
*
|
|
9588
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9589
|
-
* https://openapi-generator.tech
|
|
9590
|
-
* Do not edit the class manually.
|
|
9591
|
-
*/
|
|
9592
|
-
const FilterExpressionFieldWidgetType = {
|
|
9593
|
-
TextField: 'TEXT_FIELD',
|
|
9594
|
-
TextFieldChips: 'TEXT_FIELD_CHIPS',
|
|
9595
|
-
TextBox: 'TEXT_BOX',
|
|
9596
|
-
Select: 'SELECT',
|
|
9597
|
-
SelectMultiple: 'SELECT_MULTIPLE',
|
|
9598
|
-
Date: 'DATE',
|
|
9599
|
-
Time: 'TIME',
|
|
9600
|
-
DateTime: 'DATE_TIME',
|
|
9601
|
-
CheckBox: 'CHECK_BOX',
|
|
9602
|
-
RadioButton: 'RADIO_BUTTON',
|
|
9603
|
-
Range: 'RANGE'
|
|
9604
|
-
};
|
|
9605
|
-
|
|
9606
|
-
/**
|
|
9607
|
-
* Filter API 2
|
|
9608
|
-
* Filter API 2
|
|
9609
|
-
*
|
|
9610
|
-
* The version of the OpenAPI document: 1.0.0
|
|
9611
|
-
* Contact: info@it4all.hu
|
|
9612
|
-
*
|
|
9613
|
-
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9614
|
-
* https://openapi-generator.tech
|
|
9615
|
-
* Do not edit the class manually.
|
|
9616
|
-
*/
|
|
9617
|
-
const FilterExpressionOperation = {
|
|
9618
|
-
Expression: 'EXPRESSION',
|
|
9619
|
-
Equal: 'EQUAL',
|
|
9620
|
-
NotEqual: 'NOT_EQUAL',
|
|
9621
|
-
Less: 'LESS',
|
|
9622
|
-
LessOrEqual: 'LESS_OR_EQUAL',
|
|
9623
|
-
Greater: 'GREATER',
|
|
9624
|
-
GreaterOrEqual: 'GREATER_OR_EQUAL',
|
|
9625
|
-
Like: 'LIKE',
|
|
9626
|
-
NotLike: 'NOT_LIKE',
|
|
9627
|
-
Between: 'BETWEEN',
|
|
9628
|
-
NotBetween: 'NOT_BETWEEN',
|
|
9629
|
-
IsEmpty: 'IS_EMPTY',
|
|
9630
|
-
IsNotEmpty: 'IS_NOT_EMPTY',
|
|
9631
|
-
Exists: 'EXISTS',
|
|
9632
|
-
NotExists: 'NOT_EXISTS',
|
|
9633
|
-
In: 'IN',
|
|
9634
|
-
NotIn: 'NOT_IN'
|
|
9635
|
-
};
|
|
9636
|
-
|
|
9637
9516
|
/**
|
|
9638
9517
|
* Filter API 2
|
|
9639
9518
|
* Filter API 2
|
|
@@ -9649,362 +9528,76 @@ var FilterExpressionOrderBy;
|
|
|
9649
9528
|
(function (FilterExpressionOrderBy) {
|
|
9650
9529
|
FilterExpressionOrderBy.OrderEnum = {
|
|
9651
9530
|
Asc: 'ASC',
|
|
9652
|
-
Desc: 'DESC'
|
|
9531
|
+
Desc: 'DESC',
|
|
9653
9532
|
};
|
|
9654
9533
|
})(FilterExpressionOrderBy || (FilterExpressionOrderBy = {}));
|
|
9655
9534
|
|
|
9656
|
-
var
|
|
9657
|
-
(function (
|
|
9658
|
-
|
|
9659
|
-
|
|
9660
|
-
|
|
9661
|
-
|
|
9662
|
-
|
|
9663
|
-
|
|
9535
|
+
var ExpandableSectionButtonType;
|
|
9536
|
+
(function (ExpandableSectionButtonType) {
|
|
9537
|
+
ExpandableSectionButtonType[ExpandableSectionButtonType["BUTTON"] = 0] = "BUTTON";
|
|
9538
|
+
ExpandableSectionButtonType[ExpandableSectionButtonType["MENU"] = 1] = "MENU";
|
|
9539
|
+
ExpandableSectionButtonType[ExpandableSectionButtonType["MENU_ITEM"] = 2] = "MENU_ITEM";
|
|
9540
|
+
})(ExpandableSectionButtonType || (ExpandableSectionButtonType = {}));
|
|
9541
|
+
var ExpandableSectionButtonIconPosition;
|
|
9542
|
+
(function (ExpandableSectionButtonIconPosition) {
|
|
9543
|
+
ExpandableSectionButtonIconPosition["PRE"] = "Pre";
|
|
9544
|
+
ExpandableSectionButtonIconPosition["POST"] = "Post";
|
|
9545
|
+
})(ExpandableSectionButtonIconPosition || (ExpandableSectionButtonIconPosition = {}));
|
|
9664
9546
|
|
|
9665
|
-
class
|
|
9666
|
-
constructor(
|
|
9667
|
-
this.service = service;
|
|
9547
|
+
class ExpandableSectionComponent {
|
|
9548
|
+
constructor(cfService) {
|
|
9668
9549
|
this.cfService = cfService;
|
|
9669
|
-
this.
|
|
9550
|
+
this.stateChange = new Subject();
|
|
9670
9551
|
}
|
|
9671
|
-
|
|
9672
|
-
|
|
9673
|
-
this.
|
|
9674
|
-
|
|
9552
|
+
onStateChange(isOpened) {
|
|
9553
|
+
this.data.isExpanded = isOpened;
|
|
9554
|
+
this.stateChange.next(this.data);
|
|
9555
|
+
if (this.data.stateChanged) {
|
|
9556
|
+
this.data.stateChanged.next({
|
|
9557
|
+
data: this.data.data,
|
|
9558
|
+
isExpanded: isOpened,
|
|
9559
|
+
index: this.data.index,
|
|
9560
|
+
});
|
|
9561
|
+
}
|
|
9675
9562
|
}
|
|
9563
|
+
ngOnInit() { }
|
|
9676
9564
|
ngAfterViewInit() {
|
|
9677
|
-
|
|
9678
|
-
|
|
9679
|
-
|
|
9680
|
-
|
|
9681
|
-
|
|
9682
|
-
|
|
9683
|
-
|
|
9684
|
-
|
|
9685
|
-
if (type === FilterExpressionFieldWidgetType.Date) {
|
|
9686
|
-
type = SmartFormWidgetType.DATE_PICKER;
|
|
9687
|
-
}
|
|
9688
|
-
else if (type === FilterExpressionFieldWidgetType.DateTime) {
|
|
9689
|
-
type = SmartFormWidgetType.DATE_TIME_PICKER;
|
|
9565
|
+
var _a, _b;
|
|
9566
|
+
if (this.data.headerComponent) {
|
|
9567
|
+
this.cfService.createComponent(this.vcRefheader, this.data.headerComponent, new Map([
|
|
9568
|
+
[(_a = this.data.headerInputName) !== null && _a !== void 0 ? _a : '', this.data.headerData],
|
|
9569
|
+
['stateChange', this.stateChange],
|
|
9570
|
+
['index', this.data.index],
|
|
9571
|
+
['sectionIndex', this.index],
|
|
9572
|
+
]));
|
|
9690
9573
|
}
|
|
9691
|
-
|
|
9692
|
-
|
|
9693
|
-
|
|
9694
|
-
|
|
9695
|
-
|
|
9696
|
-
|
|
9697
|
-
valueList: possibleValues.map((value) => {
|
|
9698
|
-
return {
|
|
9699
|
-
key: value.objectUri ? value.objectUri : value.code,
|
|
9700
|
-
label: value.displayValue,
|
|
9701
|
-
type: SmartFormWidgetType.ITEM,
|
|
9702
|
-
value: value.objectUri ? value.objectUri : value.code,
|
|
9703
|
-
};
|
|
9704
|
-
}),
|
|
9705
|
-
};
|
|
9706
|
-
return widget;
|
|
9574
|
+
this.componentRef = this.cfService.createComponent(this.vcRef, this.data.customComponent, new Map([
|
|
9575
|
+
[(_b = this.data.inputName) !== null && _b !== void 0 ? _b : '', this.data.data],
|
|
9576
|
+
['stateChange', this.stateChange],
|
|
9577
|
+
['index', this.data.index],
|
|
9578
|
+
['sectionIndex', this.index],
|
|
9579
|
+
]));
|
|
9707
9580
|
}
|
|
9708
|
-
|
|
9709
|
-
|
|
9710
|
-
(
|
|
9711
|
-
|
|
9712
|
-
let key;
|
|
9713
|
-
if (this.filterExpressionField.widgetType === 'SELECT_MULTIPLE') {
|
|
9714
|
-
key = 'expressionData.operand2.selectedValues';
|
|
9715
|
-
}
|
|
9716
|
-
if ((_b = this.filterExpressionField.expressionData) === null || _b === void 0 ? void 0 : _b.operand2) {
|
|
9717
|
-
if (key !== 'expressionData.operand2.selectedValues') {
|
|
9718
|
-
key = 'expressionData.operand2.valueAsString';
|
|
9719
|
-
}
|
|
9720
|
-
widgets.push(this.constructFormWidget(key, this.filterExpressionField.label2, (_c = this.filterExpressionField.widgetType) !== null && _c !== void 0 ? _c : FilterExpressionFieldWidgetType.TextField, this.filterExpressionField.possibleValues));
|
|
9721
|
-
}
|
|
9722
|
-
if ((_d = this.filterExpressionField.expressionData) === null || _d === void 0 ? void 0 : _d.operand3) {
|
|
9723
|
-
if (key !== 'selectedValues') {
|
|
9724
|
-
key = 'expressionData.operand3.valueAsString';
|
|
9725
|
-
}
|
|
9726
|
-
widgets.push(this.constructFormWidget(key, this.filterExpressionField.label3, (_e = this.filterExpressionField.widgetType) !== null && _e !== void 0 ? _e : FilterExpressionFieldWidgetType.TextField, this.filterExpressionField.possibleValues));
|
|
9581
|
+
action(button, event) {
|
|
9582
|
+
event.stopPropagation();
|
|
9583
|
+
if (!button.callback) {
|
|
9584
|
+
throw new Error(`Button with name ${button.label} or icon ${button.icon} does not have a callback!`);
|
|
9727
9585
|
}
|
|
9728
|
-
|
|
9729
|
-
this.currentOperation = this.getOptionLabel(this.operation);
|
|
9730
|
-
this.smartForm = {
|
|
9731
|
-
direction: SmartFormWidgetDirection.ROW,
|
|
9732
|
-
componentModel: { data: this.filterExpressionField },
|
|
9733
|
-
useOnValueChangeEvent: true,
|
|
9734
|
-
useOnBlurEvent: true,
|
|
9735
|
-
submitOnEnter: (_g = this.service.filter) === null || _g === void 0 ? void 0 : _g.submitOnEnter,
|
|
9736
|
-
widgets,
|
|
9737
|
-
translateService: (_h = this.service.filter) === null || _h === void 0 ? void 0 : _h.translateService,
|
|
9738
|
-
};
|
|
9739
|
-
// Show form on page
|
|
9740
|
-
this.componentRefForm = this.cfService.createComponent(this.vcRefForm, SmartformComponent, new Map([['smartForm', this.smartForm]]));
|
|
9741
|
-
(_j = this.componentRefForm.instance.onValueChangeSubject) === null || _j === void 0 ? void 0 : _j.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
9742
|
-
this.submit();
|
|
9743
|
-
this.service.change.next();
|
|
9744
|
-
});
|
|
9745
|
-
(_k = this.componentRefForm.instance.onBlurSubject) === null || _k === void 0 ? void 0 : _k.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
9746
|
-
this.submit();
|
|
9747
|
-
this.service.change.next();
|
|
9748
|
-
});
|
|
9586
|
+
button.callback(button.args);
|
|
9749
9587
|
}
|
|
9750
|
-
|
|
9751
|
-
|
|
9752
|
-
|
|
9753
|
-
this.filterExpressionField = (_a = form.componentModel) === null || _a === void 0 ? void 0 : _a.data;
|
|
9754
|
-
this.simpleFieldChildren.forEach((smartFilterFieldComponent, index) => {
|
|
9755
|
-
let filterExpressionField = smartFilterFieldComponent.submit();
|
|
9756
|
-
this.filterExpressionField.subFieldList.filters[index] = filterExpressionField;
|
|
9757
|
-
});
|
|
9758
|
-
return this.filterExpressionField;
|
|
9588
|
+
setExpanded() { }
|
|
9589
|
+
type() {
|
|
9590
|
+
return ExpandableSectionButtonType;
|
|
9759
9591
|
}
|
|
9760
|
-
|
|
9761
|
-
|
|
9762
|
-
let oldOption = this.componentRefForm.instance.smartForm.componentModel.data.expressionData
|
|
9763
|
-
.currentOperation;
|
|
9764
|
-
this.componentRefForm.instance.smartForm.componentModel.data.expressionData.currentOperation =
|
|
9765
|
-
option;
|
|
9766
|
-
this.operation = option;
|
|
9767
|
-
this.currentOperation = this.getOptionLabel(this.operation);
|
|
9768
|
-
if (oldOption !== FilterExpressionOperation.Between &&
|
|
9769
|
-
option === FilterExpressionOperation.Between) {
|
|
9770
|
-
this.submit();
|
|
9771
|
-
let label = this.filterExpressionField.label2;
|
|
9772
|
-
this.filterExpressionField.label2 = `${label} - tól`;
|
|
9773
|
-
this.filterExpressionField.label3 = `${label} - ig`;
|
|
9774
|
-
this.filterExpressionField.expressionData.operand3 = {
|
|
9775
|
-
isDataName: (_a = this.filterExpressionField.expressionData.operand2) === null || _a === void 0 ? void 0 : _a.isDataName,
|
|
9776
|
-
type: (_b = this.filterExpressionField.expressionData.operand3) === null || _b === void 0 ? void 0 : _b.type,
|
|
9777
|
-
valueAsString: (_c = this.filterExpressionField.expressionData.operand3) === null || _c === void 0 ? void 0 : _c.valueAsString,
|
|
9778
|
-
selectedValues: (_d = this.filterExpressionField.expressionData.operand3) === null || _d === void 0 ? void 0 : _d.selectedValues,
|
|
9779
|
-
};
|
|
9780
|
-
this.constructForm();
|
|
9781
|
-
}
|
|
9782
|
-
else if (oldOption === FilterExpressionOperation.Between &&
|
|
9783
|
-
option !== FilterExpressionOperation.Between) {
|
|
9784
|
-
let label = this.filterExpressionField.label2.replace(' - tól', '');
|
|
9785
|
-
this.filterExpressionField.label2 = `${label}`;
|
|
9786
|
-
this.filterExpressionField.label3 = undefined;
|
|
9787
|
-
this.filterExpressionField.expressionData.operand3 = undefined;
|
|
9788
|
-
this.constructForm();
|
|
9789
|
-
}
|
|
9592
|
+
position() {
|
|
9593
|
+
return ExpandableSectionButtonIconPosition;
|
|
9790
9594
|
}
|
|
9791
|
-
|
|
9792
|
-
|
|
9793
|
-
|
|
9794
|
-
|
|
9795
|
-
else if (this.operationTranslator) {
|
|
9796
|
-
return this.operationTranslator(option);
|
|
9595
|
+
customButtonClicked(event, button, element) {
|
|
9596
|
+
event.stopPropagation();
|
|
9597
|
+
if (!button.callback) {
|
|
9598
|
+
throw new Error(`Button with name ${button.label} or icon ${button.icon} does not have a callback!`);
|
|
9797
9599
|
}
|
|
9798
|
-
|
|
9799
|
-
}
|
|
9800
|
-
}
|
|
9801
|
-
SmartFilterSimpleFieldComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterSimpleFieldComponent, deps: [{ token: SmartFilterService }, { token: ComponentFactoryService }], target: i0.ɵɵFactoryTarget.Component });
|
|
9802
|
-
SmartFilterSimpleFieldComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartFilterSimpleFieldComponent, selector: "smart-filter-simple-field", inputs: { operationTranslator: "operationTranslator", filterExpressionField: "filterExpressionField", showPossibleActions: "showPossibleActions" }, viewQueries: [{ propertyName: "vcRefForm", first: true, predicate: ["form"], descendants: true, read: ViewContainerRef }, { propertyName: "simpleFieldChildren", predicate: ["simpleField"], descendants: true }], ngImport: i0, template: "<div class=\"smart-filter-simple-field-container\">\r\n <div class=\"smart-filter-simple-field-form-widget\">\r\n <div\r\n class=\"smart-filter-simple-field-form-widget-row\"\r\n *ngIf=\"showPossibleActions\"\r\n >\r\n <p>({{ currentOperation }})</p>\r\n <button\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n aria-label=\"Example icon-button with a menu\"\r\n >\r\n <mat-icon>more_vert</mat-icon>\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <button\r\n mat-menu-item\r\n *ngFor=\"let option of filterExpressionField.possibleOperations\"\r\n (click)=\"optionSelected(option)\"\r\n >\r\n <span>\r\n {{ getOptionLabel(option) }}\r\n </span>\r\n </button>\r\n </mat-menu>\r\n </div>\r\n <ng-template #form></ng-template>\r\n </div>\r\n</div>\r\n", styles: [".smart-filter-simple-field-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem}.smart-filter-simple-field-form-widget{padding:1rem;border-radius:1rem;display:flex;flex-direction:column}.smart-filter-simple-field-form-widget-row{display:flex;flex-direction:row;justify-content:space-between}.smart-filter-simple-field-form-widget-row p{color:#00000042}.smart-filter-simple-field-form-widget ::ng-deep .mat-icon-button{height:24px;width:24px}.smart-filter-simple-field-form-widget ::ng-deep .mat-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-flat-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-stroked-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-raised-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-icon-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-fab .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-mini-fab .mat-button-wrapper>*{vertical-align:inherit!important}.smart-filter-simple-field-subfields-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem}.smart-filter-simple-field-container ::ng-deep h4{margin:0}\n"], components: [{ type: i3.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: i3$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
9803
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterSimpleFieldComponent, decorators: [{
|
|
9804
|
-
type: Component,
|
|
9805
|
-
args: [{ selector: 'smart-filter-simple-field', template: "<div class=\"smart-filter-simple-field-container\">\r\n <div class=\"smart-filter-simple-field-form-widget\">\r\n <div\r\n class=\"smart-filter-simple-field-form-widget-row\"\r\n *ngIf=\"showPossibleActions\"\r\n >\r\n <p>({{ currentOperation }})</p>\r\n <button\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n aria-label=\"Example icon-button with a menu\"\r\n >\r\n <mat-icon>more_vert</mat-icon>\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <button\r\n mat-menu-item\r\n *ngFor=\"let option of filterExpressionField.possibleOperations\"\r\n (click)=\"optionSelected(option)\"\r\n >\r\n <span>\r\n {{ getOptionLabel(option) }}\r\n </span>\r\n </button>\r\n </mat-menu>\r\n </div>\r\n <ng-template #form></ng-template>\r\n </div>\r\n</div>\r\n", styles: [".smart-filter-simple-field-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem}.smart-filter-simple-field-form-widget{padding:1rem;border-radius:1rem;display:flex;flex-direction:column}.smart-filter-simple-field-form-widget-row{display:flex;flex-direction:row;justify-content:space-between}.smart-filter-simple-field-form-widget-row p{color:#00000042}.smart-filter-simple-field-form-widget ::ng-deep .mat-icon-button{height:24px;width:24px}.smart-filter-simple-field-form-widget ::ng-deep .mat-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-flat-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-stroked-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-raised-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-icon-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-fab .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-mini-fab .mat-button-wrapper>*{vertical-align:inherit!important}.smart-filter-simple-field-subfields-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem}.smart-filter-simple-field-container ::ng-deep h4{margin:0}\n"] }]
|
|
9806
|
-
}], ctorParameters: function () { return [{ type: SmartFilterService }, { type: ComponentFactoryService }]; }, propDecorators: { simpleFieldChildren: [{
|
|
9807
|
-
type: ViewChildren,
|
|
9808
|
-
args: ['simpleField']
|
|
9809
|
-
}], operationTranslator: [{
|
|
9810
|
-
type: Input
|
|
9811
|
-
}], filterExpressionField: [{
|
|
9812
|
-
type: Input
|
|
9813
|
-
}], showPossibleActions: [{
|
|
9814
|
-
type: Input
|
|
9815
|
-
}], vcRefForm: [{
|
|
9816
|
-
type: ViewChild,
|
|
9817
|
-
args: ['form', { read: ViewContainerRef }]
|
|
9818
|
-
}] } });
|
|
9819
|
-
|
|
9820
|
-
class SmartFilterSimpleComponent {
|
|
9821
|
-
constructor(service) {
|
|
9822
|
-
this.service = service;
|
|
9823
|
-
this._destroy$ = new Subject();
|
|
9824
|
-
this.service.reSubscribeToSubmit.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
9825
|
-
this.subscribeToSubmit();
|
|
9826
|
-
});
|
|
9827
|
-
this.subscribeToSubmit();
|
|
9828
|
-
}
|
|
9829
|
-
ngOnInit() {
|
|
9830
|
-
this.smartFilter = this.service.filter;
|
|
9831
|
-
}
|
|
9832
|
-
ngOnDestroy() {
|
|
9833
|
-
this._destroy$.next();
|
|
9834
|
-
this._destroy$.complete();
|
|
9835
|
-
}
|
|
9836
|
-
subscribeToSubmit() {
|
|
9837
|
-
this.service.shouldSubmit.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
9838
|
-
this.submit();
|
|
9839
|
-
});
|
|
9840
|
-
}
|
|
9841
|
-
submit() {
|
|
9842
|
-
this.simpleFieldChildren.forEach((smartFilterFieldComponent, index) => {
|
|
9843
|
-
this.smartFilter.data[index] = smartFilterFieldComponent.submit();
|
|
9844
|
-
});
|
|
9845
|
-
this.service.filter = this.smartFilter;
|
|
9846
|
-
this.service.shouldSubmit.complete();
|
|
9847
|
-
}
|
|
9848
|
-
}
|
|
9849
|
-
SmartFilterSimpleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterSimpleComponent, deps: [{ token: SmartFilterService }], target: i0.ɵɵFactoryTarget.Component });
|
|
9850
|
-
SmartFilterSimpleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartFilterSimpleComponent, selector: "smart-filter-simple", viewQueries: [{ propertyName: "simpleFieldChildren", predicate: ["simpleField"], descendants: true }], ngImport: i0, template: "<div *ngIf=\"smartFilter\" class=\"smart-simple-fields-container\">\r\n <div *ngFor=\"let filterExpressionField of smartFilter.data; let i = index\">\r\n <smart-filter-simple-field\r\n #simpleField\r\n [filterExpressionField]=\"filterExpressionField\"\r\n [operationTranslator]=\"smartFilter.operationTranslator\"\r\n [showPossibleActions]=\"smartFilter.showPossibleActions\"\r\n ></smart-filter-simple-field>\r\n <div *ngFor=\"let subfilterExpressionField of filterExpressionField.subFieldList?.filters\">\r\n <smart-filter-simple-field\r\n #simpleField\r\n [filterExpressionField]=\"filterExpressionField\"\r\n [operationTranslator]=\"smartFilter.operationTranslator\"\r\n [showPossibleActions]=\"smartFilter.showPossibleActions\"\r\n ></smart-filter-simple-field>\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".smart-simple-fields-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem;justify-content:center}\n"], components: [{ type: SmartFilterSimpleFieldComponent, selector: "smart-filter-simple-field", inputs: ["operationTranslator", "filterExpressionField", "showPossibleActions"] }], directives: [{ type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
9851
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterSimpleComponent, decorators: [{
|
|
9852
|
-
type: Component,
|
|
9853
|
-
args: [{ selector: "smart-filter-simple", template: "<div *ngIf=\"smartFilter\" class=\"smart-simple-fields-container\">\r\n <div *ngFor=\"let filterExpressionField of smartFilter.data; let i = index\">\r\n <smart-filter-simple-field\r\n #simpleField\r\n [filterExpressionField]=\"filterExpressionField\"\r\n [operationTranslator]=\"smartFilter.operationTranslator\"\r\n [showPossibleActions]=\"smartFilter.showPossibleActions\"\r\n ></smart-filter-simple-field>\r\n <div *ngFor=\"let subfilterExpressionField of filterExpressionField.subFieldList?.filters\">\r\n <smart-filter-simple-field\r\n #simpleField\r\n [filterExpressionField]=\"filterExpressionField\"\r\n [operationTranslator]=\"smartFilter.operationTranslator\"\r\n [showPossibleActions]=\"smartFilter.showPossibleActions\"\r\n ></smart-filter-simple-field>\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".smart-simple-fields-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem;justify-content:center}\n"] }]
|
|
9854
|
-
}], ctorParameters: function () { return [{ type: SmartFilterService }]; }, propDecorators: { simpleFieldChildren: [{
|
|
9855
|
-
type: ViewChildren,
|
|
9856
|
-
args: ["simpleField"]
|
|
9857
|
-
}] } });
|
|
9858
|
-
|
|
9859
|
-
class SmartFilterComponent {
|
|
9860
|
-
constructor(service) {
|
|
9861
|
-
this.service = service;
|
|
9862
|
-
}
|
|
9863
|
-
ngOnInit() {
|
|
9864
|
-
if (this.filter) {
|
|
9865
|
-
this.setUp();
|
|
9866
|
-
}
|
|
9867
|
-
}
|
|
9868
|
-
ngOnChanges(changes) {
|
|
9869
|
-
if (changes['filter'].currentValue) {
|
|
9870
|
-
this.setUp();
|
|
9871
|
-
}
|
|
9872
|
-
}
|
|
9873
|
-
setUp() {
|
|
9874
|
-
this.service.filter = this.filter;
|
|
9875
|
-
}
|
|
9876
|
-
submit() {
|
|
9877
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
9878
|
-
return yield this.service.submit();
|
|
9879
|
-
});
|
|
9880
|
-
}
|
|
9881
|
-
}
|
|
9882
|
-
SmartFilterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterComponent, deps: [{ token: SmartFilterService }], target: i0.ɵɵFactoryTarget.Component });
|
|
9883
|
-
SmartFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartFilterComponent, selector: "smart-filter", inputs: { filter: "filter" }, providers: [SmartFilterService], usesOnChanges: true, ngImport: i0, template: "<smart-filter-simple *ngIf=\"filter\" #simpleFilter></smart-filter-simple>\r\n", styles: [""], components: [{ type: SmartFilterSimpleComponent, selector: "smart-filter-simple" }], directives: [{ type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
9884
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterComponent, decorators: [{
|
|
9885
|
-
type: Component,
|
|
9886
|
-
args: [{ selector: 'smart-filter', providers: [SmartFilterService], template: "<smart-filter-simple *ngIf=\"filter\" #simpleFilter></smart-filter-simple>\r\n", styles: [""] }]
|
|
9887
|
-
}], ctorParameters: function () { return [{ type: SmartFilterService }]; }, propDecorators: { filter: [{
|
|
9888
|
-
type: Input
|
|
9889
|
-
}] } });
|
|
9890
|
-
|
|
9891
|
-
class SmartFilterExpressionFieldComponent {
|
|
9892
|
-
constructor() { }
|
|
9893
|
-
ngOnInit() {
|
|
9894
|
-
}
|
|
9895
|
-
}
|
|
9896
|
-
SmartFilterExpressionFieldComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterExpressionFieldComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
9897
|
-
SmartFilterExpressionFieldComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartFilterExpressionFieldComponent, selector: "lib-smart-filter-expression-field", ngImport: i0, template: "", styles: [""] });
|
|
9898
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterExpressionFieldComponent, decorators: [{
|
|
9899
|
-
type: Component,
|
|
9900
|
-
args: [{ selector: 'lib-smart-filter-expression-field', template: "", styles: [""] }]
|
|
9901
|
-
}], ctorParameters: function () { return []; } });
|
|
9902
|
-
|
|
9903
|
-
class SmartFilterModule {
|
|
9904
|
-
}
|
|
9905
|
-
SmartFilterModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
9906
|
-
SmartFilterModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterModule, declarations: [SmartFilterComponent,
|
|
9907
|
-
SmartFilterExpressionFieldComponent,
|
|
9908
|
-
SmartFilterSimpleComponent,
|
|
9909
|
-
SmartFilterSimpleFieldComponent], imports: [BrowserModule, SmartformModule, MatMenuModule, MatIconModule, MatButtonModule], exports: [SmartFilterComponent] });
|
|
9910
|
-
SmartFilterModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterModule, imports: [[BrowserModule, SmartformModule, MatMenuModule, MatIconModule, MatButtonModule]] });
|
|
9911
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterModule, decorators: [{
|
|
9912
|
-
type: NgModule,
|
|
9913
|
-
args: [{
|
|
9914
|
-
declarations: [
|
|
9915
|
-
SmartFilterComponent,
|
|
9916
|
-
SmartFilterExpressionFieldComponent,
|
|
9917
|
-
SmartFilterSimpleComponent,
|
|
9918
|
-
SmartFilterSimpleFieldComponent,
|
|
9919
|
-
],
|
|
9920
|
-
imports: [BrowserModule, SmartformModule, MatMenuModule, MatIconModule, MatButtonModule],
|
|
9921
|
-
exports: [SmartFilterComponent],
|
|
9922
|
-
}]
|
|
9923
|
-
}] });
|
|
9924
|
-
|
|
9925
|
-
var SmartFilterPosition;
|
|
9926
|
-
(function (SmartFilterPosition) {
|
|
9927
|
-
SmartFilterPosition[SmartFilterPosition["TOP"] = 0] = "TOP";
|
|
9928
|
-
SmartFilterPosition[SmartFilterPosition["BOTTOM"] = 1] = "BOTTOM";
|
|
9929
|
-
SmartFilterPosition[SmartFilterPosition["LEFT"] = 2] = "LEFT";
|
|
9930
|
-
SmartFilterPosition[SmartFilterPosition["RIGHT"] = 3] = "RIGHT";
|
|
9931
|
-
})(SmartFilterPosition || (SmartFilterPosition = {}));
|
|
9932
|
-
var SmartFilterType;
|
|
9933
|
-
(function (SmartFilterType) {
|
|
9934
|
-
SmartFilterType[SmartFilterType["SIMPLE"] = 0] = "SIMPLE";
|
|
9935
|
-
SmartFilterType[SmartFilterType["ADVANCED"] = 1] = "ADVANCED";
|
|
9936
|
-
})(SmartFilterType || (SmartFilterType = {}));
|
|
9937
|
-
|
|
9938
|
-
/*
|
|
9939
|
-
* Public API Surface of smart-filter
|
|
9940
|
-
*/
|
|
9941
|
-
|
|
9942
|
-
var ExpandableSectionButtonType;
|
|
9943
|
-
(function (ExpandableSectionButtonType) {
|
|
9944
|
-
ExpandableSectionButtonType[ExpandableSectionButtonType["BUTTON"] = 0] = "BUTTON";
|
|
9945
|
-
ExpandableSectionButtonType[ExpandableSectionButtonType["MENU"] = 1] = "MENU";
|
|
9946
|
-
ExpandableSectionButtonType[ExpandableSectionButtonType["MENU_ITEM"] = 2] = "MENU_ITEM";
|
|
9947
|
-
})(ExpandableSectionButtonType || (ExpandableSectionButtonType = {}));
|
|
9948
|
-
var ExpandableSectionButtonIconPosition;
|
|
9949
|
-
(function (ExpandableSectionButtonIconPosition) {
|
|
9950
|
-
ExpandableSectionButtonIconPosition["PRE"] = "Pre";
|
|
9951
|
-
ExpandableSectionButtonIconPosition["POST"] = "Post";
|
|
9952
|
-
})(ExpandableSectionButtonIconPosition || (ExpandableSectionButtonIconPosition = {}));
|
|
9953
|
-
|
|
9954
|
-
class ExpandableSectionComponent {
|
|
9955
|
-
constructor(cfService) {
|
|
9956
|
-
this.cfService = cfService;
|
|
9957
|
-
this.stateChange = new Subject();
|
|
9958
|
-
}
|
|
9959
|
-
onStateChange(isOpened) {
|
|
9960
|
-
this.data.isExpanded = isOpened;
|
|
9961
|
-
this.stateChange.next(this.data);
|
|
9962
|
-
if (this.data.stateChanged) {
|
|
9963
|
-
this.data.stateChanged.next({
|
|
9964
|
-
data: this.data.data,
|
|
9965
|
-
isExpanded: isOpened,
|
|
9966
|
-
index: this.data.index,
|
|
9967
|
-
});
|
|
9968
|
-
}
|
|
9969
|
-
}
|
|
9970
|
-
ngOnInit() { }
|
|
9971
|
-
ngAfterViewInit() {
|
|
9972
|
-
var _a, _b;
|
|
9973
|
-
if (this.data.headerComponent) {
|
|
9974
|
-
this.cfService.createComponent(this.vcRefheader, this.data.headerComponent, new Map([
|
|
9975
|
-
[(_a = this.data.headerInputName) !== null && _a !== void 0 ? _a : '', this.data.headerData],
|
|
9976
|
-
['stateChange', this.stateChange],
|
|
9977
|
-
['index', this.data.index],
|
|
9978
|
-
['sectionIndex', this.index],
|
|
9979
|
-
]));
|
|
9980
|
-
}
|
|
9981
|
-
this.componentRef = this.cfService.createComponent(this.vcRef, this.data.customComponent, new Map([
|
|
9982
|
-
[(_b = this.data.inputName) !== null && _b !== void 0 ? _b : '', this.data.data],
|
|
9983
|
-
['stateChange', this.stateChange],
|
|
9984
|
-
['index', this.data.index],
|
|
9985
|
-
['sectionIndex', this.index],
|
|
9986
|
-
]));
|
|
9987
|
-
}
|
|
9988
|
-
action(button, event) {
|
|
9989
|
-
event.stopPropagation();
|
|
9990
|
-
if (!button.callback) {
|
|
9991
|
-
throw new Error(`Button with name ${button.label} or icon ${button.icon} does not have a callback!`);
|
|
9992
|
-
}
|
|
9993
|
-
button.callback(button.args);
|
|
9994
|
-
}
|
|
9995
|
-
setExpanded() { }
|
|
9996
|
-
type() {
|
|
9997
|
-
return ExpandableSectionButtonType;
|
|
9998
|
-
}
|
|
9999
|
-
position() {
|
|
10000
|
-
return ExpandableSectionButtonIconPosition;
|
|
10001
|
-
}
|
|
10002
|
-
customButtonClicked(event, button, element) {
|
|
10003
|
-
event.stopPropagation();
|
|
10004
|
-
if (!button.callback) {
|
|
10005
|
-
throw new Error(`Button with name ${button.label} or icon ${button.icon} does not have a callback!`);
|
|
10006
|
-
}
|
|
10007
|
-
button.callback(button.args, element);
|
|
9600
|
+
button.callback(button.args, element);
|
|
10008
9601
|
}
|
|
10009
9602
|
}
|
|
10010
9603
|
ExpandableSectionComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: ExpandableSectionComponent, deps: [{ token: ComponentFactoryService }], target: i0.ɵɵFactoryTarget.Component });
|
|
@@ -13115,8 +12708,8 @@ class SmartComponentLayoutComponent {
|
|
|
13115
12708
|
else if (((_h = this.smartComponentLayout.widget) === null || _h === void 0 ? void 0 : _h.type) === ComponentWidgetType.TOOLBAR) {
|
|
13116
12709
|
this.constructToolbar();
|
|
13117
12710
|
}
|
|
12711
|
+
this.parent.initActions();
|
|
13118
12712
|
}
|
|
13119
|
-
this.parent.initActions();
|
|
13120
12713
|
}
|
|
13121
12714
|
type() {
|
|
13122
12715
|
return ComponentType;
|
|
@@ -13353,6 +12946,435 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
|
|
|
13353
12946
|
args: ['smartFilter', { read: ViewContainerRef }]
|
|
13354
12947
|
}] } });
|
|
13355
12948
|
|
|
12949
|
+
class SmartFilterService {
|
|
12950
|
+
constructor() {
|
|
12951
|
+
this._destroy$ = new Subject();
|
|
12952
|
+
this.shouldSubmit = new Subject();
|
|
12953
|
+
this.reSubscribeToSubmit = new Subject();
|
|
12954
|
+
this.change = new Subject();
|
|
12955
|
+
}
|
|
12956
|
+
ngOnDestroy() {
|
|
12957
|
+
this._destroy$.next();
|
|
12958
|
+
this._destroy$.complete();
|
|
12959
|
+
}
|
|
12960
|
+
submit() {
|
|
12961
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
12962
|
+
this.shouldSubmit.next();
|
|
12963
|
+
yield this.shouldSubmit.pipe(takeUntil(this._destroy$)).toPromise();
|
|
12964
|
+
this.shouldSubmit = new Subject();
|
|
12965
|
+
this.reSubscribeToSubmit.next();
|
|
12966
|
+
return this.filter;
|
|
12967
|
+
});
|
|
12968
|
+
}
|
|
12969
|
+
}
|
|
12970
|
+
SmartFilterService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
12971
|
+
SmartFilterService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterService, providedIn: 'root' });
|
|
12972
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterService, decorators: [{
|
|
12973
|
+
type: Injectable,
|
|
12974
|
+
args: [{
|
|
12975
|
+
providedIn: 'root',
|
|
12976
|
+
}]
|
|
12977
|
+
}], ctorParameters: function () { return []; } });
|
|
12978
|
+
|
|
12979
|
+
/**
|
|
12980
|
+
* Filter API 2
|
|
12981
|
+
* Filter API 2
|
|
12982
|
+
*
|
|
12983
|
+
* The version of the OpenAPI document: 1.0.0
|
|
12984
|
+
* Contact: info@it4all.hu
|
|
12985
|
+
*
|
|
12986
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12987
|
+
* https://openapi-generator.tech
|
|
12988
|
+
* Do not edit the class manually.
|
|
12989
|
+
*/
|
|
12990
|
+
var FilterExpressionBoolOperator$1;
|
|
12991
|
+
(function (FilterExpressionBoolOperator) {
|
|
12992
|
+
FilterExpressionBoolOperator["AND"] = "AND";
|
|
12993
|
+
FilterExpressionBoolOperator["OR"] = "OR";
|
|
12994
|
+
})(FilterExpressionBoolOperator$1 || (FilterExpressionBoolOperator$1 = {}));
|
|
12995
|
+
|
|
12996
|
+
/**
|
|
12997
|
+
* Filter API 2
|
|
12998
|
+
* Filter API 2
|
|
12999
|
+
*
|
|
13000
|
+
* The version of the OpenAPI document: 1.0.0
|
|
13001
|
+
* Contact: info@it4all.hu
|
|
13002
|
+
*
|
|
13003
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
13004
|
+
* https://openapi-generator.tech
|
|
13005
|
+
* Do not edit the class manually.
|
|
13006
|
+
*/
|
|
13007
|
+
var FilterExpressionDataType;
|
|
13008
|
+
(function (FilterExpressionDataType) {
|
|
13009
|
+
FilterExpressionDataType["STRING"] = "STRING";
|
|
13010
|
+
FilterExpressionDataType["NUMBER"] = "NUMBER";
|
|
13011
|
+
FilterExpressionDataType["DATE"] = "DATE";
|
|
13012
|
+
FilterExpressionDataType["DATE_TIME"] = "DATE_TIME";
|
|
13013
|
+
FilterExpressionDataType["BOOLEAN"] = "BOOLEAN";
|
|
13014
|
+
})(FilterExpressionDataType || (FilterExpressionDataType = {}));
|
|
13015
|
+
|
|
13016
|
+
/**
|
|
13017
|
+
* Filter API 2
|
|
13018
|
+
* Filter API 2
|
|
13019
|
+
*
|
|
13020
|
+
* The version of the OpenAPI document: 1.0.0
|
|
13021
|
+
* Contact: info@it4all.hu
|
|
13022
|
+
*
|
|
13023
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
13024
|
+
* https://openapi-generator.tech
|
|
13025
|
+
* Do not edit the class manually.
|
|
13026
|
+
*/
|
|
13027
|
+
var FilterExpressionFieldWidgetType;
|
|
13028
|
+
(function (FilterExpressionFieldWidgetType) {
|
|
13029
|
+
FilterExpressionFieldWidgetType["TEXT_FIELD"] = "TEXT_FIELD";
|
|
13030
|
+
FilterExpressionFieldWidgetType["TEXT_FIELD_CHIPS"] = "TEXT_FIELD_CHIPS";
|
|
13031
|
+
FilterExpressionFieldWidgetType["TEXT_BOX"] = "TEXT_BOX";
|
|
13032
|
+
FilterExpressionFieldWidgetType["SELECT"] = "SELECT";
|
|
13033
|
+
FilterExpressionFieldWidgetType["SELECT_MULTIPLE"] = "SELECT_MULTIPLE";
|
|
13034
|
+
FilterExpressionFieldWidgetType["DATE"] = "DATE";
|
|
13035
|
+
FilterExpressionFieldWidgetType["TIME"] = "TIME";
|
|
13036
|
+
FilterExpressionFieldWidgetType["DATE_TIME"] = "DATE_TIME";
|
|
13037
|
+
FilterExpressionFieldWidgetType["CHECK_BOX"] = "CHECK_BOX";
|
|
13038
|
+
FilterExpressionFieldWidgetType["RADIO_BUTTON"] = "RADIO_BUTTON";
|
|
13039
|
+
FilterExpressionFieldWidgetType["RANGE"] = "RANGE";
|
|
13040
|
+
})(FilterExpressionFieldWidgetType || (FilterExpressionFieldWidgetType = {}));
|
|
13041
|
+
|
|
13042
|
+
/**
|
|
13043
|
+
* Filter API 2
|
|
13044
|
+
* Filter API 2
|
|
13045
|
+
*
|
|
13046
|
+
* The version of the OpenAPI document: 1.0.0
|
|
13047
|
+
* Contact: info@it4all.hu
|
|
13048
|
+
*
|
|
13049
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
13050
|
+
* https://openapi-generator.tech
|
|
13051
|
+
* Do not edit the class manually.
|
|
13052
|
+
*/
|
|
13053
|
+
var FilterExpressionOperation;
|
|
13054
|
+
(function (FilterExpressionOperation) {
|
|
13055
|
+
FilterExpressionOperation["EXPRESSION"] = "EXPRESSION";
|
|
13056
|
+
FilterExpressionOperation["EQUAL"] = "EQUAL";
|
|
13057
|
+
FilterExpressionOperation["NOT_EQUAL"] = "NOT_EQUAL";
|
|
13058
|
+
FilterExpressionOperation["LESS"] = "LESS";
|
|
13059
|
+
FilterExpressionOperation["LESS_OR_EQUAL"] = "LESS_OR_EQUAL";
|
|
13060
|
+
FilterExpressionOperation["GREATER"] = "GREATER";
|
|
13061
|
+
FilterExpressionOperation["GREATER_OR_EQUAL"] = "GREATER_OR_EQUAL";
|
|
13062
|
+
FilterExpressionOperation["LIKE"] = "LIKE";
|
|
13063
|
+
FilterExpressionOperation["NOT_LIKE"] = "NOT_LIKE";
|
|
13064
|
+
FilterExpressionOperation["BETWEEN"] = "BETWEEN";
|
|
13065
|
+
FilterExpressionOperation["NOT_BETWEEN"] = "NOT_BETWEEN";
|
|
13066
|
+
FilterExpressionOperation["IS_EMPTY"] = "IS_EMPTY";
|
|
13067
|
+
FilterExpressionOperation["IS_NOT_EMPTY"] = "IS_NOT_EMPTY";
|
|
13068
|
+
FilterExpressionOperation["EXISTS"] = "EXISTS";
|
|
13069
|
+
FilterExpressionOperation["NOT_EXISTS"] = "NOT_EXISTS";
|
|
13070
|
+
FilterExpressionOperation["IN"] = "IN";
|
|
13071
|
+
FilterExpressionOperation["NOT_IN"] = "NOT_IN";
|
|
13072
|
+
})(FilterExpressionOperation || (FilterExpressionOperation = {}));
|
|
13073
|
+
|
|
13074
|
+
/**
|
|
13075
|
+
* Filter API 2
|
|
13076
|
+
* Filter API 2
|
|
13077
|
+
*
|
|
13078
|
+
* The version of the OpenAPI document: 1.0.0
|
|
13079
|
+
* Contact: info@it4all.hu
|
|
13080
|
+
*
|
|
13081
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
13082
|
+
* https://openapi-generator.tech
|
|
13083
|
+
* Do not edit the class manually.
|
|
13084
|
+
*/
|
|
13085
|
+
var FilterExpressionOrderByOrderEnum;
|
|
13086
|
+
(function (FilterExpressionOrderByOrderEnum) {
|
|
13087
|
+
FilterExpressionOrderByOrderEnum["ASC"] = "ASC";
|
|
13088
|
+
FilterExpressionOrderByOrderEnum["DESC"] = "DESC";
|
|
13089
|
+
})(FilterExpressionOrderByOrderEnum || (FilterExpressionOrderByOrderEnum = {}));
|
|
13090
|
+
;
|
|
13091
|
+
|
|
13092
|
+
var FilterExpressionBuilderGroupBuilderGroupKindEnum;
|
|
13093
|
+
(function (FilterExpressionBuilderGroupBuilderGroupKindEnum) {
|
|
13094
|
+
FilterExpressionBuilderGroupBuilderGroupKindEnum["DIPLAY"] = "DIPLAY";
|
|
13095
|
+
FilterExpressionBuilderGroupBuilderGroupKindEnum["BRACKET"] = "BRACKET";
|
|
13096
|
+
FilterExpressionBuilderGroupBuilderGroupKindEnum["EXIST"] = "EXIST";
|
|
13097
|
+
})(FilterExpressionBuilderGroupBuilderGroupKindEnum || (FilterExpressionBuilderGroupBuilderGroupKindEnum = {}));
|
|
13098
|
+
;
|
|
13099
|
+
|
|
13100
|
+
class SmartFilterSimpleFieldComponent {
|
|
13101
|
+
constructor(service, cfService) {
|
|
13102
|
+
this.service = service;
|
|
13103
|
+
this.cfService = cfService;
|
|
13104
|
+
this._destroy$ = new Subject();
|
|
13105
|
+
}
|
|
13106
|
+
ngOnInit() {
|
|
13107
|
+
var _a;
|
|
13108
|
+
this.operation = (_a = this.filterExpressionField.expressionData) === null || _a === void 0 ? void 0 : _a.currentOperation;
|
|
13109
|
+
this.currentOperation = this.getOptionLabel(this.operation);
|
|
13110
|
+
}
|
|
13111
|
+
ngAfterViewInit() {
|
|
13112
|
+
this.constructForm();
|
|
13113
|
+
}
|
|
13114
|
+
ngOnDestroy() {
|
|
13115
|
+
this._destroy$.next();
|
|
13116
|
+
this._destroy$.complete();
|
|
13117
|
+
}
|
|
13118
|
+
constructFormWidget(key, label, widgetType, possibleValues, placeholder) {
|
|
13119
|
+
let type = widgetType;
|
|
13120
|
+
if (type === FilterExpressionFieldWidgetType.DATE) {
|
|
13121
|
+
type = SmartFormWidgetType.DATE_PICKER;
|
|
13122
|
+
}
|
|
13123
|
+
else if (type === FilterExpressionFieldWidgetType.DATE_TIME) {
|
|
13124
|
+
type = SmartFormWidgetType.DATE_TIME_PICKER;
|
|
13125
|
+
}
|
|
13126
|
+
let widget = {
|
|
13127
|
+
key,
|
|
13128
|
+
label,
|
|
13129
|
+
type,
|
|
13130
|
+
value: '',
|
|
13131
|
+
placeholder: placeholder,
|
|
13132
|
+
showLabel: true,
|
|
13133
|
+
valueList: possibleValues.map((value) => {
|
|
13134
|
+
return {
|
|
13135
|
+
key: value.objectUri ? value.objectUri : value.code,
|
|
13136
|
+
label: value.displayValue,
|
|
13137
|
+
type: SmartFormWidgetType.ITEM,
|
|
13138
|
+
value: value.objectUri ? value.objectUri : value.code,
|
|
13139
|
+
};
|
|
13140
|
+
}),
|
|
13141
|
+
};
|
|
13142
|
+
return widget;
|
|
13143
|
+
}
|
|
13144
|
+
constructForm() {
|
|
13145
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k;
|
|
13146
|
+
(_a = this.vcRefForm) === null || _a === void 0 ? void 0 : _a.clear();
|
|
13147
|
+
let widgets = [];
|
|
13148
|
+
let key;
|
|
13149
|
+
if (this.filterExpressionField.widgetType === 'SELECT_MULTIPLE') {
|
|
13150
|
+
key = 'expressionData.operand2.selectedValues';
|
|
13151
|
+
}
|
|
13152
|
+
if ((_b = this.filterExpressionField.expressionData) === null || _b === void 0 ? void 0 : _b.operand2) {
|
|
13153
|
+
if (key !== 'expressionData.operand2.selectedValues') {
|
|
13154
|
+
key = 'expressionData.operand2.valueAsString';
|
|
13155
|
+
}
|
|
13156
|
+
widgets.push(this.constructFormWidget(key, this.filterExpressionField.label2, (_c = this.filterExpressionField.widgetType) !== null && _c !== void 0 ? _c : FilterExpressionFieldWidgetType.TEXT_FIELD, this.filterExpressionField.possibleValues, this.filterExpressionField.placeholder2));
|
|
13157
|
+
}
|
|
13158
|
+
if ((_d = this.filterExpressionField.expressionData) === null || _d === void 0 ? void 0 : _d.operand3) {
|
|
13159
|
+
if (key !== 'selectedValues') {
|
|
13160
|
+
key = 'expressionData.operand3.valueAsString';
|
|
13161
|
+
}
|
|
13162
|
+
widgets.push(this.constructFormWidget(key, this.filterExpressionField.label3, (_e = this.filterExpressionField.widgetType) !== null && _e !== void 0 ? _e : FilterExpressionFieldWidgetType.TEXT_FIELD, this.filterExpressionField.possibleValues, this.filterExpressionField.placeholder3));
|
|
13163
|
+
}
|
|
13164
|
+
this.operation = (_f = this.filterExpressionField.expressionData) === null || _f === void 0 ? void 0 : _f.currentOperation;
|
|
13165
|
+
this.currentOperation = this.getOptionLabel(this.operation);
|
|
13166
|
+
this.smartForm = {
|
|
13167
|
+
direction: SmartFormWidgetDirection.ROW,
|
|
13168
|
+
componentModel: { data: this.filterExpressionField },
|
|
13169
|
+
useOnValueChangeEvent: true,
|
|
13170
|
+
useOnBlurEvent: true,
|
|
13171
|
+
submitOnEnter: (_g = this.service.filter) === null || _g === void 0 ? void 0 : _g.submitOnEnter,
|
|
13172
|
+
widgets,
|
|
13173
|
+
translateService: (_h = this.service.filter) === null || _h === void 0 ? void 0 : _h.translateService,
|
|
13174
|
+
};
|
|
13175
|
+
// Show form on page
|
|
13176
|
+
this.componentRefForm = this.cfService.createComponent(this.vcRefForm, SmartformComponent, new Map([['smartForm', this.smartForm]]));
|
|
13177
|
+
(_j = this.componentRefForm.instance.onValueChangeSubject) === null || _j === void 0 ? void 0 : _j.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
13178
|
+
this.submit();
|
|
13179
|
+
this.service.change.next();
|
|
13180
|
+
});
|
|
13181
|
+
(_k = this.componentRefForm.instance.onBlurSubject) === null || _k === void 0 ? void 0 : _k.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
13182
|
+
this.submit();
|
|
13183
|
+
this.service.change.next();
|
|
13184
|
+
});
|
|
13185
|
+
}
|
|
13186
|
+
submit() {
|
|
13187
|
+
var _a;
|
|
13188
|
+
let form = this.componentRefForm.instance.submitForm();
|
|
13189
|
+
this.filterExpressionField = (_a = form.componentModel) === null || _a === void 0 ? void 0 : _a.data;
|
|
13190
|
+
this.simpleFieldChildren.forEach((smartFilterFieldComponent, index) => {
|
|
13191
|
+
let filterExpressionField = smartFilterFieldComponent.submit();
|
|
13192
|
+
this.filterExpressionField.subFieldList.filters[index] = filterExpressionField;
|
|
13193
|
+
});
|
|
13194
|
+
return this.filterExpressionField;
|
|
13195
|
+
}
|
|
13196
|
+
optionSelected(option) {
|
|
13197
|
+
var _a, _b, _c, _d;
|
|
13198
|
+
let oldOption = this.componentRefForm.instance.smartForm.componentModel.data.expressionData
|
|
13199
|
+
.currentOperation;
|
|
13200
|
+
this.componentRefForm.instance.smartForm.componentModel.data.expressionData.currentOperation =
|
|
13201
|
+
option;
|
|
13202
|
+
this.operation = option;
|
|
13203
|
+
this.currentOperation = this.getOptionLabel(this.operation);
|
|
13204
|
+
if (oldOption !== FilterExpressionOperation.BETWEEN &&
|
|
13205
|
+
option === FilterExpressionOperation.BETWEEN) {
|
|
13206
|
+
this.submit();
|
|
13207
|
+
let label = this.filterExpressionField.label2;
|
|
13208
|
+
this.filterExpressionField.label2 = `${label} - tól`;
|
|
13209
|
+
this.filterExpressionField.label3 = `${label} - ig`;
|
|
13210
|
+
this.filterExpressionField.expressionData.operand3 = {
|
|
13211
|
+
isDataName: (_a = this.filterExpressionField.expressionData.operand2) === null || _a === void 0 ? void 0 : _a.isDataName,
|
|
13212
|
+
type: (_b = this.filterExpressionField.expressionData.operand3) === null || _b === void 0 ? void 0 : _b.type,
|
|
13213
|
+
valueAsString: (_c = this.filterExpressionField.expressionData.operand3) === null || _c === void 0 ? void 0 : _c.valueAsString,
|
|
13214
|
+
selectedValues: (_d = this.filterExpressionField.expressionData.operand3) === null || _d === void 0 ? void 0 : _d.selectedValues,
|
|
13215
|
+
};
|
|
13216
|
+
this.constructForm();
|
|
13217
|
+
}
|
|
13218
|
+
else if (oldOption === FilterExpressionOperation.BETWEEN &&
|
|
13219
|
+
option !== FilterExpressionOperation.BETWEEN) {
|
|
13220
|
+
let label = this.filterExpressionField.label2.replace(' - tól', '');
|
|
13221
|
+
this.filterExpressionField.label2 = `${label}`;
|
|
13222
|
+
this.filterExpressionField.label3 = undefined;
|
|
13223
|
+
this.filterExpressionField.expressionData.operand3 = undefined;
|
|
13224
|
+
this.constructForm();
|
|
13225
|
+
}
|
|
13226
|
+
}
|
|
13227
|
+
getOptionLabel(option) {
|
|
13228
|
+
if (!option) {
|
|
13229
|
+
return '';
|
|
13230
|
+
}
|
|
13231
|
+
else if (this.operationTranslator) {
|
|
13232
|
+
return this.operationTranslator(option);
|
|
13233
|
+
}
|
|
13234
|
+
return option;
|
|
13235
|
+
}
|
|
13236
|
+
}
|
|
13237
|
+
SmartFilterSimpleFieldComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterSimpleFieldComponent, deps: [{ token: SmartFilterService }, { token: ComponentFactoryService }], target: i0.ɵɵFactoryTarget.Component });
|
|
13238
|
+
SmartFilterSimpleFieldComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartFilterSimpleFieldComponent, selector: "smart-filter-simple-field", inputs: { operationTranslator: "operationTranslator", filterExpressionField: "filterExpressionField", showPossibleActions: "showPossibleActions" }, viewQueries: [{ propertyName: "vcRefForm", first: true, predicate: ["form"], descendants: true, read: ViewContainerRef }, { propertyName: "simpleFieldChildren", predicate: ["simpleField"], descendants: true }], ngImport: i0, template: "<div class=\"smart-filter-simple-field-container\">\r\n <div class=\"smart-filter-simple-field-form-widget\">\r\n <div\r\n class=\"smart-filter-simple-field-form-widget-row\"\r\n *ngIf=\"showPossibleActions\"\r\n >\r\n <p>({{ currentOperation }})</p>\r\n <button\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n aria-label=\"Example icon-button with a menu\"\r\n >\r\n <mat-icon>more_vert</mat-icon>\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <button\r\n mat-menu-item\r\n *ngFor=\"let option of filterExpressionField.possibleOperations\"\r\n (click)=\"optionSelected(option)\"\r\n >\r\n <span>\r\n {{ getOptionLabel(option) }}\r\n </span>\r\n </button>\r\n </mat-menu>\r\n </div>\r\n <ng-template #form></ng-template>\r\n </div>\r\n</div>\r\n", styles: [".smart-filter-simple-field-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem}.smart-filter-simple-field-form-widget{padding:1rem;border-radius:1rem;display:flex;flex-direction:column}.smart-filter-simple-field-form-widget-row{display:flex;flex-direction:row;justify-content:space-between}.smart-filter-simple-field-form-widget-row p{color:#00000042}.smart-filter-simple-field-form-widget ::ng-deep .mat-icon-button{height:24px;width:24px}.smart-filter-simple-field-form-widget ::ng-deep .mat-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-flat-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-stroked-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-raised-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-icon-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-fab .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-mini-fab .mat-button-wrapper>*{vertical-align:inherit!important}.smart-filter-simple-field-subfields-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem}.smart-filter-simple-field-container ::ng-deep h4{margin:0}\n"], components: [{ type: i3.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: i3$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
13239
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterSimpleFieldComponent, decorators: [{
|
|
13240
|
+
type: Component,
|
|
13241
|
+
args: [{ selector: 'smart-filter-simple-field', template: "<div class=\"smart-filter-simple-field-container\">\r\n <div class=\"smart-filter-simple-field-form-widget\">\r\n <div\r\n class=\"smart-filter-simple-field-form-widget-row\"\r\n *ngIf=\"showPossibleActions\"\r\n >\r\n <p>({{ currentOperation }})</p>\r\n <button\r\n mat-icon-button\r\n [matMenuTriggerFor]=\"menu\"\r\n aria-label=\"Example icon-button with a menu\"\r\n >\r\n <mat-icon>more_vert</mat-icon>\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <button\r\n mat-menu-item\r\n *ngFor=\"let option of filterExpressionField.possibleOperations\"\r\n (click)=\"optionSelected(option)\"\r\n >\r\n <span>\r\n {{ getOptionLabel(option) }}\r\n </span>\r\n </button>\r\n </mat-menu>\r\n </div>\r\n <ng-template #form></ng-template>\r\n </div>\r\n</div>\r\n", styles: [".smart-filter-simple-field-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem}.smart-filter-simple-field-form-widget{padding:1rem;border-radius:1rem;display:flex;flex-direction:column}.smart-filter-simple-field-form-widget-row{display:flex;flex-direction:row;justify-content:space-between}.smart-filter-simple-field-form-widget-row p{color:#00000042}.smart-filter-simple-field-form-widget ::ng-deep .mat-icon-button{height:24px;width:24px}.smart-filter-simple-field-form-widget ::ng-deep .mat-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-flat-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-stroked-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-raised-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-icon-button .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-fab .mat-button-wrapper>*,.smart-filter-simple-field-form-widget ::ng-deep .mat-mini-fab .mat-button-wrapper>*{vertical-align:inherit!important}.smart-filter-simple-field-subfields-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem}.smart-filter-simple-field-container ::ng-deep h4{margin:0}\n"] }]
|
|
13242
|
+
}], ctorParameters: function () { return [{ type: SmartFilterService }, { type: ComponentFactoryService }]; }, propDecorators: { simpleFieldChildren: [{
|
|
13243
|
+
type: ViewChildren,
|
|
13244
|
+
args: ['simpleField']
|
|
13245
|
+
}], operationTranslator: [{
|
|
13246
|
+
type: Input
|
|
13247
|
+
}], filterExpressionField: [{
|
|
13248
|
+
type: Input
|
|
13249
|
+
}], showPossibleActions: [{
|
|
13250
|
+
type: Input
|
|
13251
|
+
}], vcRefForm: [{
|
|
13252
|
+
type: ViewChild,
|
|
13253
|
+
args: ['form', { read: ViewContainerRef }]
|
|
13254
|
+
}] } });
|
|
13255
|
+
|
|
13256
|
+
class SmartFilterSimpleComponent {
|
|
13257
|
+
constructor(service) {
|
|
13258
|
+
this.service = service;
|
|
13259
|
+
this._destroy$ = new Subject();
|
|
13260
|
+
this.service.reSubscribeToSubmit.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
13261
|
+
this.subscribeToSubmit();
|
|
13262
|
+
});
|
|
13263
|
+
this.subscribeToSubmit();
|
|
13264
|
+
}
|
|
13265
|
+
ngOnInit() {
|
|
13266
|
+
this.smartFilter = this.service.filter;
|
|
13267
|
+
}
|
|
13268
|
+
ngOnDestroy() {
|
|
13269
|
+
this._destroy$.next();
|
|
13270
|
+
this._destroy$.complete();
|
|
13271
|
+
}
|
|
13272
|
+
subscribeToSubmit() {
|
|
13273
|
+
this.service.shouldSubmit.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
13274
|
+
this.submit();
|
|
13275
|
+
});
|
|
13276
|
+
}
|
|
13277
|
+
submit() {
|
|
13278
|
+
this.simpleFieldChildren.forEach((smartFilterFieldComponent, index) => {
|
|
13279
|
+
this.smartFilter.data[index] = smartFilterFieldComponent.submit();
|
|
13280
|
+
});
|
|
13281
|
+
this.service.filter = this.smartFilter;
|
|
13282
|
+
this.service.shouldSubmit.complete();
|
|
13283
|
+
}
|
|
13284
|
+
}
|
|
13285
|
+
SmartFilterSimpleComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterSimpleComponent, deps: [{ token: SmartFilterService }], target: i0.ɵɵFactoryTarget.Component });
|
|
13286
|
+
SmartFilterSimpleComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartFilterSimpleComponent, selector: "smart-filter-simple", viewQueries: [{ propertyName: "simpleFieldChildren", predicate: ["simpleField"], descendants: true }], ngImport: i0, template: "<div *ngIf=\"smartFilter\" class=\"smart-simple-fields-container\">\r\n <div *ngFor=\"let filterExpressionField of smartFilter.data; let i = index\">\r\n <smart-filter-simple-field\r\n #simpleField\r\n [filterExpressionField]=\"filterExpressionField\"\r\n [operationTranslator]=\"smartFilter.operationTranslator\"\r\n [showPossibleActions]=\"smartFilter.showPossibleActions\"\r\n ></smart-filter-simple-field>\r\n <div *ngFor=\"let subfilterExpressionField of filterExpressionField.subFieldList?.filters\">\r\n <smart-filter-simple-field\r\n #simpleField\r\n [filterExpressionField]=\"filterExpressionField\"\r\n [operationTranslator]=\"smartFilter.operationTranslator\"\r\n [showPossibleActions]=\"smartFilter.showPossibleActions\"\r\n ></smart-filter-simple-field>\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".smart-simple-fields-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem;justify-content:center}\n"], components: [{ type: SmartFilterSimpleFieldComponent, selector: "smart-filter-simple-field", inputs: ["operationTranslator", "filterExpressionField", "showPossibleActions"] }], directives: [{ type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
13287
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterSimpleComponent, decorators: [{
|
|
13288
|
+
type: Component,
|
|
13289
|
+
args: [{ selector: "smart-filter-simple", template: "<div *ngIf=\"smartFilter\" class=\"smart-simple-fields-container\">\r\n <div *ngFor=\"let filterExpressionField of smartFilter.data; let i = index\">\r\n <smart-filter-simple-field\r\n #simpleField\r\n [filterExpressionField]=\"filterExpressionField\"\r\n [operationTranslator]=\"smartFilter.operationTranslator\"\r\n [showPossibleActions]=\"smartFilter.showPossibleActions\"\r\n ></smart-filter-simple-field>\r\n <div *ngFor=\"let subfilterExpressionField of filterExpressionField.subFieldList?.filters\">\r\n <smart-filter-simple-field\r\n #simpleField\r\n [filterExpressionField]=\"filterExpressionField\"\r\n [operationTranslator]=\"smartFilter.operationTranslator\"\r\n [showPossibleActions]=\"smartFilter.showPossibleActions\"\r\n ></smart-filter-simple-field>\r\n </div>\r\n </div>\r\n</div>\r\n", styles: [".smart-simple-fields-container{display:flex;flex-direction:row;flex-wrap:wrap;gap:1rem;justify-content:center}\n"] }]
|
|
13290
|
+
}], ctorParameters: function () { return [{ type: SmartFilterService }]; }, propDecorators: { simpleFieldChildren: [{
|
|
13291
|
+
type: ViewChildren,
|
|
13292
|
+
args: ["simpleField"]
|
|
13293
|
+
}] } });
|
|
13294
|
+
|
|
13295
|
+
class SmartFilterComponent {
|
|
13296
|
+
constructor(service) {
|
|
13297
|
+
this.service = service;
|
|
13298
|
+
}
|
|
13299
|
+
ngOnInit() {
|
|
13300
|
+
if (this.filter) {
|
|
13301
|
+
this.setUp();
|
|
13302
|
+
}
|
|
13303
|
+
}
|
|
13304
|
+
ngOnChanges(changes) {
|
|
13305
|
+
if (changes['filter'].currentValue) {
|
|
13306
|
+
this.setUp();
|
|
13307
|
+
}
|
|
13308
|
+
}
|
|
13309
|
+
setUp() {
|
|
13310
|
+
this.service.filter = this.filter;
|
|
13311
|
+
}
|
|
13312
|
+
submit() {
|
|
13313
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
13314
|
+
return yield this.service.submit();
|
|
13315
|
+
});
|
|
13316
|
+
}
|
|
13317
|
+
}
|
|
13318
|
+
SmartFilterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterComponent, deps: [{ token: SmartFilterService }], target: i0.ɵɵFactoryTarget.Component });
|
|
13319
|
+
SmartFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartFilterComponent, selector: "smart-filter", inputs: { filter: "filter" }, providers: [SmartFilterService], usesOnChanges: true, ngImport: i0, template: "<smart-filter-simple *ngIf=\"filter\" #simpleFilter></smart-filter-simple>\r\n", styles: [""], components: [{ type: SmartFilterSimpleComponent, selector: "smart-filter-simple" }], directives: [{ type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
13320
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterComponent, decorators: [{
|
|
13321
|
+
type: Component,
|
|
13322
|
+
args: [{ selector: 'smart-filter', providers: [SmartFilterService], template: "<smart-filter-simple *ngIf=\"filter\" #simpleFilter></smart-filter-simple>\r\n", styles: [""] }]
|
|
13323
|
+
}], ctorParameters: function () { return [{ type: SmartFilterService }]; }, propDecorators: { filter: [{
|
|
13324
|
+
type: Input
|
|
13325
|
+
}] } });
|
|
13326
|
+
|
|
13327
|
+
class SmartFilterExpressionFieldComponent {
|
|
13328
|
+
constructor() { }
|
|
13329
|
+
ngOnInit() {
|
|
13330
|
+
}
|
|
13331
|
+
}
|
|
13332
|
+
SmartFilterExpressionFieldComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterExpressionFieldComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
13333
|
+
SmartFilterExpressionFieldComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartFilterExpressionFieldComponent, selector: "lib-smart-filter-expression-field", ngImport: i0, template: "", styles: [""] });
|
|
13334
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterExpressionFieldComponent, decorators: [{
|
|
13335
|
+
type: Component,
|
|
13336
|
+
args: [{ selector: 'lib-smart-filter-expression-field', template: "", styles: [""] }]
|
|
13337
|
+
}], ctorParameters: function () { return []; } });
|
|
13338
|
+
|
|
13339
|
+
class SmartFilterModule {
|
|
13340
|
+
}
|
|
13341
|
+
SmartFilterModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
13342
|
+
SmartFilterModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterModule, declarations: [SmartFilterComponent,
|
|
13343
|
+
SmartFilterExpressionFieldComponent,
|
|
13344
|
+
SmartFilterSimpleComponent,
|
|
13345
|
+
SmartFilterSimpleFieldComponent], imports: [BrowserModule, SmartformModule, MatMenuModule, MatIconModule, MatButtonModule], exports: [SmartFilterComponent] });
|
|
13346
|
+
SmartFilterModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterModule, imports: [[BrowserModule, SmartformModule, MatMenuModule, MatIconModule, MatButtonModule]] });
|
|
13347
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartFilterModule, decorators: [{
|
|
13348
|
+
type: NgModule,
|
|
13349
|
+
args: [{
|
|
13350
|
+
declarations: [
|
|
13351
|
+
SmartFilterComponent,
|
|
13352
|
+
SmartFilterExpressionFieldComponent,
|
|
13353
|
+
SmartFilterSimpleComponent,
|
|
13354
|
+
SmartFilterSimpleFieldComponent,
|
|
13355
|
+
],
|
|
13356
|
+
imports: [BrowserModule, SmartformModule, MatMenuModule, MatIconModule, MatButtonModule],
|
|
13357
|
+
exports: [SmartFilterComponent],
|
|
13358
|
+
}]
|
|
13359
|
+
}] });
|
|
13360
|
+
|
|
13361
|
+
var SmartFilterPosition;
|
|
13362
|
+
(function (SmartFilterPosition) {
|
|
13363
|
+
SmartFilterPosition[SmartFilterPosition["TOP"] = 0] = "TOP";
|
|
13364
|
+
SmartFilterPosition[SmartFilterPosition["BOTTOM"] = 1] = "BOTTOM";
|
|
13365
|
+
SmartFilterPosition[SmartFilterPosition["LEFT"] = 2] = "LEFT";
|
|
13366
|
+
SmartFilterPosition[SmartFilterPosition["RIGHT"] = 3] = "RIGHT";
|
|
13367
|
+
})(SmartFilterPosition || (SmartFilterPosition = {}));
|
|
13368
|
+
var SmartFilterType;
|
|
13369
|
+
(function (SmartFilterType) {
|
|
13370
|
+
SmartFilterType[SmartFilterType["SIMPLE"] = 0] = "SIMPLE";
|
|
13371
|
+
SmartFilterType[SmartFilterType["ADVANCED"] = 1] = "ADVANCED";
|
|
13372
|
+
})(SmartFilterType || (SmartFilterType = {}));
|
|
13373
|
+
|
|
13374
|
+
/*
|
|
13375
|
+
* Public API Surface of smart-filter
|
|
13376
|
+
*/
|
|
13377
|
+
|
|
13356
13378
|
var FilterExpressionBuilderUiModelTypeEnum;
|
|
13357
13379
|
(function (FilterExpressionBuilderUiModelTypeEnum) {
|
|
13358
13380
|
FilterExpressionBuilderUiModelTypeEnum["SIMPLE"] = "SIMPLE";
|
|
@@ -13549,28 +13571,28 @@ class SmartFilterEditorContentComponent {
|
|
|
13549
13571
|
model[index] = filterExpressionField;
|
|
13550
13572
|
if (filterExpressionField.widgetType === 'SELECT_MULTIPLE') {
|
|
13551
13573
|
key = index + '.expressionData.operand2.selectedValues';
|
|
13552
|
-
widgets.push(this.constructFormWidget(key, filterExpressionField.label2, (_a = filterExpressionField.widgetType) !== null && _a !== void 0 ? _a : FilterExpressionFieldWidgetType.
|
|
13574
|
+
widgets.push(this.constructFormWidget(key, filterExpressionField.label2, (_a = filterExpressionField.widgetType) !== null && _a !== void 0 ? _a : FilterExpressionFieldWidgetType.TEXT_FIELD, filterExpressionField.possibleValues, (_d = (_c = (_b = filterExpressionField.expressionData) === null || _b === void 0 ? void 0 : _b.operand2) === null || _c === void 0 ? void 0 : _c.valueAsString) !== null && _d !== void 0 ? _d : ''));
|
|
13553
13575
|
return;
|
|
13554
13576
|
}
|
|
13555
13577
|
if (((_e = filterExpressionField.expressionData) === null || _e === void 0 ? void 0 : _e.currentOperation) === 'BETWEEN') {
|
|
13556
13578
|
key = index + '.expressionData.operand2.valueAsString';
|
|
13557
|
-
widgets.push(this.constructFormWidget(key, filterExpressionField.label2, (_f = filterExpressionField.widgetType) !== null && _f !== void 0 ? _f : FilterExpressionFieldWidgetType.
|
|
13579
|
+
widgets.push(this.constructFormWidget(key, filterExpressionField.label2, (_f = filterExpressionField.widgetType) !== null && _f !== void 0 ? _f : FilterExpressionFieldWidgetType.TEXT_FIELD, filterExpressionField.possibleValues, (_j = (_h = (_g = filterExpressionField.expressionData) === null || _g === void 0 ? void 0 : _g.operand2) === null || _h === void 0 ? void 0 : _h.valueAsString) !== null && _j !== void 0 ? _j : ''));
|
|
13558
13580
|
key = index + '.expressionData.operand3.valueAsString';
|
|
13559
|
-
widgets.push(this.constructFormWidget(key, filterExpressionField.label3, (_k = filterExpressionField.widgetType) !== null && _k !== void 0 ? _k : FilterExpressionFieldWidgetType.
|
|
13581
|
+
widgets.push(this.constructFormWidget(key, filterExpressionField.label3, (_k = filterExpressionField.widgetType) !== null && _k !== void 0 ? _k : FilterExpressionFieldWidgetType.TEXT_FIELD, filterExpressionField.possibleValues, (_o = (_m = (_l = filterExpressionField.expressionData) === null || _l === void 0 ? void 0 : _l.operand3) === null || _m === void 0 ? void 0 : _m.valueAsString) !== null && _o !== void 0 ? _o : ''));
|
|
13560
13582
|
return;
|
|
13561
13583
|
}
|
|
13562
13584
|
if ((_p = filterExpressionField.expressionData) === null || _p === void 0 ? void 0 : _p.operand2) {
|
|
13563
13585
|
if (key !== index + '.expressionData.operand2.selectedValues') {
|
|
13564
13586
|
key = index + '.expressionData.operand2.valueAsString';
|
|
13565
13587
|
}
|
|
13566
|
-
widgets.push(this.constructFormWidget(key, filterExpressionField.label2, (_q = filterExpressionField.widgetType) !== null && _q !== void 0 ? _q : FilterExpressionFieldWidgetType.
|
|
13588
|
+
widgets.push(this.constructFormWidget(key, filterExpressionField.label2, (_q = filterExpressionField.widgetType) !== null && _q !== void 0 ? _q : FilterExpressionFieldWidgetType.TEXT_FIELD, filterExpressionField.possibleValues, (_t = (_s = (_r = filterExpressionField.expressionData) === null || _r === void 0 ? void 0 : _r.operand2) === null || _s === void 0 ? void 0 : _s.valueAsString) !== null && _t !== void 0 ? _t : ''));
|
|
13567
13589
|
return;
|
|
13568
13590
|
}
|
|
13569
13591
|
if ((_u = filterExpressionField === null || filterExpressionField === void 0 ? void 0 : filterExpressionField.expressionData) === null || _u === void 0 ? void 0 : _u.operand3) {
|
|
13570
13592
|
if (key !== index + '.selectedValues') {
|
|
13571
13593
|
key = index + '.expressionData.operand3.valueAsString';
|
|
13572
13594
|
}
|
|
13573
|
-
widgets.push(this.constructFormWidget(key, filterExpressionField.label3, (_v = filterExpressionField.widgetType) !== null && _v !== void 0 ? _v : FilterExpressionFieldWidgetType.
|
|
13595
|
+
widgets.push(this.constructFormWidget(key, filterExpressionField.label3, (_v = filterExpressionField.widgetType) !== null && _v !== void 0 ? _v : FilterExpressionFieldWidgetType.TEXT_FIELD, filterExpressionField.possibleValues, (_y = (_x = (_w = filterExpressionField.expressionData) === null || _w === void 0 ? void 0 : _w.operand3) === null || _x === void 0 ? void 0 : _x.valueAsString) !== null && _y !== void 0 ? _y : ''));
|
|
13574
13596
|
return;
|
|
13575
13597
|
}
|
|
13576
13598
|
});
|
|
@@ -13684,10 +13706,10 @@ class SmartFilterEditorContentComponent {
|
|
|
13684
13706
|
}
|
|
13685
13707
|
constructFormWidget(key, label, widgetType, possibleValues, value) {
|
|
13686
13708
|
let type = widgetType;
|
|
13687
|
-
if (type === FilterExpressionFieldWidgetType.
|
|
13709
|
+
if (type === FilterExpressionFieldWidgetType.DATE) {
|
|
13688
13710
|
type = SmartFormWidgetType.DATE_PICKER;
|
|
13689
13711
|
}
|
|
13690
|
-
else if (type === FilterExpressionFieldWidgetType.
|
|
13712
|
+
else if (type === FilterExpressionFieldWidgetType.DATE_TIME) {
|
|
13691
13713
|
type = SmartFormWidgetType.DATE_TIME_PICKER;
|
|
13692
13714
|
}
|
|
13693
13715
|
let widget = {
|
|
@@ -15398,5 +15420,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
|
|
|
15398
15420
|
* Generated bundle index. Do not edit.
|
|
15399
15421
|
*/
|
|
15400
15422
|
|
|
15401
|
-
export { APIS$3 as APIS, ApiModule$3 as ApiModule, ApiQueueService, BASE_PATH$5 as BASE_PATH, COLLECTION_FORMATS$5 as COLLECTION_FORMATS, CloseResult, ComponentFactoryService, ComponentFactoryServiceModule, ComponentType, ComponentWidgetType, Configuration$5 as Configuration, DIALOG_DISABLE_CLOSE, DataChangeKind, DefaultUiActionCode_CLOSE, ExpandableSectionButtonIconPosition, ExpandableSectionButtonType, ExpandableSectionComponent, FilterExpressionBoolOperator$1 as FilterExpressionBoolOperator,
|
|
15423
|
+
export { APIS$3 as APIS, ApiModule$3 as ApiModule, ApiQueueService, BASE_PATH$5 as BASE_PATH, COLLECTION_FORMATS$5 as COLLECTION_FORMATS, CloseResult, ComponentFactoryService, ComponentFactoryServiceModule, ComponentType, ComponentWidgetType, Configuration$5 as Configuration, DIALOG_DISABLE_CLOSE, DataChangeKind, DefaultUiActionCode_CLOSE, ExpandableSectionButtonIconPosition, ExpandableSectionButtonType, ExpandableSectionComponent, FilterExpressionBoolOperator$1 as FilterExpressionBoolOperator, FilterExpressionBuilderGroupBuilderGroupKindEnum, FilterExpressionDataType, FilterExpressionFieldWidgetType, FilterExpressionOperation, FilterExpressionOrderByOrderEnum, GridColumnContentType, GridDataAccessConfigKindEnum, GridSelectionMode, GridSelectionType, GridUiActionType, GridViewDescriptorKindEnum, IS_ASYNC_PARAM_NAME, IconPosition, ImageResourceKindEnum, LayoutDirection, LinkTargetEnum, MessageOptionType, MessageTextType, MessageType, SelectionDefinitionTypeEnum, SessionAPIS, SessionErrorBehaviour, SessionService, SharedModule, SimplifiedTabGroupComponent, SmartActionType, SmartAuthService, SmartComponent, SmartComponentApiClient, SmartComponentLayoutComponent, SmartComponentLayoutModule, SmartComponentLayoutUtility, SmartDatePipe, SmartDateTimePipe, SmartDialog, SmartExpandableSectionModule, SmartExpandableSectionService, SmartFileUploaderComponent, SmartFilterComponent, SmartFilterEditorContentComponent, SmartFilterEditorModule, SmartFilterEditorService, SmartFilterExpressionItemComponent, SmartFilterExpressionItemsComponent, SmartFilterModule, SmartFilterParamComponent, SmartFilterParamsComponent, SmartFilterPosition, SmartFilterType, SmartFormTextFieldButtonIconPosition, SmartFormWidgetDirection, SmartFormWidgetType, SmartFormWidgetWidth, SmartGridButtonType, SmartGridComponent, SmartGridDataLayout, SmartGridModule, SmartGridService, SmartGridType, SmartIconComponent, SmartIconModule, SmartIconService, SmartLayoutDef, SmartLinkChannelVariableInPath, SmartLinkUuidVariableInPath, SmartNavbarComponent, SmartNavbarModule, SmartNavbarService, SmartNavigationModule, SmartNavigationService, SmartNgClientModule, SmartNgClientService, SmartService, SmartSessionModule, SmartSessionService, SmartSessionTimerComponent, SmartSessionTimerService, SmartSubject, SmartTabGroupModule, SmartTabGroupService, SmartTable, SmartTableButtonType, SmartTableHeaderPropertyType, SmartTableInterfaceTypeEnum, SmartTableOptionButtonDirection, SmartTableOrder, SmartTableType, SmartTimePipe, SmartTooltipDirective, SmartTreeComponent, SmartTreeNodeButtonType, SmartUserSettinsIconPosition, SmartValidatorName, SmartViewContextErrorDialogButtonLabel, SmartViewContextErrorDialogMessage, SmartViewContextErrorDialogTitle, SmartViewContextModule, SmartViewContextService, SmartViewRedirect, SmartWidgetHintPosition, SmartWidgetHintPositionEnum, SmartWidgetSettings, SmartdialogModule, SmartdialogService, SmartfileuploaderComponent, SmartformComponent, SmartformLayoutDefinitionService, SmartformModule, SmartformwidgetComponent, SmarttableComponent, SmarttableModule, SmarttableService, SmarttreeGenericService, SmarttreeModule, SmarttreeService, TabGroupComponent, ToggleLabelPosition, UiActionButtonType, UiActionConfirmDialogComponent, UiActionConfirmDialogService, UiActionDescriptorService, UiActionDialogType, UiActionFeedbackType, UiActionInputDialogComponent, UiActionInputDialogService, UiActionInputType, UiActionService, UiActionToolbarComponent, UiActionTooltipTooltipPositionEnum, ViewEventHandlerViewEventTypeEnum, ViewService, ViewState, ViewType, WidgetMap };
|
|
15402
15424
|
//# sourceMappingURL=smartbit4all-ng-client.mjs.map
|