ngx-smz-ui 3.4.9 → 3.4.13
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/bundles/ngx-smz-ui.umd.js +88 -23
- package/bundles/ngx-smz-ui.umd.js.map +1 -1
- package/esm2015/lib/builders/smz-dialogs/dialog-input-conversion.js +24 -1
- package/esm2015/lib/modules/rbk-utils/utils/state/state.guard.js +3 -1
- package/esm2015/lib/modules/smz-dialogs/features/dialog-footer/dialog-footer.component.js +53 -10
- package/fesm2015/ngx-smz-ui.js +75 -10
- package/fesm2015/ngx-smz-ui.js.map +1 -1
- package/lib/modules/smz-dialogs/features/dialog-footer/dialog-footer.component.d.ts +3 -1
- package/package.json +1 -1
package/fesm2015/ngx-smz-ui.js
CHANGED
|
@@ -6,7 +6,7 @@ import * as i1$2 from '@angular/forms';
|
|
|
6
6
|
import { Validators, FormGroup, FormControl, NG_VALUE_ACCESSOR, FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
7
7
|
import { FlexLayoutModule } from '@angular/flex-layout';
|
|
8
8
|
import { DialogModule } from 'primeng/dialog';
|
|
9
|
-
import * as i7
|
|
9
|
+
import * as i7 from 'primeng/toast';
|
|
10
10
|
import { ToastModule } from 'primeng/toast';
|
|
11
11
|
import * as i5 from 'primeng/table';
|
|
12
12
|
import { ColumnFilter, Table, TableModule } from 'primeng/table';
|
|
@@ -14,7 +14,7 @@ import * as i6 from 'primeng/button';
|
|
|
14
14
|
import { ButtonModule } from 'primeng/button';
|
|
15
15
|
import { MessageModule } from 'primeng/message';
|
|
16
16
|
import { ProgressSpinnerModule } from 'primeng/progressspinner';
|
|
17
|
-
import * as
|
|
17
|
+
import * as i8 from 'primeng/toolbar';
|
|
18
18
|
import { ToolbarModule } from 'primeng/toolbar';
|
|
19
19
|
import * as i3$1 from 'primeng/listbox';
|
|
20
20
|
import { ListboxModule } from 'primeng/listbox';
|
|
@@ -4788,8 +4788,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImpor
|
|
|
4788
4788
|
}]
|
|
4789
4789
|
}] });
|
|
4790
4790
|
|
|
4791
|
+
class NgxRbkUtilsConfig {
|
|
4792
|
+
}
|
|
4793
|
+
|
|
4791
4794
|
let DialogFooterComponent = class DialogFooterComponent {
|
|
4792
|
-
constructor(refService, dialogConfig, presets, visibilityService, injectComponent, cdf, actions$, store) {
|
|
4795
|
+
constructor(refService, dialogConfig, presets, visibilityService, injectComponent, cdf, actions$, rbkConfig, store) {
|
|
4793
4796
|
this.refService = refService;
|
|
4794
4797
|
this.dialogConfig = dialogConfig;
|
|
4795
4798
|
this.presets = presets;
|
|
@@ -4797,6 +4800,7 @@ let DialogFooterComponent = class DialogFooterComponent {
|
|
|
4797
4800
|
this.injectComponent = injectComponent;
|
|
4798
4801
|
this.cdf = cdf;
|
|
4799
4802
|
this.actions$ = actions$;
|
|
4803
|
+
this.rbkConfig = rbkConfig;
|
|
4800
4804
|
this.store = store;
|
|
4801
4805
|
}
|
|
4802
4806
|
ngOnInit() {
|
|
@@ -4824,19 +4828,36 @@ let DialogFooterComponent = class DialogFooterComponent {
|
|
|
4824
4828
|
}
|
|
4825
4829
|
onSubmit() {
|
|
4826
4830
|
if (this.isValid()) {
|
|
4831
|
+
if (this.rbkConfig.debugMode) {
|
|
4832
|
+
console.log(' onSubmit => ', true);
|
|
4833
|
+
}
|
|
4827
4834
|
return true;
|
|
4828
4835
|
}
|
|
4829
4836
|
else {
|
|
4837
|
+
if (this.rbkConfig.debugMode) {
|
|
4838
|
+
console.log(' Forms... ');
|
|
4839
|
+
}
|
|
4830
4840
|
this.dialogConfig.data.features
|
|
4831
4841
|
.filter(x => x.type === 'form')
|
|
4832
4842
|
.forEach(feature => {
|
|
4833
4843
|
const formFeature = feature.data;
|
|
4834
4844
|
const form = formFeature._context.form;
|
|
4845
|
+
if (this.rbkConfig.debugMode) {
|
|
4846
|
+
console.log(' > formFeature:', formFeature);
|
|
4847
|
+
console.log(' > form:', form);
|
|
4848
|
+
console.log(' > controls:', form.controls);
|
|
4849
|
+
}
|
|
4835
4850
|
Object.keys(form.controls).forEach(field => {
|
|
4836
4851
|
const control = form.get(field);
|
|
4852
|
+
if (this.rbkConfig.debugMode) {
|
|
4853
|
+
console.log(` > control for ${field}:`, control);
|
|
4854
|
+
}
|
|
4837
4855
|
control.markAsTouched({ onlySelf: true });
|
|
4838
4856
|
});
|
|
4839
4857
|
});
|
|
4858
|
+
if (this.rbkConfig.debugMode) {
|
|
4859
|
+
console.log(' Components... ');
|
|
4860
|
+
}
|
|
4840
4861
|
this.dialogConfig.data.features
|
|
4841
4862
|
.filter(x => x.type === 'component')
|
|
4842
4863
|
.forEach(feature => {
|
|
@@ -4861,6 +4882,9 @@ let DialogFooterComponent = class DialogFooterComponent {
|
|
|
4861
4882
|
}
|
|
4862
4883
|
});
|
|
4863
4884
|
this.cdf.markForCheck();
|
|
4885
|
+
if (this.rbkConfig.debugMode) {
|
|
4886
|
+
console.log(' onSubmit => ', false);
|
|
4887
|
+
}
|
|
4864
4888
|
return false;
|
|
4865
4889
|
}
|
|
4866
4890
|
}
|
|
@@ -4880,6 +4904,12 @@ let DialogFooterComponent = class DialogFooterComponent {
|
|
|
4880
4904
|
}
|
|
4881
4905
|
save() {
|
|
4882
4906
|
var _a, _b;
|
|
4907
|
+
if (this.rbkConfig.debugMode) {
|
|
4908
|
+
console.groupCollapsed('Dialog Save Pressed:');
|
|
4909
|
+
console.log(' >> context', this.dialogConfig.data._context);
|
|
4910
|
+
console.log(' >> onSubmit()', this.onSubmit());
|
|
4911
|
+
console.log(' >> data', this.dialogConfig.data);
|
|
4912
|
+
}
|
|
4883
4913
|
const context = this.dialogConfig.data._context;
|
|
4884
4914
|
if (context.builtInButtons.saveDependsOnValidation && !this.onSubmit())
|
|
4885
4915
|
return;
|
|
@@ -4897,8 +4927,14 @@ let DialogFooterComponent = class DialogFooterComponent {
|
|
|
4897
4927
|
if (((_b = (_a = this.dialogConfig.data) === null || _a === void 0 ? void 0 : _a.callbacks) === null || _b === void 0 ? void 0 : _b.onSaveAction) != null) {
|
|
4898
4928
|
const postProcessResponse = this.responsePostProcesses();
|
|
4899
4929
|
const action = this.dialogConfig.data.callbacks.onSaveAction;
|
|
4930
|
+
if (this.rbkConfig.debugMode) {
|
|
4931
|
+
console.log(' >> postProcessResponse', postProcessResponse);
|
|
4932
|
+
}
|
|
4900
4933
|
this.store.dispatch(new action(postProcessResponse))
|
|
4901
4934
|
.pipe(catchError(err => {
|
|
4935
|
+
if (this.rbkConfig.debugMode) {
|
|
4936
|
+
console.log(' >> dispatch catchError', err);
|
|
4937
|
+
}
|
|
4902
4938
|
const errors = err.error;
|
|
4903
4939
|
this.dialogConfig.data._context.apiErrors = errors.map(x => ({ severity: 'warn', summary: '', detail: x }));
|
|
4904
4940
|
this.dialogConfig.data._context.isGlobalDisabled = false;
|
|
@@ -4914,12 +4950,18 @@ let DialogFooterComponent = class DialogFooterComponent {
|
|
|
4914
4950
|
return err;
|
|
4915
4951
|
}))
|
|
4916
4952
|
.subscribe(() => {
|
|
4953
|
+
if (this.rbkConfig.debugMode) {
|
|
4954
|
+
console.log(' >> dispatch subscribe');
|
|
4955
|
+
}
|
|
4917
4956
|
this.dialogConfig.data._context.isGlobalDisabled = false;
|
|
4918
4957
|
this.dialogConfig.data._context.isLoading = false;
|
|
4919
4958
|
this.dialogConfig.data._context.apiErrors = [];
|
|
4920
4959
|
this.refService.close();
|
|
4921
4960
|
});
|
|
4922
4961
|
}
|
|
4962
|
+
if (this.rbkConfig.debugMode) {
|
|
4963
|
+
console.groupEnd();
|
|
4964
|
+
}
|
|
4923
4965
|
}
|
|
4924
4966
|
customClick(button) {
|
|
4925
4967
|
if (button.blockUi != null) {
|
|
@@ -5015,11 +5057,14 @@ let DialogFooterComponent = class DialogFooterComponent {
|
|
|
5015
5057
|
var _a;
|
|
5016
5058
|
const config = this.dialogConfig.data;
|
|
5017
5059
|
const response = config.behaviors.useAdvancedResponse ? config._context.advancedResponse : config._context.simpleResponse;
|
|
5060
|
+
if (this.rbkConfig.debugMode) {
|
|
5061
|
+
console.log(' >> response', response);
|
|
5062
|
+
}
|
|
5018
5063
|
return ((_a = config.callbacks) === null || _a === void 0 ? void 0 : _a.postProcessResponse) != null ? config.callbacks.postProcessResponse(response) : response;
|
|
5019
5064
|
}
|
|
5020
5065
|
};
|
|
5021
|
-
DialogFooterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: DialogFooterComponent, deps: [{ token: DynamicDialogRef }, { token: SmzDynamicDialogConfig }, { token: SmzDialogsConfig }, { token: SmzDialogsVisibilityService }, { token: InjectComponentService }, { token: i0.ChangeDetectorRef }, { token: i1$4.Actions }, { token: i1$4.Store }], target: i0.ɵɵFactoryTarget.Component });
|
|
5022
|
-
DialogFooterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: DialogFooterComponent, selector: "smz-dialog-footer", ngImport: i0, template: "<ng-container *ngIf=\"dialogConfig.data._context as context\">\n\n <p-toolbar class=\"smz-dialog-footer\">\n <div class=\"p-grid p-nogutter p-align-center p-justify-end gap-2\">\n\n <ng-container *ngIf=\"context.customButtonsOrder == null || context.customButtonsOrder === 'first'\">\n <ng-container *ngFor=\"let customButton of context.customButtons\">\n <p-button\n *ngIf=\"customButton.visible == null || customButton.visible\"\n [label]=\"customButton.name\"\n [ngClass]=\"customButton.class\"\n [styleClass]=\"customButton.class\"\n [disabled]=\"context.isGlobalDisabled || customButton.dependsOnValidation && !isValid() || customButton.disabled\"\n [pTooltip]=\"customButton.tooltip\"\n appendTo=\"body\"\n tooltipPosition=\"top\"\n (onClick)=\"customClick(customButton)\">\n </p-button>\n </ng-container>\n </ng-container>\n\n <p-button\n *ngIf=\"context.behaviors.showCancelButton\"\n [label]=\"context.builtInButtons.cancelName\"\n [ngClass]=\"context.builtInButtons.cancelClass\"\n [styleClass]=\"context.builtInButtons.cancelClass\"\n (onClick)=\"close()\">\n </p-button>\n\n <!-- DependsOnValidation -->\n <p-button\n *ngIf=\"context.behaviors.showConfirmButton\"\n [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\"\n [dialogId]=\"context.id\"\n [label]=\"context.builtInButtons.confirmName\"\n [ngClass]=\"context.builtInButtons.confirmClass\"\n [styleClass]=\"context.builtInButtons.confirmClass\"\n [disabled]=\"context.isGlobalDisabled\"\n (onClick)=\"confirm()\">\n </p-button>\n\n <!-- DependsOnValidation -->\n <p-button\n *ngIf=\"context.behaviors.showOkButton\"\n [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\"\n [dialogId]=\"context.id\"\n [label]=\"context.builtInButtons.okName\"\n [ngClass]=\"context.builtInButtons.okClass\"\n [styleClass]=\"context.builtInButtons.okClass\"\n [disabled]=\"context.isGlobalDisabled\"\n (onClick)=\"ok()\">\n </p-button>\n\n <!-- DependsOnValidation -->\n <p-button\n *ngIf=\"context.behaviors.showSaveButton\"\n [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\"\n [dialogId]=\"context.id\"\n [label]=\"context.builtInButtons.saveName\"\n [ngClass]=\"context.builtInButtons.saveClass\"\n [styleClass]=\"context.builtInButtons.saveClass\"\n [icon]=\"context.isLoading ? 'fas fa-spinner fa-spin' : ''\"\n [disabled]=\"context.isGlobalDisabled\"\n (onClick)=\"save()\">\n </p-button>\n\n <ng-container *ngIf=\"context.customButtonsOrder === 'last'\">\n <ng-container *ngFor=\"let customButton of context.customButtons\">\n\n <!-- DependsOnValidation -->\n <p-button\n *ngIf=\"customButton.visible == null || customButton.visible\"\n [label]=\"customButton.name\"\n [ngClass]=\"customButton.class\"\n [styleClass]=\"customButton.class\"\n [disabled]=\"context.isGlobalDisabled || customButton.disabled\"\n [pTooltip]=\"customButton.tooltip\"\n appendTo=\"body\"\n tooltipPosition=\"top\"\n (onClick)=\"customClick(customButton)\">\n </p-button>\n </ng-container>\n </ng-container>\n\n </div>\n </p-toolbar>\n\n</ng-container>", styles: [""], components: [{ type: i0.forwardRef(function () { return
|
|
5066
|
+
DialogFooterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: DialogFooterComponent, deps: [{ token: DynamicDialogRef }, { token: SmzDynamicDialogConfig }, { token: SmzDialogsConfig }, { token: SmzDialogsVisibilityService }, { token: InjectComponentService }, { token: i0.ChangeDetectorRef }, { token: i1$4.Actions }, { token: NgxRbkUtilsConfig }, { token: i1$4.Store }], target: i0.ɵɵFactoryTarget.Component });
|
|
5067
|
+
DialogFooterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: DialogFooterComponent, selector: "smz-dialog-footer", ngImport: i0, template: "<ng-container *ngIf=\"dialogConfig.data._context as context\">\n\n <p-toolbar class=\"smz-dialog-footer\">\n <div class=\"p-grid p-nogutter p-align-center p-justify-end gap-2\">\n\n <ng-container *ngIf=\"context.customButtonsOrder == null || context.customButtonsOrder === 'first'\">\n <ng-container *ngFor=\"let customButton of context.customButtons\">\n <p-button\n *ngIf=\"customButton.visible == null || customButton.visible\"\n [label]=\"customButton.name\"\n [ngClass]=\"customButton.class\"\n [styleClass]=\"customButton.class\"\n [disabled]=\"context.isGlobalDisabled || customButton.dependsOnValidation && !isValid() || customButton.disabled\"\n [pTooltip]=\"customButton.tooltip\"\n appendTo=\"body\"\n tooltipPosition=\"top\"\n (onClick)=\"customClick(customButton)\">\n </p-button>\n </ng-container>\n </ng-container>\n\n <p-button\n *ngIf=\"context.behaviors.showCancelButton\"\n [label]=\"context.builtInButtons.cancelName\"\n [ngClass]=\"context.builtInButtons.cancelClass\"\n [styleClass]=\"context.builtInButtons.cancelClass\"\n (onClick)=\"close()\">\n </p-button>\n\n <!-- DependsOnValidation -->\n <p-button\n *ngIf=\"context.behaviors.showConfirmButton\"\n [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\"\n [dialogId]=\"context.id\"\n [label]=\"context.builtInButtons.confirmName\"\n [ngClass]=\"context.builtInButtons.confirmClass\"\n [styleClass]=\"context.builtInButtons.confirmClass\"\n [disabled]=\"context.isGlobalDisabled\"\n (onClick)=\"confirm()\">\n </p-button>\n\n <!-- DependsOnValidation -->\n <p-button\n *ngIf=\"context.behaviors.showOkButton\"\n [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\"\n [dialogId]=\"context.id\"\n [label]=\"context.builtInButtons.okName\"\n [ngClass]=\"context.builtInButtons.okClass\"\n [styleClass]=\"context.builtInButtons.okClass\"\n [disabled]=\"context.isGlobalDisabled\"\n (onClick)=\"ok()\">\n </p-button>\n\n <!-- DependsOnValidation -->\n <p-button\n *ngIf=\"context.behaviors.showSaveButton\"\n [confirmOnEnter]=\"context.isLoading ? false : context.behaviors.confirmOnEnter\"\n [dialogId]=\"context.id\"\n [label]=\"context.builtInButtons.saveName\"\n [ngClass]=\"context.builtInButtons.saveClass\"\n [styleClass]=\"context.builtInButtons.saveClass\"\n [icon]=\"context.isLoading ? 'fas fa-spinner fa-spin' : ''\"\n [disabled]=\"context.isGlobalDisabled\"\n (onClick)=\"save()\">\n </p-button>\n\n <ng-container *ngIf=\"context.customButtonsOrder === 'last'\">\n <ng-container *ngFor=\"let customButton of context.customButtons\">\n\n <!-- DependsOnValidation -->\n <p-button\n *ngIf=\"customButton.visible == null || customButton.visible\"\n [label]=\"customButton.name\"\n [ngClass]=\"customButton.class\"\n [styleClass]=\"customButton.class\"\n [disabled]=\"context.isGlobalDisabled || customButton.disabled\"\n [pTooltip]=\"customButton.tooltip\"\n appendTo=\"body\"\n tooltipPosition=\"top\"\n (onClick)=\"customClick(customButton)\">\n </p-button>\n </ng-container>\n </ng-container>\n\n </div>\n </p-toolbar>\n\n</ng-container>", styles: [""], components: [{ type: i0.forwardRef(function () { return i8.Toolbar; }), selector: "p-toolbar", inputs: ["style", "styleClass"] }, { type: i0.forwardRef(function () { return i6.Button; }), selector: "p-button", inputs: ["type", "iconPos", "icon", "badge", "label", "disabled", "loading", "loadingIcon", "style", "styleClass", "badgeClass"], outputs: ["onClick", "onFocus", "onBlur"] }], directives: [{ type: i0.forwardRef(function () { return i1.NgIf; }), selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i0.forwardRef(function () { return i1.NgForOf; }), selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i0.forwardRef(function () { return i1.NgClass; }), selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i0.forwardRef(function () { return i4$1.DefaultClassDirective; }), selector: " [ngClass], [ngClass.xs], [ngClass.sm], [ngClass.md], [ngClass.lg], [ngClass.xl], [ngClass.lt-sm], [ngClass.lt-md], [ngClass.lt-lg], [ngClass.lt-xl], [ngClass.gt-xs], [ngClass.gt-sm], [ngClass.gt-md], [ngClass.gt-lg]", inputs: ["ngClass", "ngClass.xs", "ngClass.sm", "ngClass.md", "ngClass.lg", "ngClass.xl", "ngClass.lt-sm", "ngClass.lt-md", "ngClass.lt-lg", "ngClass.lt-xl", "ngClass.gt-xs", "ngClass.gt-sm", "ngClass.gt-md", "ngClass.gt-lg"] }, { type: i0.forwardRef(function () { return i10.Tooltip; }), selector: "[pTooltip]", inputs: ["tooltipPosition", "tooltipEvent", "appendTo", "positionStyle", "tooltipStyleClass", "tooltipZIndex", "escape", "showDelay", "hideDelay", "life", "positionTop", "positionLeft", "pTooltip", "tooltipDisabled", "tooltipOptions"] }, { type: i0.forwardRef(function () { return ConfirmOnEnterDirective; }), selector: "[confirmOnEnter]", inputs: ["confirmOnEnter", "clickEvent", "delayConfirmation", "disabled", "dialogId"] }], encapsulation: i0.ViewEncapsulation.None });
|
|
5023
5068
|
DialogFooterComponent = __decorate([
|
|
5024
5069
|
UntilDestroy()
|
|
5025
5070
|
], DialogFooterComponent);
|
|
@@ -5031,7 +5076,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.5", ngImpor
|
|
|
5031
5076
|
styleUrls: ['./dialog-footer.component.scss'],
|
|
5032
5077
|
encapsulation: ViewEncapsulation.None,
|
|
5033
5078
|
}]
|
|
5034
|
-
}], ctorParameters: function () { return [{ type: DynamicDialogRef }, { type: SmzDynamicDialogConfig }, { type: SmzDialogsConfig }, { type: SmzDialogsVisibilityService }, { type: InjectComponentService }, { type: i0.ChangeDetectorRef }, { type: i1$4.Actions }, { type: i1$4.Store }]; } });
|
|
5079
|
+
}], ctorParameters: function () { return [{ type: DynamicDialogRef }, { type: SmzDynamicDialogConfig }, { type: SmzDialogsConfig }, { type: SmzDialogsVisibilityService }, { type: InjectComponentService }, { type: i0.ChangeDetectorRef }, { type: i1$4.Actions }, { type: NgxRbkUtilsConfig }, { type: i1$4.Store }]; } });
|
|
5035
5080
|
class ConfirmOnEnterDirective {
|
|
5036
5081
|
constructor(el, store) {
|
|
5037
5082
|
this.el = el;
|
|
@@ -5377,9 +5422,6 @@ class GlobalInjector$1 {
|
|
|
5377
5422
|
}
|
|
5378
5423
|
GlobalInjector$1.instance = null;
|
|
5379
5424
|
|
|
5380
|
-
class NgxRbkUtilsConfig {
|
|
5381
|
-
}
|
|
5382
|
-
|
|
5383
5425
|
const LOADING_BEHAVIOR_HEADER = 'Loading-Behavior';
|
|
5384
5426
|
const ERROR_HANDLING_TYPE_HEADER = 'Error-Handling-Type';
|
|
5385
5427
|
const REFRESH_TOKEN_BEHAVIOR_HEADER = 'Refresh-Token-Behavior';
|
|
@@ -10437,6 +10479,7 @@ function convertFormFeature(entityName, store, entity = null, options = null) {
|
|
|
10437
10479
|
}
|
|
10438
10480
|
function convertFormFeatureFromInputData(groups, entity = null, options = null, store) {
|
|
10439
10481
|
var _a, _b, _c;
|
|
10482
|
+
const rbkConfig = GlobalInjector.instance.get(NgxRbkUtilsConfig);
|
|
10440
10483
|
const form = {
|
|
10441
10484
|
groups: [],
|
|
10442
10485
|
behaviors: {}
|
|
@@ -10539,10 +10582,16 @@ function convertFormFeatureFromInputData(groups, entity = null, options = null,
|
|
|
10539
10582
|
return smzFeature;
|
|
10540
10583
|
}
|
|
10541
10584
|
function convertInputs(inputs, store, options) {
|
|
10585
|
+
const rbkConfig = GlobalInjector.instance.get(NgxRbkUtilsConfig);
|
|
10542
10586
|
const results = [];
|
|
10543
10587
|
if (inputs == null)
|
|
10544
10588
|
throw new Error('Inputs could not be null');
|
|
10545
10589
|
for (const config of inputs) {
|
|
10590
|
+
if (rbkConfig.debugMode) {
|
|
10591
|
+
console.groupCollapsed(config.propertyName);
|
|
10592
|
+
console.log('config', config);
|
|
10593
|
+
console.log('options', options);
|
|
10594
|
+
}
|
|
10546
10595
|
if (config.controlType.id === `${SmzControlType.TEXT}`) {
|
|
10547
10596
|
const input = Object.assign(Object.assign({}, convertBaseControl(config)), { defaultValue: config.defaultValue, type: SmzControlType.TEXT });
|
|
10548
10597
|
results.push(input);
|
|
@@ -10565,6 +10614,9 @@ function convertInputs(inputs, store, options) {
|
|
|
10565
10614
|
}
|
|
10566
10615
|
else if (config.controlType.id === `${SmzControlType.DROPDOWN}`) {
|
|
10567
10616
|
const list = getInputOptions(config, store, options);
|
|
10617
|
+
if (rbkConfig.debugMode) {
|
|
10618
|
+
console.log('list', list);
|
|
10619
|
+
}
|
|
10568
10620
|
const input = Object.assign(Object.assign({}, convertBaseControl(config)), { defaultValue: config.required ? list[0].id : config.defaultValue, type: SmzControlType.DROPDOWN, filterMatchMode: config.filterMatchMode, showFilter: config.showFilter, options: list });
|
|
10569
10621
|
results.push(input);
|
|
10570
10622
|
}
|
|
@@ -10613,6 +10665,10 @@ function convertInputs(inputs, store, options) {
|
|
|
10613
10665
|
results.push(parentInput);
|
|
10614
10666
|
results.push(childInput);
|
|
10615
10667
|
}
|
|
10668
|
+
if (rbkConfig.debugMode) {
|
|
10669
|
+
console.log('results', results[(results === null || results === void 0 ? void 0 : results.length) - 1]);
|
|
10670
|
+
console.groupEnd();
|
|
10671
|
+
}
|
|
10616
10672
|
}
|
|
10617
10673
|
return results;
|
|
10618
10674
|
}
|
|
@@ -10671,6 +10727,13 @@ function getDataFromStore(config, store, options) {
|
|
|
10671
10727
|
if (storeData === null) {
|
|
10672
10728
|
throw new Error('The data was loaded from the store, but it seems to be null. Please check that your store is populated or that your selector is not returning null');
|
|
10673
10729
|
}
|
|
10730
|
+
const rbkConfig = GlobalInjector.instance.get(NgxRbkUtilsConfig);
|
|
10731
|
+
if (rbkConfig.debugMode) {
|
|
10732
|
+
console.log(' >> getDataFromStore()');
|
|
10733
|
+
console.log(' >> config', storeData);
|
|
10734
|
+
console.log(' >> options', options);
|
|
10735
|
+
console.log(' >> storeData', storeData);
|
|
10736
|
+
}
|
|
10674
10737
|
return storeData;
|
|
10675
10738
|
}
|
|
10676
10739
|
function convertBaseControl(config) {
|
|
@@ -14156,7 +14219,7 @@ class OutletComponent {
|
|
|
14156
14219
|
}
|
|
14157
14220
|
}
|
|
14158
14221
|
OutletComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.5", ngImport: i0, type: OutletComponent, deps: [{ token: SmzLayoutsConfig }, { token: RouterDataListenerService }, { token: i1$4.Store }, { token: PrimeConfigService }], target: i0.ɵɵFactoryTarget.Component });
|
|
14159
|
-
OutletComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: OutletComponent, selector: "smz-ui-outlet", inputs: { menu: "menu" }, host: { listeners: { "mouseleave": "onMouseLeave()", "mouseenter": "onBeforeUnload()" } }, queries: [{ propertyName: "templates", predicate: PrimeTemplate }], ngImport: i0, template: "<ng-container [ngSwitch]=\"routerListener.data?.layout?.mode\">\n\n <!-- LAYOUT SIMPLES -->\n <ng-container *ngSwitchCase=\"'none'\">\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n\n <!-- LAYOUT COMPLETO -->\n <ng-container *ngSwitchCase=\"'full'\">\n <ng-container *ngTemplateOutlet=\"layoutTemplate\">\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n </ng-container>\n\n <!-- LAYOUT COMPLETO -->\n <ng-container *ngSwitchCase=\"'menu-only'\">\n <ng-container *ngTemplateOutlet=\"layoutTemplate\">\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'custom'\">\n <ng-container *ngTemplateOutlet=\"layoutTemplate\">\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <!-- Nenhum tipo de layout foi encontrado. -->\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n</ng-container>\n\n<smz-ui-theme-manager></smz-ui-theme-manager>\n<smz-ui-global-loader></smz-ui-global-loader>\n\n<ng-container *ngIf=\"toast$ | async as toast\">\n <p-toast [position]=\"toast.position\"></p-toast>\n</ng-container>", styles: [""], components: [{ type: ThemeManagerComponent, selector: "smz-ui-theme-manager" }, { type: GlobalLoaderComponent, selector: "smz-ui-global-loader", inputs: ["template"] }, { type: i7
|
|
14222
|
+
OutletComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.0.5", type: OutletComponent, selector: "smz-ui-outlet", inputs: { menu: "menu" }, host: { listeners: { "mouseleave": "onMouseLeave()", "mouseenter": "onBeforeUnload()" } }, queries: [{ propertyName: "templates", predicate: PrimeTemplate }], ngImport: i0, template: "<ng-container [ngSwitch]=\"routerListener.data?.layout?.mode\">\n\n <!-- LAYOUT SIMPLES -->\n <ng-container *ngSwitchCase=\"'none'\">\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n\n <!-- LAYOUT COMPLETO -->\n <ng-container *ngSwitchCase=\"'full'\">\n <ng-container *ngTemplateOutlet=\"layoutTemplate\">\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n </ng-container>\n\n <!-- LAYOUT COMPLETO -->\n <ng-container *ngSwitchCase=\"'menu-only'\">\n <ng-container *ngTemplateOutlet=\"layoutTemplate\">\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"'custom'\">\n <ng-container *ngTemplateOutlet=\"layoutTemplate\">\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n </ng-container>\n\n <ng-container *ngSwitchDefault>\n <!-- Nenhum tipo de layout foi encontrado. -->\n <ng-container *ngTemplateOutlet=\"contentTemplate\"></ng-container>\n </ng-container>\n</ng-container>\n\n<smz-ui-theme-manager></smz-ui-theme-manager>\n<smz-ui-global-loader></smz-ui-global-loader>\n\n<ng-container *ngIf=\"toast$ | async as toast\">\n <p-toast [position]=\"toast.position\"></p-toast>\n</ng-container>", styles: [""], components: [{ type: ThemeManagerComponent, selector: "smz-ui-theme-manager" }, { type: GlobalLoaderComponent, selector: "smz-ui-global-loader", inputs: ["template"] }, { type: i7.Toast, selector: "p-toast", inputs: ["key", "autoZIndex", "baseZIndex", "style", "styleClass", "position", "preventOpenDuplicates", "preventDuplicates", "showTransformOptions", "hideTransformOptions", "showTransitionOptions", "hideTransitionOptions", "breakpoints"], outputs: ["onClose"] }], directives: [{ type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], pipes: { "async": i1.AsyncPipe } });
|
|
14160
14223
|
__decorate([
|
|
14161
14224
|
Select(LayoutUiSelectors.toast)
|
|
14162
14225
|
], OutletComponent.prototype, "toast$", void 0);
|
|
@@ -21323,6 +21386,8 @@ class RbkDatabaseStateGuard {
|
|
|
21323
21386
|
this.store.dispatch(stateConfig.loadAction);
|
|
21324
21387
|
}
|
|
21325
21388
|
}
|
|
21389
|
+
if (this.config.debugMode)
|
|
21390
|
+
console.groupEnd();
|
|
21326
21391
|
return this.store
|
|
21327
21392
|
.select(DatabaseSelectors.areStatesInitialized(states))
|
|
21328
21393
|
.pipe(filter(x => x !== false), tap(() => {
|