@pepperi-addons/ngx-lib 0.4.2-beta.99 → 0.4.2-scroll.1
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/chips/chips.component.d.ts +1 -3
- package/core/common/pipes/common-pipes.d.ts +3 -0
- package/core/customization/customization.model.d.ts +1 -1
- package/esm2020/checkbox/checkbox.component.mjs +3 -3
- package/esm2020/chips/chips.component.mjs +8 -11
- package/esm2020/color/color.component.mjs +3 -3
- package/esm2020/core/common/pipes/common-pipes.mjs +14 -4
- package/esm2020/core/customization/customization.model.mjs +7 -1
- package/esm2020/core/customization/customization.service.mjs +2 -1
- package/esm2020/core/http/services/loader.service.mjs +3 -3
- package/esm2020/draggable-items/draggable-items.component.mjs +3 -3
- package/esm2020/form/field-generator.component.mjs +3 -3
- package/esm2020/form/form.component.mjs +3 -3
- package/esm2020/form/internal-carusel.component.mjs +10 -6
- package/esm2020/form/internal-field-generator.component.mjs +3 -3
- package/esm2020/form/internal-form.component.mjs +3 -3
- package/esm2020/form/internal-menu.component.mjs +4 -6
- package/esm2020/form/internal-page.component.mjs +3 -4
- package/esm2020/image/image.component.mjs +3 -3
- package/esm2020/images-filmstrip/images-filmstrip.component.mjs +3 -3
- package/esm2020/link/link.component.mjs +9 -3
- package/esm2020/list/list-actions.component.mjs +1 -1
- package/esm2020/list/list-chooser.component.mjs +1 -1
- package/esm2020/list/list-sorting.component.mjs +1 -1
- package/esm2020/list/list-views.component.mjs +1 -1
- package/esm2020/list/list.component.mjs +22 -10
- package/esm2020/list/list.model.mjs +1 -1
- package/esm2020/menu/menu-item.component.mjs +3 -3
- package/esm2020/menu/menu.component.mjs +6 -3
- package/esm2020/menu/menu.model.mjs +2 -1
- package/esm2020/profile-data-views-list/profile-data-view/profile-data-view.component.mjs +1 -1
- package/esm2020/profile-data-views-list/profile-data-views-card/profile-data-views-card.component.mjs +25 -9
- package/esm2020/profile-data-views-list/profile-data-views-list.component.mjs +58 -26
- package/esm2020/profile-data-views-list/profile-data-views-list.model.mjs +1 -1
- package/esm2020/quantity-selector/quantity-selector.component.mjs +7 -3
- package/esm2020/query-builder/common/model/legacy.mjs +1 -1
- package/esm2020/query-builder/common/model/operator.mjs +72 -62
- package/esm2020/query-builder/common/services/output-query.service.mjs +5 -3
- package/esm2020/query-builder/common/services/query-structure.service.mjs +24 -1
- package/esm2020/query-builder/query-builder-item/query-builder-item.component.mjs +3 -3
- package/esm2020/query-builder/query-builder-section/query-builder-section.component.mjs +3 -3
- package/esm2020/query-builder/query-builder.module.mjs +14 -3
- package/esm2020/query-builder/query-builder.service.mjs +2 -2
- package/esm2020/remote-loader/remote-loader.service.mjs +16 -16
- package/esm2020/rich-html-textarea/rich-html-textarea.component.mjs +10 -3
- package/esm2020/select/select.component.mjs +3 -3
- package/esm2020/select-panel/select-panel.component.mjs +3 -5
- package/esm2020/signature/signature-dialog.component.mjs +2 -1
- package/esm2020/signature/signature.component.mjs +4 -4
- package/esm2020/skeleton-loader/public-api.mjs +2 -2
- package/esm2020/skeleton-loader/skeleton-loader.component.mjs +3 -3
- package/esm2020/smart-filters/common/model/operator.mjs +11 -4
- package/esm2020/smart-filters/common/model/type.mjs +1 -1
- package/esm2020/smart-filters/multi-select-filter/multi-select-filter.component.mjs +3 -3
- package/esm2020/smart-filters/text-filter/text-filter.component.mjs +3 -3
- package/esm2020/textbox/textbox.component.mjs +26 -6
- package/fesm2015/pepperi-addons-ngx-lib-checkbox.mjs +2 -2
- package/fesm2015/pepperi-addons-ngx-lib-checkbox.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-chips.mjs +7 -10
- package/fesm2015/pepperi-addons-ngx-lib-chips.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-color.mjs +2 -2
- package/fesm2015/pepperi-addons-ngx-lib-color.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-draggable-items.mjs +2 -2
- package/fesm2015/pepperi-addons-ngx-lib-draggable-items.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-form.mjs +22 -21
- package/fesm2015/pepperi-addons-ngx-lib-form.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-image.mjs +2 -2
- package/fesm2015/pepperi-addons-ngx-lib-image.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-images-filmstrip.mjs +2 -2
- package/fesm2015/pepperi-addons-ngx-lib-images-filmstrip.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-link.mjs +8 -2
- package/fesm2015/pepperi-addons-ngx-lib-link.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-list.mjs +25 -13
- package/fesm2015/pepperi-addons-ngx-lib-list.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-menu.mjs +8 -4
- package/fesm2015/pepperi-addons-ngx-lib-menu.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-profile-data-views-list.mjs +81 -33
- package/fesm2015/pepperi-addons-ngx-lib-profile-data-views-list.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-quantity-selector.mjs +7 -2
- package/fesm2015/pepperi-addons-ngx-lib-quantity-selector.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-query-builder.mjs +119 -70
- package/fesm2015/pepperi-addons-ngx-lib-query-builder.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-remote-loader.mjs +16 -16
- package/fesm2015/pepperi-addons-ngx-lib-remote-loader.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-rich-html-textarea.mjs +9 -2
- package/fesm2015/pepperi-addons-ngx-lib-rich-html-textarea.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-select-panel.mjs +2 -4
- package/fesm2015/pepperi-addons-ngx-lib-select-panel.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-select.mjs +2 -2
- package/fesm2015/pepperi-addons-ngx-lib-select.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-signature.mjs +5 -3
- package/fesm2015/pepperi-addons-ngx-lib-signature.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-skeleton-loader.mjs +3 -3
- package/fesm2015/pepperi-addons-ngx-lib-skeleton-loader.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-smart-filters.mjs +14 -7
- package/fesm2015/pepperi-addons-ngx-lib-smart-filters.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib-textbox.mjs +26 -5
- package/fesm2015/pepperi-addons-ngx-lib-textbox.mjs.map +1 -1
- package/fesm2015/pepperi-addons-ngx-lib.mjs +547 -532
- package/fesm2015/pepperi-addons-ngx-lib.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-checkbox.mjs +2 -2
- package/fesm2020/pepperi-addons-ngx-lib-checkbox.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-chips.mjs +7 -10
- package/fesm2020/pepperi-addons-ngx-lib-chips.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-color.mjs +2 -2
- package/fesm2020/pepperi-addons-ngx-lib-color.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-draggable-items.mjs +2 -2
- package/fesm2020/pepperi-addons-ngx-lib-draggable-items.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-form.mjs +22 -21
- package/fesm2020/pepperi-addons-ngx-lib-form.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-image.mjs +2 -2
- package/fesm2020/pepperi-addons-ngx-lib-image.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-images-filmstrip.mjs +2 -2
- package/fesm2020/pepperi-addons-ngx-lib-images-filmstrip.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-link.mjs +8 -2
- package/fesm2020/pepperi-addons-ngx-lib-link.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-list.mjs +25 -13
- package/fesm2020/pepperi-addons-ngx-lib-list.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-menu.mjs +8 -4
- package/fesm2020/pepperi-addons-ngx-lib-menu.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-profile-data-views-list.mjs +81 -33
- package/fesm2020/pepperi-addons-ngx-lib-profile-data-views-list.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-quantity-selector.mjs +6 -2
- package/fesm2020/pepperi-addons-ngx-lib-quantity-selector.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-query-builder.mjs +115 -69
- package/fesm2020/pepperi-addons-ngx-lib-query-builder.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-remote-loader.mjs +15 -15
- package/fesm2020/pepperi-addons-ngx-lib-remote-loader.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-rich-html-textarea.mjs +9 -2
- package/fesm2020/pepperi-addons-ngx-lib-rich-html-textarea.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-select-panel.mjs +2 -4
- package/fesm2020/pepperi-addons-ngx-lib-select-panel.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-select.mjs +2 -2
- package/fesm2020/pepperi-addons-ngx-lib-select.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-signature.mjs +4 -3
- package/fesm2020/pepperi-addons-ngx-lib-signature.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-skeleton-loader.mjs +3 -3
- package/fesm2020/pepperi-addons-ngx-lib-skeleton-loader.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-smart-filters.mjs +14 -7
- package/fesm2020/pepperi-addons-ngx-lib-smart-filters.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib-textbox.mjs +25 -5
- package/fesm2020/pepperi-addons-ngx-lib-textbox.mjs.map +1 -1
- package/fesm2020/pepperi-addons-ngx-lib.mjs +544 -529
- package/fesm2020/pepperi-addons-ngx-lib.mjs.map +1 -1
- package/form/internal-carusel.component.d.ts +1 -0
- package/form/internal-menu.component.d.ts +1 -2
- package/link/link.component.d.ts +3 -1
- package/list/list.component.d.ts +1 -1
- package/list/list.model.d.ts +1 -2
- package/menu/menu.component.d.ts +2 -1
- package/menu/menu.model.d.ts +1 -0
- package/package.json +1 -1
- package/profile-data-views-list/profile-data-view/profile-data-view.component.d.ts +3 -3
- package/profile-data-views-list/profile-data-views-card/profile-data-views-card.component.d.ts +5 -4
- package/profile-data-views-list/profile-data-views-list.component.d.ts +13 -10
- package/profile-data-views-list/profile-data-views-list.model.d.ts +8 -0
- package/query-builder/common/model/legacy.d.ts +2 -0
- package/query-builder/common/model/operator.d.ts +11 -1
- package/query-builder/common/services/query-structure.service.d.ts +1 -0
- package/query-builder/query-builder.module.d.ts +7 -3
- package/remote-loader/remote-loader.service.d.ts +1 -1
- package/rich-html-textarea/rich-html-textarea.component.d.ts +3 -1
- package/rich-html-textarea/rich-html-textarea.component.theme.scss +4 -2
- package/select-panel/select-panel.component.d.ts +1 -2
- package/signature/signature-dialog.component.d.ts +1 -1
- package/skeleton-loader/skeleton-loader.component.d.ts +3 -3
- package/smart-filters/boolean-filter/boolean-filter.component.d.ts +1 -0
- package/smart-filters/common/model/operator.d.ts +1 -0
- package/smart-filters/common/model/type.d.ts +1 -1
- package/smart-filters/date-filter/date-filter.component.d.ts +1 -0
- package/smart-filters/multi-select-filter/multi-select-filter.component.d.ts +1 -0
- package/smart-filters/number-filter/number-filter.component.d.ts +1 -0
- package/smart-filters/text-filter/text-filter.component.d.ts +1 -0
- package/src/assets/i18n/de.ngx-lib.json +4 -1
- package/src/assets/i18n/en.ngx-lib.json +7 -1
- package/src/core/style/abstracts/mixins.scss +73 -11
- package/src/core/style/abstracts/variables.scss +1 -1
- package/src/core/style/base/base.scss +5 -3
- package/src/core/style/base/typography.scss +2 -1
- package/src/core/style/components/button.scss +11 -0
- package/src/core/style/components/general.scss +2 -4
- package/textbox/textbox.component.d.ts +2 -0
- package/theming.scss +5 -1
- package/src/assets/images/sail-away.jpg +0 -0
- package/src/core/style/abstracts/AbstractsIntro.stories.mdx +0 -7
|
@@ -15,6 +15,8 @@ import * as i5 from '@pepperi-addons/ngx-lib/group-buttons';
|
|
|
15
15
|
import { PepGroupButtonsModule } from '@pepperi-addons/ngx-lib/group-buttons';
|
|
16
16
|
import { BehaviorSubject } from 'rxjs';
|
|
17
17
|
import * as i3$1 from '@angular/flex-layout/flex';
|
|
18
|
+
import * as i1$1 from '@pepperi-addons/ngx-lib/icon';
|
|
19
|
+
import { pepIconSystemBin, PepIconModule } from '@pepperi-addons/ngx-lib/icon';
|
|
18
20
|
|
|
19
21
|
class PepTypeConvertorService {
|
|
20
22
|
constructor() {
|
|
@@ -98,10 +100,10 @@ class PepQueryBuilderSectionComponent {
|
|
|
98
100
|
}
|
|
99
101
|
}
|
|
100
102
|
PepQueryBuilderSectionComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: PepQueryBuilderSectionComponent, deps: [{ token: PepTypeConvertorService }], target: i0.ɵɵFactoryTarget.Component });
|
|
101
|
-
PepQueryBuilderSectionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.0.2", type: PepQueryBuilderSectionComponent, selector: "pep-query-builder-section", inputs: { form: "form", depth: "depth", hasFields: "hasFields" }, outputs: { createSection: "createSection", createItem: "createItem", remove: "remove", operatorChange: "operatorChange" }, viewQueries: [{ propertyName: "sectionContainer", first: true, predicate: ["sectionContainer"], descendants: true, read: ViewContainerRef, static: true }], ngImport: i0, template: "<div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <div class=\"query-section-container\" fxLayout=\"column\" fxLayoutGap=\".5rem\">\n <div fxLayout=\"row\" fxLayoutAlign=\"space-between\">\n <pep-group-buttons [buttons]=\"toggleButtons\" [selectedButtonKey]=\"f.operator?.value || ''\" styleType=\"weak\"\n sizeType=\"sm\" [viewType]=\"'toggle'\" [buttonsDisabled]=\"!hasFields\">\n </pep-group-buttons>\n <div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <pep-button value=\"Add Filter\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"sm\" classNames=\"\"\n [disabled]=\"!hasFields\" iconName=\"number_plus\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onAddRuleClicked()\"></pep-button>\n <ng-container *ngIf=\"depth.current < depth.max-1\">\n <pep-button value=\"Add Filter Group\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"sm\"\n classNames=\"\" [disabled]=\"!hasFields\" iconName=\"number_plus\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onAddRuleSetClicked()\"></pep-button>\n </ng-container>\n </div>\n </div>\n <ng-container #sectionContainer></ng-container>\n </div>\n <pep-button *ngIf=\"depth.current > 0\" styleType=\"weak\" styleStateType=\"
|
|
103
|
+
PepQueryBuilderSectionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.0.2", type: PepQueryBuilderSectionComponent, selector: "pep-query-builder-section", inputs: { form: "form", depth: "depth", hasFields: "hasFields" }, outputs: { createSection: "createSection", createItem: "createItem", remove: "remove", operatorChange: "operatorChange" }, viewQueries: [{ propertyName: "sectionContainer", first: true, predicate: ["sectionContainer"], descendants: true, read: ViewContainerRef, static: true }], ngImport: i0, template: "<div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <div class=\"query-section-container\" fxLayout=\"column\" fxLayoutGap=\".5rem\">\n <div fxLayout=\"row\" fxLayoutAlign=\"space-between\">\n <pep-group-buttons [buttons]=\"toggleButtons\" [selectedButtonKey]=\"f.operator?.value || ''\" styleType=\"weak\"\n sizeType=\"sm\" [viewType]=\"'toggle'\" [buttonsDisabled]=\"!hasFields\">\n </pep-group-buttons>\n <div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <pep-button value=\"Add Filter\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"sm\" classNames=\"\"\n [disabled]=\"!hasFields\" iconName=\"number_plus\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onAddRuleClicked()\"></pep-button>\n <ng-container *ngIf=\"depth.current < depth.max-1\">\n <pep-button value=\"Add Filter Group\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"sm\"\n classNames=\"\" [disabled]=\"!hasFields\" iconName=\"number_plus\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onAddRuleSetClicked()\"></pep-button>\n </ng-container>\n </div>\n </div>\n <ng-container #sectionContainer></ng-container>\n </div>\n <pep-button *ngIf=\"depth.current > 0\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"md\" classNames=\"\"\n [disabled]=\"false\" iconName=\"system_bin\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onDeleteSectionClicked()\">\n </pep-button>\n</div>", styles: [".query-section-container{border-radius:var(--pep-border-radius-md, .25rem);padding:.5rem;width:100%}\n", ".query-section-container{box-shadow:var(--pep-shadow-sm-offset, 0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h, 0),var(--pep-color-system-primary-s, 0%),var(--pep-color-system-primary-l, 10%),.08);border:1px solid hsla(var(--pep-color-system-primary-h, 0),var(--pep-color-system-primary-s, 0%),var(--pep-color-system-primary-l, 10%),.24)}\n"], dependencies: [{ kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3$1.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { kind: "directive", type: i3$1.DefaultLayoutGapDirective, selector: " [fxLayoutGap], [fxLayoutGap.xs], [fxLayoutGap.sm], [fxLayoutGap.md], [fxLayoutGap.lg], [fxLayoutGap.xl], [fxLayoutGap.lt-sm], [fxLayoutGap.lt-md], [fxLayoutGap.lt-lg], [fxLayoutGap.lt-xl], [fxLayoutGap.gt-xs], [fxLayoutGap.gt-sm], [fxLayoutGap.gt-md], [fxLayoutGap.gt-lg]", inputs: ["fxLayoutGap", "fxLayoutGap.xs", "fxLayoutGap.sm", "fxLayoutGap.md", "fxLayoutGap.lg", "fxLayoutGap.xl", "fxLayoutGap.lt-sm", "fxLayoutGap.lt-md", "fxLayoutGap.lt-lg", "fxLayoutGap.lt-xl", "fxLayoutGap.gt-xs", "fxLayoutGap.gt-sm", "fxLayoutGap.gt-md", "fxLayoutGap.gt-lg"] }, { kind: "directive", type: i3$1.DefaultLayoutAlignDirective, selector: " [fxLayoutAlign], [fxLayoutAlign.xs], [fxLayoutAlign.sm], [fxLayoutAlign.md], [fxLayoutAlign.lg], [fxLayoutAlign.xl], [fxLayoutAlign.lt-sm], [fxLayoutAlign.lt-md], [fxLayoutAlign.lt-lg], [fxLayoutAlign.lt-xl], [fxLayoutAlign.gt-xs], [fxLayoutAlign.gt-sm], [fxLayoutAlign.gt-md], [fxLayoutAlign.gt-lg]", inputs: ["fxLayoutAlign", "fxLayoutAlign.xs", "fxLayoutAlign.sm", "fxLayoutAlign.md", "fxLayoutAlign.lg", "fxLayoutAlign.xl", "fxLayoutAlign.lt-sm", "fxLayoutAlign.lt-md", "fxLayoutAlign.lt-lg", "fxLayoutAlign.lt-xl", "fxLayoutAlign.gt-xs", "fxLayoutAlign.gt-sm", "fxLayoutAlign.gt-md", "fxLayoutAlign.gt-lg"] }, { kind: "component", type: i4.PepButtonComponent, selector: "pep-button", inputs: ["key", "value", "styleType", "styleStateType", "sizeType", "classNames", "disabled", "iconName", "iconPosition", "visible"], outputs: ["buttonClick"] }, { kind: "component", type: i5.PepGroupButtonsComponent, selector: "pep-group-buttons", inputs: ["viewType", "styleType", "sizeType", "buttons", "buttonsDisabled", "supportUnselect", "selectedButtonKey", "stretch"], outputs: ["buttonClick"] }] });
|
|
102
104
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: PepQueryBuilderSectionComponent, decorators: [{
|
|
103
105
|
type: Component,
|
|
104
|
-
args: [{ selector: 'pep-query-builder-section', template: "<div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <div class=\"query-section-container\" fxLayout=\"column\" fxLayoutGap=\".5rem\">\n <div fxLayout=\"row\" fxLayoutAlign=\"space-between\">\n <pep-group-buttons [buttons]=\"toggleButtons\" [selectedButtonKey]=\"f.operator?.value || ''\" styleType=\"weak\"\n sizeType=\"sm\" [viewType]=\"'toggle'\" [buttonsDisabled]=\"!hasFields\">\n </pep-group-buttons>\n <div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <pep-button value=\"Add Filter\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"sm\" classNames=\"\"\n [disabled]=\"!hasFields\" iconName=\"number_plus\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onAddRuleClicked()\"></pep-button>\n <ng-container *ngIf=\"depth.current < depth.max-1\">\n <pep-button value=\"Add Filter Group\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"sm\"\n classNames=\"\" [disabled]=\"!hasFields\" iconName=\"number_plus\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onAddRuleSetClicked()\"></pep-button>\n </ng-container>\n </div>\n </div>\n <ng-container #sectionContainer></ng-container>\n </div>\n <pep-button *ngIf=\"depth.current > 0\" styleType=\"weak\" styleStateType=\"
|
|
106
|
+
args: [{ selector: 'pep-query-builder-section', template: "<div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <div class=\"query-section-container\" fxLayout=\"column\" fxLayoutGap=\".5rem\">\n <div fxLayout=\"row\" fxLayoutAlign=\"space-between\">\n <pep-group-buttons [buttons]=\"toggleButtons\" [selectedButtonKey]=\"f.operator?.value || ''\" styleType=\"weak\"\n sizeType=\"sm\" [viewType]=\"'toggle'\" [buttonsDisabled]=\"!hasFields\">\n </pep-group-buttons>\n <div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <pep-button value=\"Add Filter\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"sm\" classNames=\"\"\n [disabled]=\"!hasFields\" iconName=\"number_plus\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onAddRuleClicked()\"></pep-button>\n <ng-container *ngIf=\"depth.current < depth.max-1\">\n <pep-button value=\"Add Filter Group\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"sm\"\n classNames=\"\" [disabled]=\"!hasFields\" iconName=\"number_plus\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onAddRuleSetClicked()\"></pep-button>\n </ng-container>\n </div>\n </div>\n <ng-container #sectionContainer></ng-container>\n </div>\n <pep-button *ngIf=\"depth.current > 0\" styleType=\"weak\" styleStateType=\"system\" sizeType=\"md\" classNames=\"\"\n [disabled]=\"false\" iconName=\"system_bin\" iconPosition=\"end\" [visible]=\"true\"\n (buttonClick)=\"onDeleteSectionClicked()\">\n </pep-button>\n</div>", styles: [".query-section-container{border-radius:var(--pep-border-radius-md, .25rem);padding:.5rem;width:100%}\n", ".query-section-container{box-shadow:var(--pep-shadow-sm-offset, 0 .25rem .5rem 0) hsla(var(--pep-color-system-primary-h, 0),var(--pep-color-system-primary-s, 0%),var(--pep-color-system-primary-l, 10%),.08);border:1px solid hsla(var(--pep-color-system-primary-h, 0),var(--pep-color-system-primary-s, 0%),var(--pep-color-system-primary-l, 10%),.24)}\n"] }]
|
|
105
107
|
}], ctorParameters: function () { return [{ type: PepTypeConvertorService }]; }, propDecorators: { form: [{
|
|
106
108
|
type: Input
|
|
107
109
|
}], depth: [{
|
|
@@ -215,10 +217,10 @@ class PepQueryBuilderItemComponent {
|
|
|
215
217
|
}
|
|
216
218
|
}
|
|
217
219
|
PepQueryBuilderItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: PepQueryBuilderItemComponent, deps: [{ token: i1.FormBuilder }, { token: PepTypeConvertorService }], target: i0.ɵɵFactoryTarget.Component });
|
|
218
|
-
PepQueryBuilderItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.0.2", type: PepQueryBuilderItemComponent, selector: "pep-query-builder-item", inputs: { formKey: "formKey", fields: "fields", selected: "selected", filter: "filter", parentForm: "parentForm", variableFields: "variableFields" }, outputs: { filterChange: "filterChange", remove: "remove" }, ngImport: i0, template: "<div fxLayout=\"column\" fxLayoutGap=\".5rem\">\n <div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <pep-select fxFlex=\"25%\" [value]=\"_selectedField?.id\" xAlignment=\"left\" [options]=\"_options\"\n [renderTitle]=\"false\" (valueChange)=\"onFieldChanged($event)\"></pep-select>\n <ng-container *ngIf=\"_selectedField?.componentType\">\n <ng-container [ngSwitch]=\"_selectedField.componentType\">\n <ng-container *ngSwitchCase=\"'text'\">\n <pep-text-filter fxFlex=\"auto\" [showActionButtons]=\"false\" [variableField]=\"variableFields?.text\"\n [field]=\"_selectedField\" [filter]=\"_filter\" [parentForm]=\"f.smart\" [emitOnChange]=\"true\"\n [inline]=\"true\" [renderTitle]=\"false\" (filterChange)=\"onFilterChanged()\">\n </pep-text-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'boolean'\">\n <pep-boolean-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.boolean\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\"\n [options]=\"typeConvertorService.booleans\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-boolean-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'date'\">\n <pep-date-filter fxFlex=\"auto\" [showActionButtons]=\"false\" [showAdditionalOperators]=\"true\"\n [variableField]=\"variableFields?.date\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-date-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'
|
|
220
|
+
PepQueryBuilderItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.0.2", type: PepQueryBuilderItemComponent, selector: "pep-query-builder-item", inputs: { formKey: "formKey", fields: "fields", selected: "selected", filter: "filter", parentForm: "parentForm", variableFields: "variableFields" }, outputs: { filterChange: "filterChange", remove: "remove" }, ngImport: i0, template: "<div fxLayout=\"column\" fxLayoutGap=\".5rem\">\n <div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <pep-select fxFlex=\"25%\" [value]=\"_selectedField?.id\" xAlignment=\"left\" [options]=\"_options\"\n [renderTitle]=\"false\" (valueChange)=\"onFieldChanged($event)\"></pep-select>\n <ng-container *ngIf=\"_selectedField?.componentType\">\n <ng-container [ngSwitch]=\"_selectedField.componentType\">\n <ng-container *ngSwitchCase=\"'text'\">\n <pep-text-filter fxFlex=\"auto\" [showActionButtons]=\"false\" [variableField]=\"variableFields?.text\"\n [field]=\"_selectedField\" [filter]=\"_filter\" [parentForm]=\"f.smart\" [emitOnChange]=\"true\"\n [inline]=\"true\" [renderTitle]=\"false\" (filterChange)=\"onFilterChanged()\">\n </pep-text-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'boolean'\">\n <pep-boolean-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.boolean\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\"\n [options]=\"typeConvertorService.booleans\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-boolean-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'date'\">\n <pep-date-filter fxFlex=\"auto\" [showActionButtons]=\"false\" [showAdditionalOperators]=\"true\"\n [variableField]=\"variableFields?.date\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-date-filter>\n </ng-container>\n <!-- <ng-container *ngSwitchCase=\"'text'\">\n <pep-multi-select-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.text\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-multi-select-filter>\n </ng-container> -->\n <ng-container *ngSwitchCase=\"'multi-select'\">\n <pep-multi-select-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.text\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-multi-select-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'number'\">\n <pep-number-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.number\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-number-filter>\n </ng-container>\n </ng-container>\n </ng-container>\n <pep-button styleType=\"weak\" styleStateType=\"system\" sizeType=\"md\" classNames=\"\" [disabled]=\"false\"\n iconName=\"system_bin\" iconPosition=\"end\" [visible]=\"true\" (buttonClick)=\"onDeleteItemClicked()\">\n </pep-button>\n </div>\n</div>", styles: ["::ng-deep .pep-field-no-spacing{min-height:0!important;margin-bottom:0!important}\n"], dependencies: [{ kind: "directive", type: i3.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i3.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i3.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i3$1.DefaultLayoutDirective, selector: " [fxLayout], [fxLayout.xs], [fxLayout.sm], [fxLayout.md], [fxLayout.lg], [fxLayout.xl], [fxLayout.lt-sm], [fxLayout.lt-md], [fxLayout.lt-lg], [fxLayout.lt-xl], [fxLayout.gt-xs], [fxLayout.gt-sm], [fxLayout.gt-md], [fxLayout.gt-lg]", inputs: ["fxLayout", "fxLayout.xs", "fxLayout.sm", "fxLayout.md", "fxLayout.lg", "fxLayout.xl", "fxLayout.lt-sm", "fxLayout.lt-md", "fxLayout.lt-lg", "fxLayout.lt-xl", "fxLayout.gt-xs", "fxLayout.gt-sm", "fxLayout.gt-md", "fxLayout.gt-lg"] }, { kind: "directive", type: i3$1.DefaultLayoutGapDirective, selector: " [fxLayoutGap], [fxLayoutGap.xs], [fxLayoutGap.sm], [fxLayoutGap.md], [fxLayoutGap.lg], [fxLayoutGap.xl], [fxLayoutGap.lt-sm], [fxLayoutGap.lt-md], [fxLayoutGap.lt-lg], [fxLayoutGap.lt-xl], [fxLayoutGap.gt-xs], [fxLayoutGap.gt-sm], [fxLayoutGap.gt-md], [fxLayoutGap.gt-lg]", inputs: ["fxLayoutGap", "fxLayoutGap.xs", "fxLayoutGap.sm", "fxLayoutGap.md", "fxLayoutGap.lg", "fxLayoutGap.xl", "fxLayoutGap.lt-sm", "fxLayoutGap.lt-md", "fxLayoutGap.lt-lg", "fxLayoutGap.lt-xl", "fxLayoutGap.gt-xs", "fxLayoutGap.gt-sm", "fxLayoutGap.gt-md", "fxLayoutGap.gt-lg"] }, { kind: "directive", type: i3$1.DefaultFlexDirective, selector: " [fxFlex], [fxFlex.xs], [fxFlex.sm], [fxFlex.md], [fxFlex.lg], [fxFlex.xl], [fxFlex.lt-sm], [fxFlex.lt-md], [fxFlex.lt-lg], [fxFlex.lt-xl], [fxFlex.gt-xs], [fxFlex.gt-sm], [fxFlex.gt-md], [fxFlex.gt-lg]", inputs: ["fxFlex", "fxFlex.xs", "fxFlex.sm", "fxFlex.md", "fxFlex.lg", "fxFlex.xl", "fxFlex.lt-sm", "fxFlex.lt-md", "fxFlex.lt-lg", "fxFlex.lt-xl", "fxFlex.gt-xs", "fxFlex.gt-sm", "fxFlex.gt-md", "fxFlex.gt-lg"] }, { kind: "component", type: i5$1.PepSelectComponent, selector: "pep-select", inputs: ["key", "value", "label", "type", "mandatory", "disabled", "readonly", "xAlignment", "rowSpan", "placeholder", "placeholderWhenDisabled", "options", "visible", "emptyOption", "form", "layoutType", "parentFieldKey", "isActive", "showTitle", "renderTitle", "typeaheadDebounceInterval", "addValueToOptionsIfNotExist"], outputs: ["valueChange"] }, { kind: "component", type: i4.PepButtonComponent, selector: "pep-button", inputs: ["key", "value", "styleType", "styleStateType", "sizeType", "classNames", "disabled", "iconName", "iconPosition", "visible"], outputs: ["buttonClick"] }, { kind: "component", type: i7.PepTextFilterComponent, selector: "pep-text-filter" }, { kind: "component", type: i7.PepBooleanFilterComponent, selector: "pep-boolean-filter", inputs: ["options"] }, { kind: "component", type: i7.PepDateFilterComponent, selector: "pep-date-filter" }, { kind: "component", type: i7.PepMultiSelectFilterComponent, selector: "pep-multi-select-filter" }, { kind: "component", type: i7.PepNumberFilterComponent, selector: "pep-number-filter" }] });
|
|
219
221
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: PepQueryBuilderItemComponent, decorators: [{
|
|
220
222
|
type: Component,
|
|
221
|
-
args: [{ selector: 'pep-query-builder-item', template: "<div fxLayout=\"column\" fxLayoutGap=\".5rem\">\n <div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <pep-select fxFlex=\"25%\" [value]=\"_selectedField?.id\" xAlignment=\"left\" [options]=\"_options\"\n [renderTitle]=\"false\" (valueChange)=\"onFieldChanged($event)\"></pep-select>\n <ng-container *ngIf=\"_selectedField?.componentType\">\n <ng-container [ngSwitch]=\"_selectedField.componentType\">\n <ng-container *ngSwitchCase=\"'text'\">\n <pep-text-filter fxFlex=\"auto\" [showActionButtons]=\"false\" [variableField]=\"variableFields?.text\"\n [field]=\"_selectedField\" [filter]=\"_filter\" [parentForm]=\"f.smart\" [emitOnChange]=\"true\"\n [inline]=\"true\" [renderTitle]=\"false\" (filterChange)=\"onFilterChanged()\">\n </pep-text-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'boolean'\">\n <pep-boolean-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.boolean\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\"\n [options]=\"typeConvertorService.booleans\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-boolean-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'date'\">\n <pep-date-filter fxFlex=\"auto\" [showActionButtons]=\"false\" [showAdditionalOperators]=\"true\"\n [variableField]=\"variableFields?.date\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-date-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'
|
|
223
|
+
args: [{ selector: 'pep-query-builder-item', template: "<div fxLayout=\"column\" fxLayoutGap=\".5rem\">\n <div fxLayout=\"row\" fxLayoutGap=\".5rem\">\n <pep-select fxFlex=\"25%\" [value]=\"_selectedField?.id\" xAlignment=\"left\" [options]=\"_options\"\n [renderTitle]=\"false\" (valueChange)=\"onFieldChanged($event)\"></pep-select>\n <ng-container *ngIf=\"_selectedField?.componentType\">\n <ng-container [ngSwitch]=\"_selectedField.componentType\">\n <ng-container *ngSwitchCase=\"'text'\">\n <pep-text-filter fxFlex=\"auto\" [showActionButtons]=\"false\" [variableField]=\"variableFields?.text\"\n [field]=\"_selectedField\" [filter]=\"_filter\" [parentForm]=\"f.smart\" [emitOnChange]=\"true\"\n [inline]=\"true\" [renderTitle]=\"false\" (filterChange)=\"onFilterChanged()\">\n </pep-text-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'boolean'\">\n <pep-boolean-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.boolean\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\"\n [options]=\"typeConvertorService.booleans\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-boolean-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'date'\">\n <pep-date-filter fxFlex=\"auto\" [showActionButtons]=\"false\" [showAdditionalOperators]=\"true\"\n [variableField]=\"variableFields?.date\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-date-filter>\n </ng-container>\n <!-- <ng-container *ngSwitchCase=\"'text'\">\n <pep-multi-select-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.text\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-multi-select-filter>\n </ng-container> -->\n <ng-container *ngSwitchCase=\"'multi-select'\">\n <pep-multi-select-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.text\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-multi-select-filter>\n </ng-container>\n <ng-container *ngSwitchCase=\"'number'\">\n <pep-number-filter fxFlex=\"auto\" [showActionButtons]=\"false\"\n [variableField]=\"variableFields?.number\" [field]=\"_selectedField\" [filter]=\"_filter\"\n [parentForm]=\"f.smart\" [emitOnChange]=\"true\" [inline]=\"true\" [renderTitle]=\"false\"\n (filterChange)=\"onFilterChanged()\">\n </pep-number-filter>\n </ng-container>\n </ng-container>\n </ng-container>\n <pep-button styleType=\"weak\" styleStateType=\"system\" sizeType=\"md\" classNames=\"\" [disabled]=\"false\"\n iconName=\"system_bin\" iconPosition=\"end\" [visible]=\"true\" (buttonClick)=\"onDeleteItemClicked()\">\n </pep-button>\n </div>\n</div>", styles: ["::ng-deep .pep-field-no-spacing{min-height:0!important;margin-bottom:0!important}\n"] }]
|
|
222
224
|
}], ctorParameters: function () { return [{ type: i1.FormBuilder }, { type: PepTypeConvertorService }]; }, propDecorators: { formKey: [{
|
|
223
225
|
type: Input
|
|
224
226
|
}], fields: [{
|
|
@@ -272,41 +274,50 @@ var PepOperatorTypes;
|
|
|
272
274
|
|
|
273
275
|
const Equals = {
|
|
274
276
|
legacy: 'IsEqual',
|
|
277
|
+
valueType: 'Static',
|
|
275
278
|
smartFilter: PepSmartFilterOperators.Equals,
|
|
276
279
|
type: ['boolean', 'int', 'text', 'real']
|
|
277
280
|
};
|
|
278
281
|
const EqualsVariable = {
|
|
279
|
-
legacy: '
|
|
282
|
+
legacy: 'IsEqual',
|
|
283
|
+
valueType: 'Dynamic',
|
|
280
284
|
smartFilter: PepSmartFilterVariableOperators.EqualsToVariable,
|
|
281
|
-
type: ['boolean', 'int', 'text',
|
|
285
|
+
type: ['boolean', 'int', 'text'],
|
|
286
|
+
fieldType: ['String', 'Bool', 'Integer']
|
|
282
287
|
};
|
|
283
288
|
const NotEqual = {
|
|
284
289
|
legacy: 'IsNotEqual',
|
|
290
|
+
valueType: 'Static',
|
|
285
291
|
smartFilter: PepSmartFilterOperators.NotEqual,
|
|
286
292
|
type: null
|
|
287
293
|
};
|
|
288
294
|
const NotEqualsVariable = {
|
|
289
|
-
legacy: '
|
|
295
|
+
legacy: 'IsNotEqual',
|
|
296
|
+
valueType: 'Dynamic',
|
|
290
297
|
smartFilter: PepSmartFilterVariableOperators.NotEqualsToVariable,
|
|
291
|
-
type: ['boolean'
|
|
298
|
+
type: ['boolean']
|
|
292
299
|
};
|
|
293
300
|
const LessThan = {
|
|
294
301
|
legacy: '<',
|
|
302
|
+
valueType: 'Static',
|
|
295
303
|
smartFilter: PepSmartFilterOperators.LessThan,
|
|
296
304
|
type: null
|
|
297
305
|
};
|
|
298
|
-
const
|
|
299
|
-
legacy: '
|
|
306
|
+
const LessThanVariable = {
|
|
307
|
+
legacy: '<',
|
|
308
|
+
valueType: 'Dynamic',
|
|
300
309
|
smartFilter: PepSmartFilterVariableOperators.LessThanVariable,
|
|
301
310
|
type: null
|
|
302
311
|
};
|
|
303
312
|
const GreaterThan = {
|
|
304
313
|
legacy: '>',
|
|
314
|
+
valueType: 'Static',
|
|
305
315
|
smartFilter: PepSmartFilterOperators.GreaterThan,
|
|
306
316
|
type: null
|
|
307
317
|
};
|
|
308
|
-
const
|
|
309
|
-
legacy: '
|
|
318
|
+
const GreaterThanVariable = {
|
|
319
|
+
legacy: '>',
|
|
320
|
+
valueType: 'Dynamic',
|
|
310
321
|
smartFilter: PepSmartFilterVariableOperators.GreaterThanVariable,
|
|
311
322
|
type: null
|
|
312
323
|
};
|
|
@@ -335,159 +346,142 @@ const LessThanOrEquals: IPepQueryBuilderOperator = {
|
|
|
335
346
|
}; */
|
|
336
347
|
const NumberRange = {
|
|
337
348
|
legacy: 'Between',
|
|
349
|
+
valueType: 'Static',
|
|
338
350
|
smartFilter: PepSmartFilterOperators.NumberRange,
|
|
339
351
|
type: ['int']
|
|
340
352
|
};
|
|
341
353
|
const Contains = {
|
|
342
354
|
legacy: 'Contains',
|
|
355
|
+
valueType: 'Static',
|
|
343
356
|
smartFilter: PepSmartFilterOperators.Contains,
|
|
344
357
|
type: null
|
|
345
358
|
};
|
|
346
359
|
const BeginsWith = {
|
|
347
|
-
legacy: '
|
|
360
|
+
legacy: 'StartWith',
|
|
361
|
+
valueType: 'Static',
|
|
348
362
|
smartFilter: PepSmartFilterOperators.BeginsWith,
|
|
349
363
|
type: null
|
|
350
364
|
};
|
|
351
365
|
const EndsWith = {
|
|
352
|
-
legacy: '
|
|
366
|
+
legacy: 'EndWith',
|
|
367
|
+
valueType: 'Static',
|
|
353
368
|
smartFilter: PepSmartFilterOperators.EndsWith,
|
|
354
369
|
type: null
|
|
355
370
|
};
|
|
356
|
-
/*
|
|
357
|
-
const BeginsWith: IPepQueryBuilderOperator = {
|
|
358
|
-
legacy: {
|
|
359
|
-
operator: 'BeginsWith',
|
|
360
|
-
type: 'String'
|
|
361
|
-
},
|
|
362
|
-
smartFilter: {
|
|
363
|
-
item: PepSmartFilterOperators.BeginsWith,
|
|
364
|
-
type: 'text'
|
|
365
|
-
}
|
|
366
|
-
};
|
|
367
|
-
|
|
368
|
-
const EndsWith: IPepQueryBuilderOperator = {
|
|
369
|
-
legacy: {
|
|
370
|
-
operator: 'EndsWith',
|
|
371
|
-
type: 'String'
|
|
372
|
-
},
|
|
373
|
-
smartFilter: {
|
|
374
|
-
item: PepSmartFilterOperators.EndsWith,
|
|
375
|
-
type: 'text'
|
|
376
|
-
}
|
|
377
|
-
};
|
|
378
|
-
|
|
379
|
-
const Before: IPepQueryBuilderOperator = {
|
|
380
|
-
legacy: {
|
|
381
|
-
operator: 'Before',
|
|
382
|
-
type: 'Date'
|
|
383
|
-
},
|
|
384
|
-
smartFilter: {
|
|
385
|
-
item: PepSmartFilterOperators.Before,
|
|
386
|
-
type: 'date'
|
|
387
|
-
}
|
|
388
|
-
};
|
|
389
|
-
|
|
390
|
-
const After: IPepQueryBuilderOperator = {
|
|
391
|
-
legacy: {
|
|
392
|
-
operator: 'After',
|
|
393
|
-
type: 'Date'
|
|
394
|
-
},
|
|
395
|
-
smartFilter: {
|
|
396
|
-
item: PepSmartFilterOperators.After,
|
|
397
|
-
type: 'date'
|
|
398
|
-
}
|
|
399
|
-
}; */
|
|
400
371
|
const InTheLast = {
|
|
401
372
|
legacy: 'InTheLast',
|
|
373
|
+
valueType: 'Static',
|
|
402
374
|
smartFilter: PepSmartFilterOperators.InTheLast,
|
|
403
375
|
type: null
|
|
404
376
|
};
|
|
405
377
|
const InTheLastCalendar = {
|
|
406
378
|
legacy: 'InTheLastCalendar',
|
|
379
|
+
valueType: 'Static',
|
|
407
380
|
smartFilter: PepSmartFilterAdditionalOperators.InTheLastCalendar,
|
|
408
381
|
type: null
|
|
409
382
|
};
|
|
410
383
|
/*
|
|
411
384
|
const InTheLastVariable: IPepQueryBuilderOperator = {
|
|
412
|
-
legacy: '
|
|
385
|
+
legacy: 'InTheLast',
|
|
386
|
+
valueType: 'Dynamic',
|
|
413
387
|
smartFilter: PepSmartFilterVariableOperators.InTheLastVariable,
|
|
414
388
|
type: null
|
|
415
389
|
} */
|
|
416
390
|
const NotInTheLast = {
|
|
417
391
|
legacy: 'NotInTheLast',
|
|
392
|
+
valueType: 'Static',
|
|
418
393
|
smartFilter: PepSmartFilterOperators.NotInTheLast,
|
|
419
394
|
type: null
|
|
420
395
|
};
|
|
421
396
|
const NotInTheLastCalendar = {
|
|
422
397
|
legacy: 'NotInTheLastCalendar',
|
|
398
|
+
valueType: 'Static',
|
|
423
399
|
smartFilter: PepSmartFilterAdditionalOperators.NotInTheLastCalendar,
|
|
424
400
|
type: null
|
|
425
401
|
};
|
|
426
402
|
const Today = {
|
|
427
403
|
legacy: 'Today',
|
|
404
|
+
valueType: 'Static',
|
|
428
405
|
smartFilter: PepSmartFilterOperators.Today,
|
|
429
406
|
type: null
|
|
430
407
|
};
|
|
431
408
|
const ThisWeek = {
|
|
432
409
|
legacy: 'ThisWeek',
|
|
410
|
+
valueType: 'Static',
|
|
433
411
|
smartFilter: PepSmartFilterOperators.ThisWeek,
|
|
434
412
|
type: null
|
|
435
413
|
};
|
|
436
414
|
const ThisMonth = {
|
|
437
415
|
legacy: 'ThisMonth',
|
|
416
|
+
valueType: 'Static',
|
|
438
417
|
smartFilter: PepSmartFilterOperators.ThisMonth,
|
|
439
418
|
type: null
|
|
440
419
|
};
|
|
441
420
|
const DateRange = {
|
|
442
421
|
legacy: 'Between',
|
|
422
|
+
valueType: 'Static',
|
|
443
423
|
smartFilter: PepSmartFilterOperators.DateRange,
|
|
444
424
|
type: ['date-time']
|
|
445
425
|
};
|
|
446
426
|
const dateRangeVariable = {
|
|
447
|
-
legacy: '
|
|
427
|
+
legacy: 'Between',
|
|
428
|
+
valueType: 'Dynamic',
|
|
448
429
|
smartFilter: PepSmartFilterVariableOperators.DateRangeVariable,
|
|
449
430
|
type: ['date-time']
|
|
450
431
|
};
|
|
451
432
|
const DueIn = {
|
|
452
433
|
legacy: 'DueIn',
|
|
434
|
+
valueType: 'Static',
|
|
453
435
|
smartFilter: PepSmartFilterOperators.DueIn,
|
|
454
436
|
type: null
|
|
455
437
|
};
|
|
456
438
|
const NotDueIn = {
|
|
457
439
|
legacy: 'NotDueIn',
|
|
440
|
+
valueType: 'Static',
|
|
458
441
|
smartFilter: PepSmartFilterOperators.NotDueIn,
|
|
459
442
|
type: null
|
|
460
443
|
};
|
|
461
444
|
const On = {
|
|
462
445
|
legacy: 'On',
|
|
446
|
+
valueType: 'Static',
|
|
463
447
|
smartFilter: PepSmartFilterOperators.On,
|
|
464
448
|
type: null
|
|
465
449
|
};
|
|
466
450
|
const IsEmpty = {
|
|
467
451
|
legacy: 'IsEmpty',
|
|
452
|
+
valueType: 'Static',
|
|
468
453
|
smartFilter: PepSmartFilterOperators.IsEmpty,
|
|
469
454
|
type: null
|
|
470
455
|
};
|
|
471
456
|
const IsNotEmpty = {
|
|
472
457
|
legacy: 'IsNotEmpty',
|
|
458
|
+
valueType: 'Static',
|
|
473
459
|
smartFilter: PepSmartFilterOperators.IsNotEmpty,
|
|
474
460
|
type: null
|
|
475
461
|
};
|
|
476
462
|
const In = {
|
|
477
463
|
legacy: 'IsEqual',
|
|
464
|
+
valueType: 'Static',
|
|
478
465
|
smartFilter: PepSmartFilterOperators.In,
|
|
479
466
|
type: ['multi-select']
|
|
480
467
|
};
|
|
468
|
+
const InVariable = {
|
|
469
|
+
legacy: 'IsEqual',
|
|
470
|
+
valueType: 'Dynamic',
|
|
471
|
+
smartFilter: PepSmartFilterVariableOperators.InVariable,
|
|
472
|
+
type: ['multi-select', 'text'],
|
|
473
|
+
fieldType: ['MultipleStringValues']
|
|
474
|
+
};
|
|
481
475
|
const PepQueryBuilderOperators = [
|
|
482
476
|
Equals,
|
|
483
477
|
EqualsVariable,
|
|
484
478
|
NotEqual,
|
|
485
479
|
NotEqualsVariable,
|
|
486
480
|
LessThan,
|
|
487
|
-
|
|
481
|
+
LessThanVariable,
|
|
488
482
|
// LessThanOrEquals,
|
|
489
483
|
GreaterThan,
|
|
490
|
-
|
|
484
|
+
GreaterThanVariable,
|
|
491
485
|
// GreaterThanOrEquals,
|
|
492
486
|
NumberRange,
|
|
493
487
|
Contains,
|
|
@@ -510,7 +504,8 @@ const PepQueryBuilderOperators = [
|
|
|
510
504
|
On,
|
|
511
505
|
IsEmpty,
|
|
512
506
|
IsNotEmpty,
|
|
513
|
-
In
|
|
507
|
+
In,
|
|
508
|
+
InVariable
|
|
514
509
|
];
|
|
515
510
|
/**
|
|
516
511
|
* gets a smart filter operator item
|
|
@@ -518,9 +513,18 @@ const PepQueryBuilderOperators = [
|
|
|
518
513
|
* @param type smart filter's type
|
|
519
514
|
* @returns smart filter operator item
|
|
520
515
|
*/
|
|
521
|
-
function getSmartFilterOperator(operator, type) {
|
|
522
|
-
const smartFilterOperator = PepQueryBuilderOperators.find(item =>
|
|
523
|
-
|
|
516
|
+
function getSmartFilterOperator(operator, type, valueType, fieldType = null) {
|
|
517
|
+
const smartFilterOperator = PepQueryBuilderOperators.find(item => {
|
|
518
|
+
var _a;
|
|
519
|
+
return item.legacy === operator &&
|
|
520
|
+
item.valueType === valueType &&
|
|
521
|
+
(item.type === null || item.type.includes(type)) &&
|
|
522
|
+
(fieldType == null || item.fieldType === undefined || ((_a = item.fieldType) === null || _a === void 0 ? void 0 : _a.includes(fieldType)));
|
|
523
|
+
});
|
|
524
|
+
/*
|
|
525
|
+
FieldType: (current[key].smart.operator.id === 'inv' &&
|
|
526
|
+
current[key].smart.fieldType === 'text') ? 'MultipleStringValues' : current[key].query.fieldType,
|
|
527
|
+
*/
|
|
524
528
|
return smartFilterOperator ? smartFilterOperator.smartFilter : null;
|
|
525
529
|
}
|
|
526
530
|
/**
|
|
@@ -534,6 +538,17 @@ function getLegacyOperator(operator, type) {
|
|
|
534
538
|
(item.type === null || item.type.includes(type)));
|
|
535
539
|
return legacyOperator ? legacyOperator.legacy : null;
|
|
536
540
|
}
|
|
541
|
+
/**
|
|
542
|
+
* gets a value type of the operator value
|
|
543
|
+
* @param operator smart filter operator item
|
|
544
|
+
* @param type smart filter's type
|
|
545
|
+
* @returns value type operator value
|
|
546
|
+
*/
|
|
547
|
+
function getValueTypeOperator(operator, type) {
|
|
548
|
+
const valueType = PepQueryBuilderOperators.find(item => item.smartFilter === operator &&
|
|
549
|
+
(item.type === null || item.type.includes(type)));
|
|
550
|
+
return valueType ? valueType.valueType : 'Static';
|
|
551
|
+
}
|
|
537
552
|
|
|
538
553
|
const Days = {
|
|
539
554
|
legacy: 'Days',
|
|
@@ -608,8 +623,10 @@ class PepOutputQueryService {
|
|
|
608
623
|
section = this.addToSection(section, {
|
|
609
624
|
ExpressionId: (this._expressionIdCounter++).toString(),
|
|
610
625
|
ApiName: current[key].smart.fieldId,
|
|
611
|
-
FieldType: current[key].
|
|
626
|
+
FieldType: (current[key].smart.operator.id === 'inv' &&
|
|
627
|
+
current[key].smart.fieldType === 'text') ? 'MultipleStringValues' : current[key].query.fieldType,
|
|
612
628
|
Operation: getLegacyOperator(current[key].smart.operator, current[key].smart.fieldType),
|
|
629
|
+
ValueType: getValueTypeOperator(current[key].smart.operator, current[key].smart.fieldType),
|
|
613
630
|
Values: this.getItemValues(current[key].smart)
|
|
614
631
|
}, current.operator);
|
|
615
632
|
}
|
|
@@ -697,7 +714,7 @@ class PepQueryBuilderService {
|
|
|
697
714
|
* @returns smart filter object
|
|
698
715
|
*/
|
|
699
716
|
getFilter(current, field) {
|
|
700
|
-
const operator = getSmartFilterOperator(current.Operation, field.type);
|
|
717
|
+
const operator = getSmartFilterOperator(current.Operation, field.type, current.ValueType || 'Static', current.FieldType || null);
|
|
701
718
|
if (operator) {
|
|
702
719
|
const filterValues = this.getFilterValues(current, operator, field);
|
|
703
720
|
return createSmartFilter(current.ApiName, operator, filterValues.first, filterValues.second, filterValues.operationUnit);
|
|
@@ -793,6 +810,7 @@ class PepQueryStructureService {
|
|
|
793
810
|
this._outputQuery$ = new BehaviorSubject(null);
|
|
794
811
|
this._variableFields = {};
|
|
795
812
|
this._maxStructureDepth = MAX_STRUCTURE_DEPTH;
|
|
813
|
+
this._cmpRefMap = new Map();
|
|
796
814
|
this.outputQuery$ = this._outputQuery$.asObservable();
|
|
797
815
|
}
|
|
798
816
|
set maxDepth(value) {
|
|
@@ -835,6 +853,18 @@ class PepQueryStructureService {
|
|
|
835
853
|
* @param containerRef reference to root element
|
|
836
854
|
*/
|
|
837
855
|
buildQueryStructure(query, containerRef) {
|
|
856
|
+
// Remove all the components from the query builder.
|
|
857
|
+
this._cmpRefMap.forEach((value, key) => {
|
|
858
|
+
// console.log(key, value);
|
|
859
|
+
// value.instance.remove();
|
|
860
|
+
if (value.instance.parentForm) {
|
|
861
|
+
value.instance.parentForm.removeControl(key);
|
|
862
|
+
}
|
|
863
|
+
value.destroy();
|
|
864
|
+
this._cmpRefMap.delete(key);
|
|
865
|
+
});
|
|
866
|
+
// Clear containerRef
|
|
867
|
+
containerRef.clear();
|
|
838
868
|
//update root operator
|
|
839
869
|
if (this.hasProperty(query, 'ComplexId') &&
|
|
840
870
|
(query === null || query === void 0 ? void 0 : query.Operation) &&
|
|
@@ -917,10 +947,15 @@ class PepQueryStructureService {
|
|
|
917
947
|
parentForm.removeControl(formKey);
|
|
918
948
|
componentRef.destroy();
|
|
919
949
|
this.createOutputQuery();
|
|
950
|
+
if (this._cmpRefMap.has(formKey)) {
|
|
951
|
+
this._cmpRefMap.delete(formKey);
|
|
952
|
+
}
|
|
920
953
|
});
|
|
921
954
|
componentRef.instance.operatorChange.subscribe(() => {
|
|
922
955
|
this.createOutputQuery();
|
|
923
956
|
});
|
|
957
|
+
// Add this to remove all the components when fields changes.
|
|
958
|
+
this._cmpRefMap.set(formKey, componentRef);
|
|
924
959
|
return {
|
|
925
960
|
containerRef: componentRef.instance.sectionContainer,
|
|
926
961
|
parentForm: sectionGroup
|
|
@@ -960,7 +995,12 @@ class PepQueryStructureService {
|
|
|
960
995
|
parentForm.removeControl(formKey);
|
|
961
996
|
componentRef.destroy();
|
|
962
997
|
this.createOutputQuery();
|
|
998
|
+
if (this._cmpRefMap.has(formKey)) {
|
|
999
|
+
this._cmpRefMap.delete(formKey);
|
|
1000
|
+
}
|
|
963
1001
|
});
|
|
1002
|
+
// Add this to remove all the components when fields changes.
|
|
1003
|
+
this._cmpRefMap.set(formKey, componentRef);
|
|
964
1004
|
}
|
|
965
1005
|
/**
|
|
966
1006
|
* get smart filter field
|
|
@@ -1109,8 +1149,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.2", ngImpor
|
|
|
1109
1149
|
}] } });
|
|
1110
1150
|
|
|
1111
1151
|
class PepQueryBuilderModule {
|
|
1152
|
+
constructor(pepIconRegistry) {
|
|
1153
|
+
this.pepIconRegistry = pepIconRegistry;
|
|
1154
|
+
this.pepIconRegistry.registerIcons([
|
|
1155
|
+
pepIconSystemBin,
|
|
1156
|
+
]);
|
|
1157
|
+
}
|
|
1112
1158
|
}
|
|
1113
|
-
PepQueryBuilderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: PepQueryBuilderModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1159
|
+
PepQueryBuilderModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: PepQueryBuilderModule, deps: [{ token: i1$1.PepIconRegistry }], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1114
1160
|
PepQueryBuilderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.0.2", ngImport: i0, type: PepQueryBuilderModule, declarations: [PepQueryBuilderComponent,
|
|
1115
1161
|
PepQueryBuilderSectionComponent,
|
|
1116
1162
|
PepQueryBuilderItemComponent], imports: [CommonModule,
|
|
@@ -1118,6 +1164,7 @@ PepQueryBuilderModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", v
|
|
|
1118
1164
|
FlexLayoutModule,
|
|
1119
1165
|
PepSelectModule,
|
|
1120
1166
|
PepButtonModule,
|
|
1167
|
+
PepIconModule,
|
|
1121
1168
|
PepGroupButtonsModule,
|
|
1122
1169
|
PepSmartFiltersModule], exports: [PepQueryBuilderComponent] });
|
|
1123
1170
|
PepQueryBuilderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: PepQueryBuilderModule, providers: [
|
|
@@ -1127,6 +1174,7 @@ PepQueryBuilderModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", v
|
|
|
1127
1174
|
FlexLayoutModule,
|
|
1128
1175
|
PepSelectModule,
|
|
1129
1176
|
PepButtonModule,
|
|
1177
|
+
PepIconModule,
|
|
1130
1178
|
PepGroupButtonsModule,
|
|
1131
1179
|
PepSmartFiltersModule] });
|
|
1132
1180
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.2", ngImport: i0, type: PepQueryBuilderModule, decorators: [{
|
|
@@ -1138,6 +1186,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.2", ngImpor
|
|
|
1138
1186
|
FlexLayoutModule,
|
|
1139
1187
|
PepSelectModule,
|
|
1140
1188
|
PepButtonModule,
|
|
1189
|
+
PepIconModule,
|
|
1141
1190
|
PepGroupButtonsModule,
|
|
1142
1191
|
PepSmartFiltersModule
|
|
1143
1192
|
],
|
|
@@ -1153,7 +1202,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.0.2", ngImpor
|
|
|
1153
1202
|
FormBuilder
|
|
1154
1203
|
]
|
|
1155
1204
|
}]
|
|
1156
|
-
}] });
|
|
1205
|
+
}], ctorParameters: function () { return [{ type: i1$1.PepIconRegistry }]; } });
|
|
1157
1206
|
|
|
1158
1207
|
/*
|
|
1159
1208
|
* Public API Surface of ngx-lib/query-builder
|