@mediusinc/mng-commons 0.15.1 → 0.16.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/esm2020/lib/components/action/action.component.mjs +7 -7
- package/esm2020/lib/components/action/editor/action-editor.component.mjs +41 -20
- package/esm2020/lib/components/action/route/action-route.component.mjs +3 -3
- package/esm2020/lib/components/form/editor/form-editor.component.mjs +29 -29
- package/esm2020/lib/components/form/formly/fields/formly-field-lookup-dialog/formly-field-lookup-dialog.component.mjs +3 -3
- package/esm2020/lib/components/form/formly/fields/formly-field-table-dialog-form/formly-field-table-dialog-form.component.mjs +13 -18
- package/esm2020/lib/components/form/formly/fields/formly-field-table-dialog-multiselect/formly-field-table-dialog-multiselect.component.mjs +7 -9
- package/esm2020/lib/components/layout/topbar.component.mjs +2 -2
- package/esm2020/lib/components/tableview/route/tableview-route.abstract.component.mjs +5 -5
- package/esm2020/lib/components/tableview/table/table.component.mjs +1 -1
- package/esm2020/lib/components/tableview/tableview.component.mjs +16 -14
- package/esm2020/lib/descriptors/action.descriptor.mjs +19 -13
- package/esm2020/lib/descriptors/editor.descriptor.mjs +5 -8
- package/esm2020/lib/descriptors/field.descriptor.mjs +2 -2
- package/esm2020/lib/descriptors/tableview.descriptor.mjs +32 -32
- package/esm2020/lib/descriptors/types/editor.type.mjs +8 -8
- package/esm2020/lib/models/view-container.model.mjs +1 -1
- package/esm2020/lib/router/tableview-route-builder.mjs +2 -2
- package/esm2020/lib/security/model/permissions.model.mjs +1 -9
- package/esm2020/lib/services/action-executor.service.mjs +8 -12
- package/esm2020/lib/services/commons.service.mjs +21 -10
- package/esm2020/lib/services/view-container.component.service.mjs +21 -8
- package/fesm2015/mediusinc-mng-commons.mjs +596 -562
- package/fesm2015/mediusinc-mng-commons.mjs.map +1 -1
- package/fesm2020/mediusinc-mng-commons.mjs +578 -546
- package/fesm2020/mediusinc-mng-commons.mjs.map +1 -1
- package/lib/components/action/editor/action-editor.component.d.ts +1 -2
- package/lib/components/form/editor/form-editor.component.d.ts +1 -1
- package/lib/components/form/formly/fields/formly-field-table-dialog-form/formly-field-table-dialog-form.component.d.ts +0 -3
- package/lib/components/form/formly/fields/formly-field-table-dialog-multiselect/formly-field-table-dialog-multiselect.component.d.ts +0 -2
- package/lib/components/tableview/tableview.component.d.ts +2 -2
- package/lib/descriptors/action.descriptor.d.ts +6 -4
- package/lib/descriptors/editor.descriptor.d.ts +5 -6
- package/lib/descriptors/tableview.descriptor.d.ts +5 -5
- package/lib/descriptors/types/editor.type.d.ts +2 -2
- package/lib/models/view-container.model.d.ts +31 -0
- package/lib/router/tableview-route-builder.d.ts +1 -1
- package/lib/security/model/permissions.model.d.ts +0 -7
- package/lib/services/commons.service.d.ts +4 -2
- package/lib/services/view-container.component.service.d.ts +12 -6
- package/package.json +1 -1
- package/scss/mng-overrides/_layout_dialog.scss +7 -8
- package/scss/mng-overrides/_theme_dialog.scss +57 -1
- package/scss/mng-overrides/_variables.scss +3 -0
- package/version-info.json +5 -5
|
@@ -28,19 +28,19 @@ import { ChipModule } from 'primeng/chip';
|
|
|
28
28
|
import * as i9 from 'primeng/confirmdialog';
|
|
29
29
|
import { ConfirmDialogModule } from 'primeng/confirmdialog';
|
|
30
30
|
import { ConfirmPopupModule } from 'primeng/confirmpopup';
|
|
31
|
-
import * as i6$
|
|
31
|
+
import * as i6$4 from 'primeng/dialog';
|
|
32
32
|
import { DialogModule } from 'primeng/dialog';
|
|
33
|
-
import * as i5$
|
|
33
|
+
import * as i5$2 from 'primeng/dropdown';
|
|
34
34
|
import { Dropdown, DropdownModule } from 'primeng/dropdown';
|
|
35
35
|
import * as i3 from 'primeng/dynamicdialog';
|
|
36
36
|
import { DynamicDialogModule, DialogService } from 'primeng/dynamicdialog';
|
|
37
37
|
import * as i3$1 from 'primeng/fieldset';
|
|
38
38
|
import { FieldsetModule } from 'primeng/fieldset';
|
|
39
|
-
import * as i5$
|
|
39
|
+
import * as i5$3 from 'primeng/fileupload';
|
|
40
40
|
import { FileUploadModule } from 'primeng/fileupload';
|
|
41
41
|
import * as i7$2 from 'primeng/inputmask';
|
|
42
42
|
import { InputMaskModule } from 'primeng/inputmask';
|
|
43
|
-
import * as i6$
|
|
43
|
+
import * as i6$2 from 'primeng/inputnumber';
|
|
44
44
|
import { InputNumberModule } from 'primeng/inputnumber';
|
|
45
45
|
import * as i8 from 'primeng/inputswitch';
|
|
46
46
|
import { InputSwitchModule } from 'primeng/inputswitch';
|
|
@@ -48,21 +48,21 @@ import * as i9$1 from 'primeng/inputtext';
|
|
|
48
48
|
import { InputTextModule } from 'primeng/inputtext';
|
|
49
49
|
import * as i10 from 'primeng/inputtextarea';
|
|
50
50
|
import { InputTextareaModule } from 'primeng/inputtextarea';
|
|
51
|
-
import * as i5 from 'primeng/messages';
|
|
51
|
+
import * as i5$1 from 'primeng/messages';
|
|
52
52
|
import { MessagesModule } from 'primeng/messages';
|
|
53
|
-
import * as i6
|
|
53
|
+
import * as i6 from 'primeng/multiselect';
|
|
54
54
|
import { MultiSelectModule } from 'primeng/multiselect';
|
|
55
55
|
import { PaginatorModule } from 'primeng/paginator';
|
|
56
56
|
import * as i7$1 from 'primeng/progressspinner';
|
|
57
57
|
import { ProgressSpinnerModule } from 'primeng/progressspinner';
|
|
58
58
|
import * as i11 from 'primeng/radiobutton';
|
|
59
59
|
import { RadioButtonModule } from 'primeng/radiobutton';
|
|
60
|
-
import * as
|
|
60
|
+
import * as i5 from 'primeng/ripple';
|
|
61
61
|
import { RippleModule } from 'primeng/ripple';
|
|
62
62
|
import { SelectButtonModule } from 'primeng/selectbutton';
|
|
63
63
|
import * as i7$3 from 'primeng/skeleton';
|
|
64
64
|
import { SkeletonModule } from 'primeng/skeleton';
|
|
65
|
-
import * as i6$
|
|
65
|
+
import * as i6$3 from 'primeng/table';
|
|
66
66
|
import { ColumnFilter, Table, TableModule } from 'primeng/table';
|
|
67
67
|
import * as i4$4 from 'primeng/tabview';
|
|
68
68
|
import { TabViewModule } from 'primeng/tabview';
|
|
@@ -70,11 +70,11 @@ import { TagModule } from 'primeng/tag';
|
|
|
70
70
|
import * as i7$4 from 'primeng/toast';
|
|
71
71
|
import { ToastModule } from 'primeng/toast';
|
|
72
72
|
import { ToggleButtonModule } from 'primeng/togglebutton';
|
|
73
|
-
import * as i6$
|
|
73
|
+
import * as i6$1 from 'primeng/toolbar';
|
|
74
74
|
import { ToolbarModule } from 'primeng/toolbar';
|
|
75
75
|
import * as i7 from 'primeng/tooltip';
|
|
76
76
|
import { TooltipModule } from 'primeng/tooltip';
|
|
77
|
-
import { isObservable, throwError,
|
|
77
|
+
import { isObservable, throwError, BehaviorSubject, Subject, ReplaySubject, distinctUntilChanged, of, combineLatest, tap, switchMap, mergeMap as mergeMap$1, from, Observable, merge, debounceTime } from 'rxjs';
|
|
78
78
|
import { map, mergeMap, catchError, first, filter, finalize, startWith } from 'rxjs/operators';
|
|
79
79
|
import 'reflect-metadata';
|
|
80
80
|
import * as i4 from '@angular/platform-browser';
|
|
@@ -577,6 +577,257 @@ DateUtil.NG_PRIME_FORMAT_MAP = {
|
|
|
577
577
|
YYYY: 'yy'
|
|
578
578
|
};
|
|
579
579
|
|
|
580
|
+
class ActionError {
|
|
581
|
+
constructor(error, // error details
|
|
582
|
+
dismissed = false // by user
|
|
583
|
+
) {
|
|
584
|
+
this.error = error;
|
|
585
|
+
this.dismissed = dismissed;
|
|
586
|
+
}
|
|
587
|
+
}
|
|
588
|
+
/**
|
|
589
|
+
* Action execution instance containing data about execution state of action
|
|
590
|
+
*/
|
|
591
|
+
class ActionInstance {
|
|
592
|
+
constructor(action, state = ActionInstanceStateEnum.TriggerStart, debug = false) {
|
|
593
|
+
this.debug = debug;
|
|
594
|
+
// function execution
|
|
595
|
+
this.isRunLoadingSubject = new BehaviorSubject(false);
|
|
596
|
+
this.contexts = [];
|
|
597
|
+
this.executionSubject = new Subject();
|
|
598
|
+
this.executionIsRunningSubject = new BehaviorSubject(false);
|
|
599
|
+
this.stateSubject = new BehaviorSubject(1);
|
|
600
|
+
this.resultSubject = new ReplaySubject(1);
|
|
601
|
+
this.errorSubject = new ReplaySubject(1);
|
|
602
|
+
this.contextExecutionSubscriptions = [];
|
|
603
|
+
this.instanceId = Math.random().toString(36).substring(2);
|
|
604
|
+
this.instanceLongName = `${action.actionNameLong}_${this.instanceId}`;
|
|
605
|
+
this.action = action;
|
|
606
|
+
this.state = state;
|
|
607
|
+
}
|
|
608
|
+
get isRunLoading$() {
|
|
609
|
+
return this.isRunLoadingSubject.asObservable();
|
|
610
|
+
}
|
|
611
|
+
get context() {
|
|
612
|
+
return this.contexts.length === 0 ? undefined : this.contexts[this.contexts.length - 1];
|
|
613
|
+
}
|
|
614
|
+
get execution$() {
|
|
615
|
+
return this.executionSubject.asObservable();
|
|
616
|
+
}
|
|
617
|
+
get executionIsRunning$() {
|
|
618
|
+
return this.executionIsRunningSubject.asObservable().pipe(distinctUntilChanged());
|
|
619
|
+
}
|
|
620
|
+
get state() {
|
|
621
|
+
return this.stateSubject.value;
|
|
622
|
+
}
|
|
623
|
+
set state(state) {
|
|
624
|
+
if (state > this.stateSubject.value) {
|
|
625
|
+
if (this.debug) {
|
|
626
|
+
console.debug(`ActionInstance ${this.instanceLongName} - state #${state}: ${ActionInstanceStateEnum[state]}`);
|
|
627
|
+
}
|
|
628
|
+
this.stateSubject.next(state);
|
|
629
|
+
}
|
|
630
|
+
}
|
|
631
|
+
get state$() {
|
|
632
|
+
return this.stateSubject.asObservable().pipe(distinctUntilChanged());
|
|
633
|
+
}
|
|
634
|
+
get result() {
|
|
635
|
+
return this._result;
|
|
636
|
+
}
|
|
637
|
+
set result(result) {
|
|
638
|
+
if (typeof result === 'undefined') {
|
|
639
|
+
return;
|
|
640
|
+
}
|
|
641
|
+
if (this.debug) {
|
|
642
|
+
console.debug(`ActionInstance ${this.instanceLongName} - result`, result);
|
|
643
|
+
}
|
|
644
|
+
this._result = result;
|
|
645
|
+
this.resultSubject.next(result);
|
|
646
|
+
}
|
|
647
|
+
get result$() {
|
|
648
|
+
return this.resultSubject.asObservable();
|
|
649
|
+
}
|
|
650
|
+
get error() {
|
|
651
|
+
return this._error;
|
|
652
|
+
}
|
|
653
|
+
set error(error) {
|
|
654
|
+
if (typeof error === 'undefined') {
|
|
655
|
+
return;
|
|
656
|
+
}
|
|
657
|
+
if (this.debug) {
|
|
658
|
+
console.debug(`ActionInstance ${this.instanceLongName} - error`, error);
|
|
659
|
+
}
|
|
660
|
+
this._error = error;
|
|
661
|
+
this.errorSubject.next(error);
|
|
662
|
+
}
|
|
663
|
+
get error$() {
|
|
664
|
+
return this.errorSubject.asObservable();
|
|
665
|
+
}
|
|
666
|
+
contextAt(idx) {
|
|
667
|
+
return idx < this.contexts.length ? this.contexts[idx] : undefined;
|
|
668
|
+
}
|
|
669
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
670
|
+
newContext(context, finishPrevious = true) {
|
|
671
|
+
if (this.debug) {
|
|
672
|
+
console.debug(`ActionInstance ${this.instanceLongName} - new context ${context.contextLongName}`);
|
|
673
|
+
}
|
|
674
|
+
const currentContext = this.context;
|
|
675
|
+
if (currentContext) {
|
|
676
|
+
currentContext.executionComplete();
|
|
677
|
+
}
|
|
678
|
+
this.contextExecutionSubscriptions.forEach(s => s.unsubscribe());
|
|
679
|
+
this.contextExecutionSubscriptions = [];
|
|
680
|
+
this.contextExecutionSubscriptions.push(context.execution$.subscribe({
|
|
681
|
+
next: next => this.executionSubject.next(next),
|
|
682
|
+
error: error => this.executionSubject.error(error)
|
|
683
|
+
}));
|
|
684
|
+
this.contextExecutionSubscriptions.push(context.executionIsRunning$.subscribe({
|
|
685
|
+
next: next => this.executionIsRunningSubject.next(next)
|
|
686
|
+
}));
|
|
687
|
+
this.contexts.push(context);
|
|
688
|
+
}
|
|
689
|
+
finish() {
|
|
690
|
+
if (this.stateSubject.value < ActionInstanceStateEnum.FinishSuccess) {
|
|
691
|
+
this.state = ActionInstanceStateEnum.FinishSuccess;
|
|
692
|
+
}
|
|
693
|
+
// complete all subjects
|
|
694
|
+
this.contexts.forEach(c => c.finish());
|
|
695
|
+
this.executionSubject.complete();
|
|
696
|
+
this.executionIsRunningSubject.complete();
|
|
697
|
+
this.stateSubject.complete();
|
|
698
|
+
this.resultSubject.complete();
|
|
699
|
+
this.errorSubject.complete();
|
|
700
|
+
}
|
|
701
|
+
}
|
|
702
|
+
/**
|
|
703
|
+
* Class containing all main data for action to be executed in run/fetch/submit states.
|
|
704
|
+
*/
|
|
705
|
+
class ActionContext {
|
|
706
|
+
constructor(instance, parameters, functionName, dataProvider, serviceInstance, executionSubject = new ReplaySubject(1), executionIsRunningSubject = new BehaviorSubject(false)) {
|
|
707
|
+
this.instance = instance;
|
|
708
|
+
this.parameters = parameters;
|
|
709
|
+
this.functionName = functionName;
|
|
710
|
+
this.dataProvider = dataProvider;
|
|
711
|
+
this.serviceInstance = serviceInstance;
|
|
712
|
+
this.executionSubject = executionSubject;
|
|
713
|
+
this.executionIsRunningSubject = executionIsRunningSubject;
|
|
714
|
+
this.contextLongName = `${this.instance.instanceLongName}_${functionName}`;
|
|
715
|
+
}
|
|
716
|
+
get execution$() {
|
|
717
|
+
return this.executionSubject.asObservable();
|
|
718
|
+
}
|
|
719
|
+
get executionIsRunning$() {
|
|
720
|
+
return this.executionIsRunningSubject.asObservable().pipe(distinctUntilChanged());
|
|
721
|
+
}
|
|
722
|
+
executionStart() {
|
|
723
|
+
if (this.instance.debug) {
|
|
724
|
+
console.debug(`ActionContext ${this.contextLongName} - execution start`);
|
|
725
|
+
}
|
|
726
|
+
this.executionIsRunningSubject.next(true);
|
|
727
|
+
}
|
|
728
|
+
executionNext(next, finish = true) {
|
|
729
|
+
if (this.instance.debug) {
|
|
730
|
+
console.debug(`ActionContext ${this.contextLongName} - execution next event`, next, finish);
|
|
731
|
+
}
|
|
732
|
+
this.executionSubject.next(next);
|
|
733
|
+
if (finish) {
|
|
734
|
+
this.executionComplete();
|
|
735
|
+
}
|
|
736
|
+
}
|
|
737
|
+
executionComplete() {
|
|
738
|
+
if (this.instance.debug) {
|
|
739
|
+
console.debug(`ActionContext ${this.contextLongName} - execution complete`);
|
|
740
|
+
}
|
|
741
|
+
this.executionSubject.complete();
|
|
742
|
+
this.executionIsRunningSubject.next(false);
|
|
743
|
+
}
|
|
744
|
+
executionError(err) {
|
|
745
|
+
if (this.instance.debug) {
|
|
746
|
+
console.debug(`ActionContext ${this.contextLongName} - execution error`, err);
|
|
747
|
+
}
|
|
748
|
+
this.executionSubject.error(err);
|
|
749
|
+
this.executionIsRunningSubject.next(false);
|
|
750
|
+
}
|
|
751
|
+
finish() {
|
|
752
|
+
this.executionSubject.complete();
|
|
753
|
+
this.executionIsRunningSubject.complete();
|
|
754
|
+
}
|
|
755
|
+
}
|
|
756
|
+
/**
|
|
757
|
+
* Class containing all main data for action validations (enabled/visible) to be executed in validation states.
|
|
758
|
+
*/
|
|
759
|
+
class ActionContextValidation {
|
|
760
|
+
constructor(descriptor, parameters, dataProvider, serviceInstance) {
|
|
761
|
+
this.descriptor = descriptor;
|
|
762
|
+
this.parameters = parameters;
|
|
763
|
+
this.dataProvider = dataProvider;
|
|
764
|
+
this.serviceInstance = serviceInstance;
|
|
765
|
+
}
|
|
766
|
+
}
|
|
767
|
+
class ActionParameters {
|
|
768
|
+
constructor(itemId, item) {
|
|
769
|
+
this.itemId = itemId;
|
|
770
|
+
this.item = item;
|
|
771
|
+
this.selectedItems = [];
|
|
772
|
+
}
|
|
773
|
+
withActionData(actionData) {
|
|
774
|
+
this.actionData = actionData;
|
|
775
|
+
return this;
|
|
776
|
+
}
|
|
777
|
+
withQueryParam(queryParam) {
|
|
778
|
+
this.queryParam = queryParam;
|
|
779
|
+
return this;
|
|
780
|
+
}
|
|
781
|
+
withViewContainer(viewContainer) {
|
|
782
|
+
this.viewContainer = viewContainer;
|
|
783
|
+
return this;
|
|
784
|
+
}
|
|
785
|
+
withSourceComponent(sourceComponent) {
|
|
786
|
+
this.sourceComponent = sourceComponent;
|
|
787
|
+
return this;
|
|
788
|
+
}
|
|
789
|
+
withRoute(route) {
|
|
790
|
+
this.route = route;
|
|
791
|
+
return this;
|
|
792
|
+
}
|
|
793
|
+
withSelectedItems(selectedItems) {
|
|
794
|
+
this.selectedItems = selectedItems;
|
|
795
|
+
return this;
|
|
796
|
+
}
|
|
797
|
+
}
|
|
798
|
+
var ActionInstanceStateEnum;
|
|
799
|
+
(function (ActionInstanceStateEnum) {
|
|
800
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["TriggerStart"] = 0] = "TriggerStart";
|
|
801
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["TriggerEnd"] = 1] = "TriggerEnd";
|
|
802
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["ActivationStart"] = 2] = "ActivationStart";
|
|
803
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["ActivationEnd"] = 3] = "ActivationEnd";
|
|
804
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["FetchStart"] = 4] = "FetchStart";
|
|
805
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["FetchEnd"] = 5] = "FetchEnd";
|
|
806
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["FetchError"] = 6] = "FetchError";
|
|
807
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["RunConfirmationStart"] = 7] = "RunConfirmationStart";
|
|
808
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["RunConfirmationEndAccept"] = 8] = "RunConfirmationEndAccept";
|
|
809
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["RunConfirmationEndReject"] = 9] = "RunConfirmationEndReject";
|
|
810
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["RunStart"] = 10] = "RunStart";
|
|
811
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["RunEnd"] = 11] = "RunEnd";
|
|
812
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["RunError"] = 12] = "RunError";
|
|
813
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["NextActionStart"] = 13] = "NextActionStart";
|
|
814
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["NextActionEnd"] = 14] = "NextActionEnd";
|
|
815
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["FinishSuccess"] = 15] = "FinishSuccess";
|
|
816
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["FinishError"] = 16] = "FinishError";
|
|
817
|
+
ActionInstanceStateEnum[ActionInstanceStateEnum["FinishDismissed"] = 17] = "FinishDismissed"; // action was dismissed by user
|
|
818
|
+
})(ActionInstanceStateEnum || (ActionInstanceStateEnum = {}));
|
|
819
|
+
|
|
820
|
+
/**
|
|
821
|
+
* Default categories for tableview actions
|
|
822
|
+
*/
|
|
823
|
+
class TableviewActionDefaultCategories {
|
|
824
|
+
}
|
|
825
|
+
TableviewActionDefaultCategories.READ = 'read';
|
|
826
|
+
TableviewActionDefaultCategories.ADD = 'add';
|
|
827
|
+
TableviewActionDefaultCategories.EDIT = 'edit';
|
|
828
|
+
TableviewActionDefaultCategories.DELETE = 'delete';
|
|
829
|
+
TableviewActionDefaultCategories.DETAILS = 'details';
|
|
830
|
+
|
|
580
831
|
class DataProvider {
|
|
581
832
|
constructor(modelType, serviceType) {
|
|
582
833
|
this._modelType = modelType;
|
|
@@ -696,137 +947,35 @@ class DynamicTableviewDataProvider extends TableviewDataProvider {
|
|
|
696
947
|
}
|
|
697
948
|
withFetch(fetch) {
|
|
698
949
|
this._fetch = fetch;
|
|
699
|
-
return this;
|
|
700
|
-
}
|
|
701
|
-
get getAll() {
|
|
702
|
-
return this._getAll;
|
|
703
|
-
}
|
|
704
|
-
get fetch() {
|
|
705
|
-
return this._fetch;
|
|
706
|
-
}
|
|
707
|
-
}
|
|
708
|
-
|
|
709
|
-
class TableviewCrudDataProvider extends TableviewDataProvider {
|
|
710
|
-
constructor(modelType, serviceType, idPropertyName, useGetAllForFetch = false) {
|
|
711
|
-
super(modelType, serviceType);
|
|
712
|
-
this.withGetAll((queryParam, service) => service.getAllPost(queryParam));
|
|
713
|
-
if (useGetAllForFetch) {
|
|
714
|
-
const selectedIdPropertyName = idPropertyName ?? ModelUtil.findIdAttribute(modelType) ?? 'id';
|
|
715
|
-
this.withFetch((id, service) => {
|
|
716
|
-
const qp = MediusQueryParamBuilder.create(10, 0).withFilter(selectedIdPropertyName, id, id, MediusFilterMatchType.Equals, true).build();
|
|
717
|
-
return service.getAllPost(qp).pipe(map(res => res.pageData[0]));
|
|
718
|
-
});
|
|
719
|
-
}
|
|
720
|
-
else {
|
|
721
|
-
this.withFetch((id, service) => service.getByIdGet(id));
|
|
722
|
-
}
|
|
723
|
-
this.withCreate((item, service) => service.createPost(item));
|
|
724
|
-
this.withUpdate((id, item, service) => service.updatePut(id, item));
|
|
725
|
-
this.withDelete((id, item, service) => service.removeDelete(id, item));
|
|
726
|
-
}
|
|
727
|
-
}
|
|
728
|
-
|
|
729
|
-
var AuthorizationTypeEnum;
|
|
730
|
-
(function (AuthorizationTypeEnum) {
|
|
731
|
-
AuthorizationTypeEnum["All"] = "ALL";
|
|
732
|
-
AuthorizationTypeEnum["Any"] = "ANY";
|
|
733
|
-
AuthorizationTypeEnum["Rbac"] = "ROLE_BASED_ACCESS_CONTROL";
|
|
734
|
-
AuthorizationTypeEnum["Service"] = "SERVICE";
|
|
735
|
-
})(AuthorizationTypeEnum || (AuthorizationTypeEnum = {}));
|
|
736
|
-
|
|
737
|
-
class APermissions {
|
|
738
|
-
constructor(type) {
|
|
739
|
-
this._authorizationType = type;
|
|
740
|
-
}
|
|
741
|
-
get authorizationType() {
|
|
742
|
-
return this._authorizationType;
|
|
743
|
-
}
|
|
744
|
-
}
|
|
745
|
-
var Permissions;
|
|
746
|
-
(function (Permissions) {
|
|
747
|
-
class All extends APermissions {
|
|
748
|
-
constructor() {
|
|
749
|
-
super(AuthorizationTypeEnum.All);
|
|
750
|
-
this._permissions = [];
|
|
751
|
-
}
|
|
752
|
-
static of(...permissions) {
|
|
753
|
-
const inst = new All();
|
|
754
|
-
inst.and(...permissions);
|
|
755
|
-
return inst;
|
|
756
|
-
}
|
|
757
|
-
get permissions() {
|
|
758
|
-
return this._permissions;
|
|
759
|
-
}
|
|
760
|
-
and(...permissions) {
|
|
761
|
-
this._permissions.push(...permissions);
|
|
762
|
-
return this;
|
|
763
|
-
}
|
|
950
|
+
return this;
|
|
764
951
|
}
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
constructor() {
|
|
768
|
-
super(AuthorizationTypeEnum.Any);
|
|
769
|
-
this._permissions = [];
|
|
770
|
-
}
|
|
771
|
-
static of(...permissions) {
|
|
772
|
-
const inst = new Any();
|
|
773
|
-
inst.or(...permissions);
|
|
774
|
-
return inst;
|
|
775
|
-
}
|
|
776
|
-
get permissions() {
|
|
777
|
-
return this._permissions;
|
|
778
|
-
}
|
|
779
|
-
or(...permissions) {
|
|
780
|
-
this._permissions.push(...permissions);
|
|
781
|
-
return this;
|
|
782
|
-
}
|
|
952
|
+
get getAll() {
|
|
953
|
+
return this._getAll;
|
|
783
954
|
}
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
constructor() {
|
|
787
|
-
super(AuthorizationTypeEnum.Rbac);
|
|
788
|
-
this._roles = [];
|
|
789
|
-
}
|
|
790
|
-
static of(...roles) {
|
|
791
|
-
const inst = new Roles();
|
|
792
|
-
inst.or(...roles);
|
|
793
|
-
return inst;
|
|
794
|
-
}
|
|
795
|
-
get roles() {
|
|
796
|
-
return this._roles;
|
|
797
|
-
}
|
|
798
|
-
and(...roles) {
|
|
799
|
-
if (this._roles.length === 0) {
|
|
800
|
-
this._roles.push([]);
|
|
801
|
-
}
|
|
802
|
-
this._roles[this._roles.length - 1].push(...roles);
|
|
803
|
-
return this;
|
|
804
|
-
}
|
|
805
|
-
or(...roles) {
|
|
806
|
-
this._roles.push(...roles.map(s => [s]));
|
|
807
|
-
return this;
|
|
808
|
-
}
|
|
955
|
+
get fetch() {
|
|
956
|
+
return this._fetch;
|
|
809
957
|
}
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
958
|
+
}
|
|
959
|
+
|
|
960
|
+
class TableviewCrudDataProvider extends TableviewDataProvider {
|
|
961
|
+
constructor(modelType, serviceType, idPropertyName, useGetAllForFetch = false) {
|
|
962
|
+
super(modelType, serviceType);
|
|
963
|
+
this.withGetAll((queryParam, service) => service.getAllPost(queryParam));
|
|
964
|
+
if (useGetAllForFetch) {
|
|
965
|
+
const selectedIdPropertyName = idPropertyName ?? ModelUtil.findIdAttribute(modelType) ?? 'id';
|
|
966
|
+
this.withFetch((id, service) => {
|
|
967
|
+
const qp = MediusQueryParamBuilder.create(10, 0).withFilter(selectedIdPropertyName, id, id, MediusFilterMatchType.Equals, true).build();
|
|
968
|
+
return service.getAllPost(qp).pipe(map(res => res.pageData[0]));
|
|
969
|
+
});
|
|
815
970
|
}
|
|
816
|
-
|
|
817
|
-
|
|
971
|
+
else {
|
|
972
|
+
this.withFetch((id, service) => service.getByIdGet(id));
|
|
818
973
|
}
|
|
974
|
+
this.withCreate((item, service) => service.createPost(item));
|
|
975
|
+
this.withUpdate((id, item, service) => service.updatePut(id, item));
|
|
976
|
+
this.withDelete((id, item, service) => service.removeDelete(id, item));
|
|
819
977
|
}
|
|
820
|
-
|
|
821
|
-
class ActionTypes {
|
|
822
|
-
}
|
|
823
|
-
ActionTypes.READ = 'read';
|
|
824
|
-
ActionTypes.ADD = 'add';
|
|
825
|
-
ActionTypes.EDIT = 'edit';
|
|
826
|
-
ActionTypes.DELETE = 'delete';
|
|
827
|
-
ActionTypes.DETAILS = 'details';
|
|
828
|
-
Permissions.ActionTypes = ActionTypes;
|
|
829
|
-
})(Permissions || (Permissions = {}));
|
|
978
|
+
}
|
|
830
979
|
|
|
831
980
|
var ActionPositionEnum;
|
|
832
981
|
(function (ActionPositionEnum) {
|
|
@@ -865,13 +1014,13 @@ var ColumnTypeEnum;
|
|
|
865
1014
|
ColumnTypeEnum[ColumnTypeEnum["Custom"] = 6] = "Custom";
|
|
866
1015
|
})(ColumnTypeEnum || (ColumnTypeEnum = {}));
|
|
867
1016
|
|
|
868
|
-
var
|
|
869
|
-
(function (
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
})(
|
|
1017
|
+
var TableviewEditorTypeEnum;
|
|
1018
|
+
(function (TableviewEditorTypeEnum) {
|
|
1019
|
+
TableviewEditorTypeEnum[TableviewEditorTypeEnum["None"] = 0] = "None";
|
|
1020
|
+
TableviewEditorTypeEnum[TableviewEditorTypeEnum["Details"] = 1] = "Details";
|
|
1021
|
+
TableviewEditorTypeEnum[TableviewEditorTypeEnum["Edit"] = 2] = "Edit";
|
|
1022
|
+
TableviewEditorTypeEnum[TableviewEditorTypeEnum["Add"] = 3] = "Add";
|
|
1023
|
+
})(TableviewEditorTypeEnum || (TableviewEditorTypeEnum = {}));
|
|
875
1024
|
|
|
876
1025
|
var FieldSizeEnum;
|
|
877
1026
|
(function (FieldSizeEnum) {
|
|
@@ -1462,8 +1611,8 @@ class ActionDescriptor {
|
|
|
1462
1611
|
get permissions() {
|
|
1463
1612
|
return this._permissions;
|
|
1464
1613
|
}
|
|
1465
|
-
get
|
|
1466
|
-
return this.
|
|
1614
|
+
get tableviewCategory() {
|
|
1615
|
+
return this._tableviewCategory;
|
|
1467
1616
|
}
|
|
1468
1617
|
get hasItemsSelection() {
|
|
1469
1618
|
return this._hasItemsSelection;
|
|
@@ -1471,6 +1620,9 @@ class ActionDescriptor {
|
|
|
1471
1620
|
get button() {
|
|
1472
1621
|
return this._button;
|
|
1473
1622
|
}
|
|
1623
|
+
get positionTableviewCategories() {
|
|
1624
|
+
return this._positionTableviewCategories;
|
|
1625
|
+
}
|
|
1474
1626
|
withDataProvider(dataProvider) {
|
|
1475
1627
|
this._dataProvider = dataProvider;
|
|
1476
1628
|
return this;
|
|
@@ -1541,14 +1693,14 @@ class ActionDescriptor {
|
|
|
1541
1693
|
return this;
|
|
1542
1694
|
}
|
|
1543
1695
|
withPermissions(permissions) {
|
|
1544
|
-
if (this.
|
|
1545
|
-
console.warn(`Permissions set on action ${this._actionNameLong} with route type '${this.
|
|
1696
|
+
if (this._tableviewCategory) {
|
|
1697
|
+
console.warn(`Permissions set on action ${this._actionNameLong} with route type '${this._tableviewCategory}' will be omitted in route guard validation.`);
|
|
1546
1698
|
}
|
|
1547
1699
|
this._permissions = permissions;
|
|
1548
1700
|
return this;
|
|
1549
1701
|
}
|
|
1550
|
-
|
|
1551
|
-
this.
|
|
1702
|
+
withTableviewCategory(permissionsRouteType) {
|
|
1703
|
+
this._tableviewCategory = permissionsRouteType;
|
|
1552
1704
|
return this;
|
|
1553
1705
|
}
|
|
1554
1706
|
withButtonDescriptor(button) {
|
|
@@ -1564,6 +1716,10 @@ class ActionDescriptor {
|
|
|
1564
1716
|
this._isEnabledFunction = this._isEnabledFunction ?? (ctx => of((ctx.parameters.selectedItems?.length ?? 0) > 0));
|
|
1565
1717
|
return this;
|
|
1566
1718
|
}
|
|
1719
|
+
withPositionTableviewCategories(positionTableviewCategories) {
|
|
1720
|
+
this._positionTableviewCategories = positionTableviewCategories;
|
|
1721
|
+
return this;
|
|
1722
|
+
}
|
|
1567
1723
|
}
|
|
1568
1724
|
class ActionSimpleDescriptor extends ActionDescriptor {
|
|
1569
1725
|
constructor(actionName, modelType, idProperty, titleProperty) {
|
|
@@ -1715,7 +1871,7 @@ class ActionEditorDetailsDescriptor extends ActionEditorDescriptor {
|
|
|
1715
1871
|
this.withRouteTrigger(':itemId');
|
|
1716
1872
|
this.withFetchFunction(ActionDataProviderUtil.runFetchOrFail);
|
|
1717
1873
|
this.withEditorActions([new ActionEditorSubmitDescriptor(this, ActionEditorSubmitTypeEnum.Cancel)]);
|
|
1718
|
-
this.
|
|
1874
|
+
this.withTableviewCategory(TableviewActionDefaultCategories.DETAILS);
|
|
1719
1875
|
}
|
|
1720
1876
|
withServiceType(serviceType) {
|
|
1721
1877
|
return this.withServiceFetchFunction(serviceType);
|
|
@@ -1736,9 +1892,8 @@ class ActionEditorAddDescriptor extends ActionEditorDescriptor {
|
|
|
1736
1892
|
this.withPosition(ActionPositionEnum.ToolbarLeft);
|
|
1737
1893
|
this.withRouteTrigger('add');
|
|
1738
1894
|
this.withSubmitFunction(ActionDataProviderUtil.runCreateOrFail);
|
|
1739
|
-
this.button.styleClass.withActionLevel(StyleLevelEnum.Success);
|
|
1740
1895
|
this.button.withIcon('pi pi-plus');
|
|
1741
|
-
this.
|
|
1896
|
+
this.withTableviewCategory(TableviewActionDefaultCategories.ADD);
|
|
1742
1897
|
}
|
|
1743
1898
|
withServiceType(serviceType) {
|
|
1744
1899
|
return this.withServiceSubmitFunction(serviceType);
|
|
@@ -1763,7 +1918,7 @@ class ActionEditorEditDescriptor extends ActionEditorDescriptor {
|
|
|
1763
1918
|
this.withRouteTrigger(':itemId/edit');
|
|
1764
1919
|
this.withFetchFunction(ActionDataProviderUtil.runFetchOrFail);
|
|
1765
1920
|
this.withSubmitFunction(ActionDataProviderUtil.runUpdateOrFail);
|
|
1766
|
-
this.
|
|
1921
|
+
this.withTableviewCategory(TableviewActionDefaultCategories.EDIT);
|
|
1767
1922
|
this.button.withLabel(null).withIcon('pi pi-pencil');
|
|
1768
1923
|
}
|
|
1769
1924
|
withServiceType(serviceType) {
|
|
@@ -1789,7 +1944,7 @@ class ActionDeleteDescriptor extends ActionDescriptor {
|
|
|
1789
1944
|
this.withRunFunction(ActionDataProviderUtil.runDeleteOrFail);
|
|
1790
1945
|
this.button.styleClass.withActionLevel(StyleLevelEnum.Danger);
|
|
1791
1946
|
this.withRunConfirmation();
|
|
1792
|
-
this.
|
|
1947
|
+
this.withTableviewCategory(TableviewActionDefaultCategories.DELETE);
|
|
1793
1948
|
this.button.withLabel(null).withIcon('pi pi-trash');
|
|
1794
1949
|
}
|
|
1795
1950
|
withServiceType(serviceType) {
|
|
@@ -2690,7 +2845,7 @@ class ColumnDynamicDescriptor extends ColumnDescriptor {
|
|
|
2690
2845
|
}
|
|
2691
2846
|
|
|
2692
2847
|
class EditorDescriptor {
|
|
2693
|
-
constructor(modelType, idProperty, titleProperty, tableviewEditorType =
|
|
2848
|
+
constructor(modelType, idProperty, titleProperty, tableviewEditorType = TableviewEditorTypeEnum.None) {
|
|
2694
2849
|
this._tabs = [];
|
|
2695
2850
|
this._groups = [];
|
|
2696
2851
|
this._fields = [];
|
|
@@ -2707,7 +2862,7 @@ class EditorDescriptor {
|
|
|
2707
2862
|
* @param titleProperty
|
|
2708
2863
|
* @param tableEditorType
|
|
2709
2864
|
*/
|
|
2710
|
-
static from(modelType, idProperty, titleProperty, tableEditorType =
|
|
2865
|
+
static from(modelType, idProperty, titleProperty, tableEditorType = TableviewEditorTypeEnum.None) {
|
|
2711
2866
|
return EditorDescriptor.fromModelWithAttributes(modelType, TableviewUtil.getAttributeDefMap(modelType), titleProperty, idProperty, tableEditorType);
|
|
2712
2867
|
}
|
|
2713
2868
|
/**
|
|
@@ -2719,7 +2874,7 @@ class EditorDescriptor {
|
|
|
2719
2874
|
* @param titleProperty
|
|
2720
2875
|
* @param tableEditorType
|
|
2721
2876
|
*/
|
|
2722
|
-
static fromModelWithAttributes(modelType, attributes, idProperty, titleProperty, tableEditorType =
|
|
2877
|
+
static fromModelWithAttributes(modelType, attributes, idProperty, titleProperty, tableEditorType = TableviewEditorTypeEnum.None) {
|
|
2723
2878
|
const descriptor = new EditorDescriptor(modelType, idProperty, titleProperty, tableEditorType);
|
|
2724
2879
|
attributes
|
|
2725
2880
|
.filter(attr => !attr.type.includes('Set') && !attr.type.includes('Array'))
|
|
@@ -2735,9 +2890,6 @@ class EditorDescriptor {
|
|
|
2735
2890
|
get fields() {
|
|
2736
2891
|
return this._fields;
|
|
2737
2892
|
}
|
|
2738
|
-
get tableviewEditorType() {
|
|
2739
|
-
return this._disabled;
|
|
2740
|
-
}
|
|
2741
2893
|
get disabled() {
|
|
2742
2894
|
return this._disabled;
|
|
2743
2895
|
}
|
|
@@ -3708,7 +3860,7 @@ class FieldManyEditorDescriptor extends AFieldDescriptor {
|
|
|
3708
3860
|
return this._tableviewDescriptor.addEditor;
|
|
3709
3861
|
}
|
|
3710
3862
|
get editorForRead() {
|
|
3711
|
-
return this._tableviewDescriptor.
|
|
3863
|
+
return this._tableviewDescriptor.detailsEditor;
|
|
3712
3864
|
}
|
|
3713
3865
|
get editorForUpdate() {
|
|
3714
3866
|
return this._tableviewDescriptor.editEditor;
|
|
@@ -4340,10 +4492,10 @@ class TableviewDescriptor {
|
|
|
4340
4492
|
this._modelType = modelType;
|
|
4341
4493
|
this._model = new ModelDescriptor(modelType, idProperty, titleProperty);
|
|
4342
4494
|
this._table = new TableDescriptor(modelType, idProperty, titleProperty);
|
|
4343
|
-
this.
|
|
4344
|
-
this.
|
|
4345
|
-
this._addEditor = new EditorDescriptor(modelType, idProperty, titleProperty,
|
|
4346
|
-
this._editEditor = new EditorDescriptor(modelType, idProperty, titleProperty,
|
|
4495
|
+
this._detailsEditor = new EditorDescriptor(modelType, idProperty, titleProperty, TableviewEditorTypeEnum.Details);
|
|
4496
|
+
this._detailsEditor.withDisabled();
|
|
4497
|
+
this._addEditor = new EditorDescriptor(modelType, idProperty, titleProperty, TableviewEditorTypeEnum.Add);
|
|
4498
|
+
this._editEditor = new EditorDescriptor(modelType, idProperty, titleProperty, TableviewEditorTypeEnum.Edit);
|
|
4347
4499
|
this._tableTitle = `${this._model.typeName}.name`;
|
|
4348
4500
|
}
|
|
4349
4501
|
/**
|
|
@@ -4356,7 +4508,7 @@ class TableviewDescriptor {
|
|
|
4356
4508
|
const descriptor = new TableviewDescriptor(modelType, idProperty, titleProperty);
|
|
4357
4509
|
descriptor._table = TableDescriptor.from(modelType, idProperty, titleProperty);
|
|
4358
4510
|
descriptor._editEditor = EditorDescriptor.from(modelType, idProperty, titleProperty);
|
|
4359
|
-
descriptor.
|
|
4511
|
+
descriptor._detailsEditor = EditorDescriptor.from(modelType, idProperty, titleProperty);
|
|
4360
4512
|
descriptor._addEditor = EditorDescriptor.from(modelType, idProperty, titleProperty);
|
|
4361
4513
|
return descriptor;
|
|
4362
4514
|
}
|
|
@@ -4373,7 +4525,7 @@ class TableviewDescriptor {
|
|
|
4373
4525
|
descriptor._table = TableDescriptor.fromModelWithAttributes(modelType, columnAttributes, idProperty, titleProperty);
|
|
4374
4526
|
if (fieldAttributes !== null) {
|
|
4375
4527
|
descriptor._editEditor = EditorDescriptor.fromModelWithAttributes(modelType, fieldAttributes ?? columnAttributes, idProperty, titleProperty);
|
|
4376
|
-
descriptor.
|
|
4528
|
+
descriptor._detailsEditor = EditorDescriptor.fromModelWithAttributes(modelType, fieldAttributes ?? columnAttributes, idProperty, titleProperty);
|
|
4377
4529
|
descriptor._addEditor = EditorDescriptor.fromModelWithAttributes(modelType, fieldAttributes ?? columnAttributes, idProperty, titleProperty);
|
|
4378
4530
|
}
|
|
4379
4531
|
return descriptor;
|
|
@@ -4381,8 +4533,8 @@ class TableviewDescriptor {
|
|
|
4381
4533
|
get table() {
|
|
4382
4534
|
return this._table;
|
|
4383
4535
|
}
|
|
4384
|
-
get
|
|
4385
|
-
return this.
|
|
4536
|
+
get detailsEditor() {
|
|
4537
|
+
return this._detailsEditor;
|
|
4386
4538
|
}
|
|
4387
4539
|
get addEditor() {
|
|
4388
4540
|
return this._addEditor;
|
|
@@ -4401,13 +4553,13 @@ class TableviewDescriptor {
|
|
|
4401
4553
|
return this;
|
|
4402
4554
|
}
|
|
4403
4555
|
withEditorDescriptors(descriptor) {
|
|
4404
|
-
this.
|
|
4556
|
+
this._detailsEditor = descriptor;
|
|
4405
4557
|
this._editEditor = descriptor;
|
|
4406
4558
|
this._addEditor = descriptor;
|
|
4407
4559
|
return this;
|
|
4408
4560
|
}
|
|
4409
|
-
|
|
4410
|
-
this.
|
|
4561
|
+
withDetailsDescriptor(descriptor) {
|
|
4562
|
+
this._detailsEditor = descriptor;
|
|
4411
4563
|
return this;
|
|
4412
4564
|
}
|
|
4413
4565
|
withAddDescriptor(descriptor) {
|
|
@@ -4423,7 +4575,7 @@ class TableviewDescriptor {
|
|
|
4423
4575
|
return this;
|
|
4424
4576
|
}
|
|
4425
4577
|
withValidator(name, expression) {
|
|
4426
|
-
this.
|
|
4578
|
+
this._detailsEditor.addValidation(name, expression);
|
|
4427
4579
|
this._addEditor.addValidation(name, expression);
|
|
4428
4580
|
this._editEditor.addValidation(name, expression);
|
|
4429
4581
|
return this;
|
|
@@ -4439,20 +4591,20 @@ class TableviewDescriptor {
|
|
|
4439
4591
|
}
|
|
4440
4592
|
getField(property, editorType) {
|
|
4441
4593
|
switch (editorType) {
|
|
4442
|
-
case
|
|
4594
|
+
case TableviewEditorTypeEnum.Edit:
|
|
4443
4595
|
return this._editEditor.getField(property);
|
|
4444
|
-
case
|
|
4596
|
+
case TableviewEditorTypeEnum.Add:
|
|
4445
4597
|
return this._addEditor.getField(property);
|
|
4446
|
-
case
|
|
4447
|
-
return this.
|
|
4448
|
-
case
|
|
4598
|
+
case TableviewEditorTypeEnum.Details:
|
|
4599
|
+
return this._detailsEditor.getField(property);
|
|
4600
|
+
case TableviewEditorTypeEnum.None:
|
|
4449
4601
|
return null;
|
|
4450
4602
|
}
|
|
4451
4603
|
}
|
|
4452
4604
|
removeField(property) {
|
|
4453
4605
|
this._editEditor.removeField(property);
|
|
4454
4606
|
this._addEditor.removeField(property);
|
|
4455
|
-
this.
|
|
4607
|
+
this._detailsEditor.removeField(property);
|
|
4456
4608
|
}
|
|
4457
4609
|
addColumnNumber(property, displayFormat) {
|
|
4458
4610
|
return this._table.addColumnNumber(property, displayFormat);
|
|
@@ -4470,49 +4622,49 @@ class TableviewDescriptor {
|
|
|
4470
4622
|
return this._table.addColumnCustomComponent(property, customComponentType);
|
|
4471
4623
|
}
|
|
4472
4624
|
createTabGroup(name, title) {
|
|
4473
|
-
this.
|
|
4625
|
+
this._detailsEditor.createTabGroup(name, title);
|
|
4474
4626
|
this._addEditor.createTabGroup(name, title);
|
|
4475
4627
|
this._editEditor.createTabGroup(name, title);
|
|
4476
4628
|
return this;
|
|
4477
4629
|
}
|
|
4478
4630
|
createFieldGroup(name, title) {
|
|
4479
|
-
this.
|
|
4631
|
+
this._detailsEditor.createFieldGroup(name, title);
|
|
4480
4632
|
this._addEditor.createFieldGroup(name, title);
|
|
4481
4633
|
this._editEditor.createFieldGroup(name, title);
|
|
4482
4634
|
return this;
|
|
4483
4635
|
}
|
|
4484
4636
|
addFieldDescriptor(field) {
|
|
4485
|
-
this.
|
|
4637
|
+
this._detailsEditor.addFieldDescriptor(field);
|
|
4486
4638
|
this._addEditor.addFieldDescriptor(field);
|
|
4487
4639
|
this._editEditor.addFieldDescriptor(field);
|
|
4488
4640
|
return this;
|
|
4489
4641
|
}
|
|
4490
4642
|
addField(property) {
|
|
4491
|
-
const field = this.
|
|
4643
|
+
const field = this._detailsEditor.addField(property);
|
|
4492
4644
|
this._addEditor.addFieldDescriptor(field);
|
|
4493
4645
|
this._editEditor.addFieldDescriptor(field);
|
|
4494
4646
|
return field;
|
|
4495
4647
|
}
|
|
4496
4648
|
addFieldLookup(property, modelType) {
|
|
4497
|
-
const field = this.
|
|
4649
|
+
const field = this._detailsEditor.addFieldLookup(property, modelType);
|
|
4498
4650
|
this._addEditor.addFieldDescriptor(field);
|
|
4499
4651
|
this._editEditor.addFieldDescriptor(field);
|
|
4500
4652
|
return field;
|
|
4501
4653
|
}
|
|
4502
4654
|
addFieldLookupEnum(property, enumType, options, nameAsValue = false, optionsTitlePath) {
|
|
4503
|
-
const field = this.
|
|
4655
|
+
const field = this._detailsEditor.addFieldLookupEnum(property, enumType, options, nameAsValue, optionsTitlePath);
|
|
4504
4656
|
this._addEditor.addFieldDescriptor(field);
|
|
4505
4657
|
this._editEditor.addFieldDescriptor(field);
|
|
4506
4658
|
return field;
|
|
4507
4659
|
}
|
|
4508
4660
|
addFieldManyEditor(property, tableviewDescriptor) {
|
|
4509
|
-
const field = this.
|
|
4661
|
+
const field = this._detailsEditor.addFieldManyEditor(property, tableviewDescriptor);
|
|
4510
4662
|
this._addEditor.addFieldDescriptor(field);
|
|
4511
4663
|
this._editEditor.addFieldDescriptor(field);
|
|
4512
4664
|
return field;
|
|
4513
4665
|
}
|
|
4514
4666
|
addFieldManyToManyEditor(property, mainTableDescriptor, lookupTableDescriptor) {
|
|
4515
|
-
const field = this.
|
|
4667
|
+
const field = this._detailsEditor.addFieldManyToManyEditor(property, mainTableDescriptor, lookupTableDescriptor);
|
|
4516
4668
|
this._addEditor.addFieldDescriptor(field);
|
|
4517
4669
|
this._editEditor.addFieldDescriptor(field);
|
|
4518
4670
|
return field;
|
|
@@ -4520,7 +4672,7 @@ class TableviewDescriptor {
|
|
|
4520
4672
|
copy() {
|
|
4521
4673
|
const tableview = new TableviewDescriptor(this._model.type, this._model.idPropertyName, this._model.titlePropertyName);
|
|
4522
4674
|
tableview._table = this._table.copy();
|
|
4523
|
-
tableview.
|
|
4675
|
+
tableview._detailsEditor = this._detailsEditor.copy();
|
|
4524
4676
|
tableview._addEditor = this._addEditor.copy();
|
|
4525
4677
|
tableview._editEditor = this._editEditor.copy();
|
|
4526
4678
|
return tableview;
|
|
@@ -4546,7 +4698,7 @@ class TableviewDescriptor {
|
|
|
4546
4698
|
this._table.withColumnModifiedType(property, columnType);
|
|
4547
4699
|
this._editEditor.withFieldModifiedType(property, fieldType);
|
|
4548
4700
|
this._addEditor.withFieldModifiedType(property, fieldType);
|
|
4549
|
-
this.
|
|
4701
|
+
this._detailsEditor.withFieldModifiedType(property, fieldType);
|
|
4550
4702
|
}
|
|
4551
4703
|
return this;
|
|
4552
4704
|
}
|
|
@@ -4563,7 +4715,7 @@ class TableviewDescriptor {
|
|
|
4563
4715
|
attributeDef.fieldType = fieldType ?? FieldInputTypeEnum.Text;
|
|
4564
4716
|
this._table.withColumnModifiedEnum(property, enumType);
|
|
4565
4717
|
this._editEditor.withFieldModifiedEnum(property, enumType);
|
|
4566
|
-
this.
|
|
4718
|
+
this._detailsEditor.withFieldModifiedEnum(property, enumType);
|
|
4567
4719
|
this._addEditor.withFieldModifiedEnum(property, enumType);
|
|
4568
4720
|
}
|
|
4569
4721
|
return this;
|
|
@@ -4589,7 +4741,7 @@ class TableviewDescriptor {
|
|
|
4589
4741
|
if (lookupProvider != null) {
|
|
4590
4742
|
this._table.withColumnModifiedLookup(property, lookupProvider, itemsLabelProperty, filterProperty);
|
|
4591
4743
|
this._addEditor.withFieldModifiedLookup(property, modelType, lookupProvider, itemsLabelProperty);
|
|
4592
|
-
this.
|
|
4744
|
+
this._detailsEditor.withFieldModifiedLookup(property, modelType, lookupProvider, itemsLabelProperty);
|
|
4593
4745
|
this._editEditor.withFieldModifiedLookup(property, modelType, lookupProvider, itemsLabelProperty);
|
|
4594
4746
|
}
|
|
4595
4747
|
else {
|
|
@@ -5864,256 +6016,99 @@ MediusRestUtil.matchModeMapping = [
|
|
|
5864
6016
|
[FilterMatchMode.DATE_IS_NOT, 'neq', MediusFilterMatchType.NotEquals, FilterTypeEnum.Date]
|
|
5865
6017
|
];
|
|
5866
6018
|
|
|
5867
|
-
|
|
5868
|
-
|
|
5869
|
-
|
|
5870
|
-
|
|
5871
|
-
|
|
5872
|
-
|
|
5873
|
-
|
|
5874
|
-
|
|
5875
|
-
|
|
5876
|
-
|
|
5877
|
-
|
|
5878
|
-
class ActionInstance {
|
|
5879
|
-
constructor(action, state = ActionInstanceStateEnum.TriggerStart, debug = false) {
|
|
5880
|
-
this.debug = debug;
|
|
5881
|
-
// function execution
|
|
5882
|
-
this.isRunLoadingSubject = new BehaviorSubject(false);
|
|
5883
|
-
this.contexts = [];
|
|
5884
|
-
this.executionSubject = new Subject();
|
|
5885
|
-
this.executionIsRunningSubject = new BehaviorSubject(false);
|
|
5886
|
-
this.stateSubject = new BehaviorSubject(1);
|
|
5887
|
-
this.resultSubject = new ReplaySubject(1);
|
|
5888
|
-
this.errorSubject = new ReplaySubject(1);
|
|
5889
|
-
this.contextExecutionSubscriptions = [];
|
|
5890
|
-
this.instanceId = Math.random().toString(36).substring(2);
|
|
5891
|
-
this.instanceLongName = `${action.actionNameLong}_${this.instanceId}`;
|
|
5892
|
-
this.action = action;
|
|
5893
|
-
this.state = state;
|
|
5894
|
-
}
|
|
5895
|
-
get isRunLoading$() {
|
|
5896
|
-
return this.isRunLoadingSubject.asObservable();
|
|
5897
|
-
}
|
|
5898
|
-
get context() {
|
|
5899
|
-
return this.contexts.length === 0 ? undefined : this.contexts[this.contexts.length - 1];
|
|
5900
|
-
}
|
|
5901
|
-
get execution$() {
|
|
5902
|
-
return this.executionSubject.asObservable();
|
|
5903
|
-
}
|
|
5904
|
-
get executionIsRunning$() {
|
|
5905
|
-
return this.executionIsRunningSubject.asObservable().pipe(distinctUntilChanged());
|
|
5906
|
-
}
|
|
5907
|
-
get state() {
|
|
5908
|
-
return this.stateSubject.value;
|
|
5909
|
-
}
|
|
5910
|
-
set state(state) {
|
|
5911
|
-
if (state > this.stateSubject.value) {
|
|
5912
|
-
if (this.debug) {
|
|
5913
|
-
console.debug(`ActionInstance ${this.instanceLongName} - state #${state}: ${ActionInstanceStateEnum[state]}`);
|
|
5914
|
-
}
|
|
5915
|
-
this.stateSubject.next(state);
|
|
5916
|
-
}
|
|
5917
|
-
}
|
|
5918
|
-
get state$() {
|
|
5919
|
-
return this.stateSubject.asObservable().pipe(distinctUntilChanged());
|
|
6019
|
+
var AuthorizationTypeEnum;
|
|
6020
|
+
(function (AuthorizationTypeEnum) {
|
|
6021
|
+
AuthorizationTypeEnum["All"] = "ALL";
|
|
6022
|
+
AuthorizationTypeEnum["Any"] = "ANY";
|
|
6023
|
+
AuthorizationTypeEnum["Rbac"] = "ROLE_BASED_ACCESS_CONTROL";
|
|
6024
|
+
AuthorizationTypeEnum["Service"] = "SERVICE";
|
|
6025
|
+
})(AuthorizationTypeEnum || (AuthorizationTypeEnum = {}));
|
|
6026
|
+
|
|
6027
|
+
class APermissions {
|
|
6028
|
+
constructor(type) {
|
|
6029
|
+
this._authorizationType = type;
|
|
5920
6030
|
}
|
|
5921
|
-
get
|
|
5922
|
-
return this.
|
|
6031
|
+
get authorizationType() {
|
|
6032
|
+
return this._authorizationType;
|
|
5923
6033
|
}
|
|
5924
|
-
|
|
5925
|
-
|
|
5926
|
-
|
|
6034
|
+
}
|
|
6035
|
+
var Permissions;
|
|
6036
|
+
(function (Permissions) {
|
|
6037
|
+
class All extends APermissions {
|
|
6038
|
+
constructor() {
|
|
6039
|
+
super(AuthorizationTypeEnum.All);
|
|
6040
|
+
this._permissions = [];
|
|
5927
6041
|
}
|
|
5928
|
-
|
|
5929
|
-
|
|
6042
|
+
static of(...permissions) {
|
|
6043
|
+
const inst = new All();
|
|
6044
|
+
inst.and(...permissions);
|
|
6045
|
+
return inst;
|
|
5930
6046
|
}
|
|
5931
|
-
|
|
5932
|
-
|
|
5933
|
-
}
|
|
5934
|
-
get result$() {
|
|
5935
|
-
return this.resultSubject.asObservable();
|
|
5936
|
-
}
|
|
5937
|
-
get error() {
|
|
5938
|
-
return this._error;
|
|
5939
|
-
}
|
|
5940
|
-
set error(error) {
|
|
5941
|
-
if (typeof error === 'undefined') {
|
|
5942
|
-
return;
|
|
6047
|
+
get permissions() {
|
|
6048
|
+
return this._permissions;
|
|
5943
6049
|
}
|
|
5944
|
-
|
|
5945
|
-
|
|
6050
|
+
and(...permissions) {
|
|
6051
|
+
this._permissions.push(...permissions);
|
|
6052
|
+
return this;
|
|
5946
6053
|
}
|
|
5947
|
-
this._error = error;
|
|
5948
|
-
this.errorSubject.next(error);
|
|
5949
|
-
}
|
|
5950
|
-
get error$() {
|
|
5951
|
-
return this.errorSubject.asObservable();
|
|
5952
6054
|
}
|
|
5953
|
-
|
|
5954
|
-
|
|
5955
|
-
|
|
5956
|
-
|
|
5957
|
-
|
|
5958
|
-
if (this.debug) {
|
|
5959
|
-
console.debug(`ActionInstance ${this.instanceLongName} - new context ${context.contextLongName}`);
|
|
6055
|
+
Permissions.All = All;
|
|
6056
|
+
class Any extends APermissions {
|
|
6057
|
+
constructor() {
|
|
6058
|
+
super(AuthorizationTypeEnum.Any);
|
|
6059
|
+
this._permissions = [];
|
|
5960
6060
|
}
|
|
5961
|
-
|
|
5962
|
-
|
|
5963
|
-
|
|
6061
|
+
static of(...permissions) {
|
|
6062
|
+
const inst = new Any();
|
|
6063
|
+
inst.or(...permissions);
|
|
6064
|
+
return inst;
|
|
5964
6065
|
}
|
|
5965
|
-
|
|
5966
|
-
|
|
5967
|
-
this.contextExecutionSubscriptions.push(context.execution$.subscribe({
|
|
5968
|
-
next: next => this.executionSubject.next(next),
|
|
5969
|
-
error: error => this.executionSubject.error(error)
|
|
5970
|
-
}));
|
|
5971
|
-
this.contextExecutionSubscriptions.push(context.executionIsRunning$.subscribe({
|
|
5972
|
-
next: next => this.executionIsRunningSubject.next(next)
|
|
5973
|
-
}));
|
|
5974
|
-
this.contexts.push(context);
|
|
5975
|
-
}
|
|
5976
|
-
finish() {
|
|
5977
|
-
if (this.stateSubject.value < ActionInstanceStateEnum.FinishSuccess) {
|
|
5978
|
-
this.state = ActionInstanceStateEnum.FinishSuccess;
|
|
6066
|
+
get permissions() {
|
|
6067
|
+
return this._permissions;
|
|
5979
6068
|
}
|
|
5980
|
-
|
|
5981
|
-
|
|
5982
|
-
|
|
5983
|
-
this.executionIsRunningSubject.complete();
|
|
5984
|
-
this.stateSubject.complete();
|
|
5985
|
-
this.resultSubject.complete();
|
|
5986
|
-
this.errorSubject.complete();
|
|
5987
|
-
}
|
|
5988
|
-
}
|
|
5989
|
-
/**
|
|
5990
|
-
* Class containing all main data for action to be executed in run/fetch/submit states.
|
|
5991
|
-
*/
|
|
5992
|
-
class ActionContext {
|
|
5993
|
-
constructor(instance, parameters, functionName, dataProvider, serviceInstance, executionSubject = new ReplaySubject(1), executionIsRunningSubject = new BehaviorSubject(false)) {
|
|
5994
|
-
this.instance = instance;
|
|
5995
|
-
this.parameters = parameters;
|
|
5996
|
-
this.functionName = functionName;
|
|
5997
|
-
this.dataProvider = dataProvider;
|
|
5998
|
-
this.serviceInstance = serviceInstance;
|
|
5999
|
-
this.executionSubject = executionSubject;
|
|
6000
|
-
this.executionIsRunningSubject = executionIsRunningSubject;
|
|
6001
|
-
this.contextLongName = `${this.instance.instanceLongName}_${functionName}`;
|
|
6002
|
-
}
|
|
6003
|
-
get execution$() {
|
|
6004
|
-
return this.executionSubject.asObservable();
|
|
6005
|
-
}
|
|
6006
|
-
get executionIsRunning$() {
|
|
6007
|
-
return this.executionIsRunningSubject.asObservable().pipe(distinctUntilChanged());
|
|
6008
|
-
}
|
|
6009
|
-
executionStart() {
|
|
6010
|
-
if (this.instance.debug) {
|
|
6011
|
-
console.debug(`ActionContext ${this.contextLongName} - execution start`);
|
|
6069
|
+
or(...permissions) {
|
|
6070
|
+
this._permissions.push(...permissions);
|
|
6071
|
+
return this;
|
|
6012
6072
|
}
|
|
6013
|
-
this.executionIsRunningSubject.next(true);
|
|
6014
6073
|
}
|
|
6015
|
-
|
|
6016
|
-
|
|
6017
|
-
|
|
6074
|
+
Permissions.Any = Any;
|
|
6075
|
+
class Roles extends APermissions {
|
|
6076
|
+
constructor() {
|
|
6077
|
+
super(AuthorizationTypeEnum.Rbac);
|
|
6078
|
+
this._roles = [];
|
|
6018
6079
|
}
|
|
6019
|
-
|
|
6020
|
-
|
|
6021
|
-
|
|
6080
|
+
static of(...roles) {
|
|
6081
|
+
const inst = new Roles();
|
|
6082
|
+
inst.or(...roles);
|
|
6083
|
+
return inst;
|
|
6022
6084
|
}
|
|
6023
|
-
|
|
6024
|
-
|
|
6025
|
-
if (this.instance.debug) {
|
|
6026
|
-
console.debug(`ActionContext ${this.contextLongName} - execution complete`);
|
|
6085
|
+
get roles() {
|
|
6086
|
+
return this._roles;
|
|
6027
6087
|
}
|
|
6028
|
-
|
|
6029
|
-
|
|
6030
|
-
|
|
6031
|
-
|
|
6032
|
-
|
|
6033
|
-
|
|
6088
|
+
and(...roles) {
|
|
6089
|
+
if (this._roles.length === 0) {
|
|
6090
|
+
this._roles.push([]);
|
|
6091
|
+
}
|
|
6092
|
+
this._roles[this._roles.length - 1].push(...roles);
|
|
6093
|
+
return this;
|
|
6094
|
+
}
|
|
6095
|
+
or(...roles) {
|
|
6096
|
+
this._roles.push(...roles.map(s => [s]));
|
|
6097
|
+
return this;
|
|
6034
6098
|
}
|
|
6035
|
-
this.executionSubject.error(err);
|
|
6036
|
-
this.executionIsRunningSubject.next(false);
|
|
6037
|
-
}
|
|
6038
|
-
finish() {
|
|
6039
|
-
this.executionSubject.complete();
|
|
6040
|
-
this.executionIsRunningSubject.complete();
|
|
6041
|
-
}
|
|
6042
|
-
}
|
|
6043
|
-
/**
|
|
6044
|
-
* Class containing all main data for action validations (enabled/visible) to be executed in validation states.
|
|
6045
|
-
*/
|
|
6046
|
-
class ActionContextValidation {
|
|
6047
|
-
constructor(descriptor, parameters, dataProvider, serviceInstance) {
|
|
6048
|
-
this.descriptor = descriptor;
|
|
6049
|
-
this.parameters = parameters;
|
|
6050
|
-
this.dataProvider = dataProvider;
|
|
6051
|
-
this.serviceInstance = serviceInstance;
|
|
6052
|
-
}
|
|
6053
|
-
}
|
|
6054
|
-
class ActionParameters {
|
|
6055
|
-
constructor(itemId, item) {
|
|
6056
|
-
this.itemId = itemId;
|
|
6057
|
-
this.item = item;
|
|
6058
|
-
this.selectedItems = [];
|
|
6059
|
-
}
|
|
6060
|
-
withActionData(actionData) {
|
|
6061
|
-
this.actionData = actionData;
|
|
6062
|
-
return this;
|
|
6063
|
-
}
|
|
6064
|
-
withQueryParam(queryParam) {
|
|
6065
|
-
this.queryParam = queryParam;
|
|
6066
|
-
return this;
|
|
6067
|
-
}
|
|
6068
|
-
withViewContainer(viewContainer) {
|
|
6069
|
-
this.viewContainer = viewContainer;
|
|
6070
|
-
return this;
|
|
6071
|
-
}
|
|
6072
|
-
withSourceComponent(sourceComponent) {
|
|
6073
|
-
this.sourceComponent = sourceComponent;
|
|
6074
|
-
return this;
|
|
6075
|
-
}
|
|
6076
|
-
withRoute(route) {
|
|
6077
|
-
this.route = route;
|
|
6078
|
-
return this;
|
|
6079
6099
|
}
|
|
6080
|
-
|
|
6081
|
-
|
|
6082
|
-
|
|
6100
|
+
Permissions.Roles = Roles;
|
|
6101
|
+
class Service extends APermissions {
|
|
6102
|
+
constructor(service) {
|
|
6103
|
+
super(AuthorizationTypeEnum.Service);
|
|
6104
|
+
this.service = service;
|
|
6105
|
+
}
|
|
6106
|
+
static of(service) {
|
|
6107
|
+
return new Service(service);
|
|
6108
|
+
}
|
|
6083
6109
|
}
|
|
6084
|
-
|
|
6085
|
-
|
|
6086
|
-
(function (ActionInstanceStateEnum) {
|
|
6087
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["TriggerStart"] = 0] = "TriggerStart";
|
|
6088
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["TriggerEnd"] = 1] = "TriggerEnd";
|
|
6089
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["ActivationStart"] = 2] = "ActivationStart";
|
|
6090
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["ActivationEnd"] = 3] = "ActivationEnd";
|
|
6091
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["FetchStart"] = 4] = "FetchStart";
|
|
6092
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["FetchEnd"] = 5] = "FetchEnd";
|
|
6093
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["FetchError"] = 6] = "FetchError";
|
|
6094
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["RunConfirmationStart"] = 7] = "RunConfirmationStart";
|
|
6095
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["RunConfirmationEndAccept"] = 8] = "RunConfirmationEndAccept";
|
|
6096
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["RunConfirmationEndReject"] = 9] = "RunConfirmationEndReject";
|
|
6097
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["RunStart"] = 10] = "RunStart";
|
|
6098
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["RunEnd"] = 11] = "RunEnd";
|
|
6099
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["RunError"] = 12] = "RunError";
|
|
6100
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["NextActionStart"] = 13] = "NextActionStart";
|
|
6101
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["NextActionEnd"] = 14] = "NextActionEnd";
|
|
6102
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["FinishSuccess"] = 15] = "FinishSuccess";
|
|
6103
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["FinishError"] = 16] = "FinishError";
|
|
6104
|
-
ActionInstanceStateEnum[ActionInstanceStateEnum["FinishDismissed"] = 17] = "FinishDismissed"; // action was dismissed by user
|
|
6105
|
-
})(ActionInstanceStateEnum || (ActionInstanceStateEnum = {}));
|
|
6106
|
-
|
|
6107
|
-
/**
|
|
6108
|
-
* Default categories for tableview actions
|
|
6109
|
-
*/
|
|
6110
|
-
class TableviewActionDefaultCategories {
|
|
6111
|
-
}
|
|
6112
|
-
TableviewActionDefaultCategories.READ = 'read';
|
|
6113
|
-
TableviewActionDefaultCategories.ADD = 'add';
|
|
6114
|
-
TableviewActionDefaultCategories.EDIT = 'edit';
|
|
6115
|
-
TableviewActionDefaultCategories.DELETE = 'delete';
|
|
6116
|
-
TableviewActionDefaultCategories.DETAILS = 'details';
|
|
6110
|
+
Permissions.Service = Service;
|
|
6111
|
+
})(Permissions || (Permissions = {}));
|
|
6117
6112
|
|
|
6118
6113
|
class AuthorizationUtil {
|
|
6119
6114
|
static isPermitted(permissions, userRoles) {
|
|
@@ -6934,37 +6929,33 @@ class MngActionExecutorService {
|
|
|
6934
6929
|
instance.state = ActionInstanceStateEnum.ActivationStart;
|
|
6935
6930
|
if (action.type === ActionTypeEnum.Editor) {
|
|
6936
6931
|
let dialogComponent = this.defaultEditorDialogComponent;
|
|
6937
|
-
|
|
6932
|
+
const dialogClassNames = ['mng-dialog'];
|
|
6938
6933
|
if (action instanceof ActionEditorDescriptor) {
|
|
6939
|
-
|
|
6940
|
-
let dialogSizeClassName = '';
|
|
6934
|
+
dialogClassNames.push(action.dialogClassName ?? 'mng-action-editor-dialog');
|
|
6941
6935
|
switch (action.dialogSize) {
|
|
6942
6936
|
case StyleSizeEnum.ExtraSmall:
|
|
6943
|
-
|
|
6937
|
+
dialogClassNames.push('mng-dialog-xs');
|
|
6944
6938
|
break;
|
|
6945
6939
|
case StyleSizeEnum.Small:
|
|
6946
|
-
|
|
6940
|
+
dialogClassNames.push('mng-dialog-sm');
|
|
6947
6941
|
break;
|
|
6948
6942
|
case StyleSizeEnum.Large:
|
|
6949
|
-
|
|
6943
|
+
dialogClassNames.push('mng-dialog-lg');
|
|
6950
6944
|
break;
|
|
6951
6945
|
case StyleSizeEnum.ExtraLarge:
|
|
6952
|
-
|
|
6946
|
+
dialogClassNames.push('mng-dialog-xl');
|
|
6953
6947
|
break;
|
|
6954
6948
|
case StyleSizeEnum.Normal:
|
|
6955
6949
|
default:
|
|
6956
6950
|
break;
|
|
6957
6951
|
}
|
|
6958
|
-
if (dialogSizeClassName.length) {
|
|
6959
|
-
dialogClassName += ` ${dialogSizeClassName}`;
|
|
6960
|
-
}
|
|
6961
6952
|
if (action.editorComponent) {
|
|
6962
6953
|
dialogComponent = action.editorComponent;
|
|
6963
6954
|
}
|
|
6964
6955
|
}
|
|
6965
6956
|
const dialogConfig = {
|
|
6966
6957
|
data: {},
|
|
6967
|
-
styleClass:
|
|
6958
|
+
styleClass: dialogClassNames.join(' ')
|
|
6968
6959
|
};
|
|
6969
6960
|
dialogConfig.data.actionInstance = instance;
|
|
6970
6961
|
dialogConfig.data.previousActionInstance = previousActionInstance;
|
|
@@ -7181,10 +7172,23 @@ class MngCommonsService {
|
|
|
7181
7172
|
return this.moduleConfig?.app?.languages ?? ['en'];
|
|
7182
7173
|
}
|
|
7183
7174
|
get appLanguage() {
|
|
7184
|
-
const
|
|
7185
|
-
if (
|
|
7186
|
-
return
|
|
7175
|
+
const lsLang = this.localStorage.getItem('lang');
|
|
7176
|
+
if (lsLang && this.appLanguages.some(l => l === lsLang)) {
|
|
7177
|
+
return lsLang;
|
|
7178
|
+
}
|
|
7179
|
+
return null;
|
|
7180
|
+
}
|
|
7181
|
+
set appLanguage(language) {
|
|
7182
|
+
if (language === null) {
|
|
7183
|
+
this.localStorage.removeItem('lang');
|
|
7184
|
+
return;
|
|
7185
|
+
}
|
|
7186
|
+
if (this.appLanguages.some(l => l === language)) {
|
|
7187
|
+
this.localStorage.setItem('lang', language);
|
|
7188
|
+
this.translate.use(language);
|
|
7187
7189
|
}
|
|
7190
|
+
}
|
|
7191
|
+
initLanguage() {
|
|
7188
7192
|
const browserLang = this.translate.getBrowserLang();
|
|
7189
7193
|
if (browserLang && this.appLanguages.some(l => l === browserLang)) {
|
|
7190
7194
|
this.appLanguage = browserLang;
|
|
@@ -7194,11 +7198,8 @@ class MngCommonsService {
|
|
|
7194
7198
|
this.appLanguage = defaultLanguage;
|
|
7195
7199
|
return defaultLanguage;
|
|
7196
7200
|
}
|
|
7197
|
-
|
|
7198
|
-
|
|
7199
|
-
this.localStorage.setItem('lang', language);
|
|
7200
|
-
this.translate.use(language);
|
|
7201
|
-
}
|
|
7201
|
+
getOrInitLanguage() {
|
|
7202
|
+
return this.appLanguage || this.initLanguage();
|
|
7202
7203
|
}
|
|
7203
7204
|
get appVersion() {
|
|
7204
7205
|
return this.moduleConfig?.app?.version;
|
|
@@ -7294,7 +7295,8 @@ class MngCommonsService {
|
|
|
7294
7295
|
};
|
|
7295
7296
|
// translate
|
|
7296
7297
|
this.translate.langs = this.appLanguages;
|
|
7297
|
-
this.
|
|
7298
|
+
const lang = this.getOrInitLanguage();
|
|
7299
|
+
this.translate.use(lang);
|
|
7298
7300
|
this.translate.get('mngPrime').subscribe(value => this.primengConfig.setTranslation(value));
|
|
7299
7301
|
this.routerEventsSubscription?.unsubscribe();
|
|
7300
7302
|
this.routerEventsSubscription = this.router.events
|
|
@@ -7468,23 +7470,36 @@ class MngViewContainerComponentService {
|
|
|
7468
7470
|
constructor(messageService) {
|
|
7469
7471
|
this.messageService = messageService;
|
|
7470
7472
|
this.actions = [];
|
|
7471
|
-
this.
|
|
7473
|
+
this._tableReloadSubject = new Subject();
|
|
7474
|
+
this._editorResetSubject = new Subject();
|
|
7472
7475
|
}
|
|
7473
7476
|
set dataProvider(dataProvider) {
|
|
7474
7477
|
this._dataProvider = dataProvider;
|
|
7475
7478
|
}
|
|
7476
|
-
get reloadTable() {
|
|
7477
|
-
return this._reloadTableSubject.asObservable();
|
|
7478
|
-
}
|
|
7479
|
-
triggerTableReload(event) {
|
|
7480
|
-
this._reloadTableSubject.next(event);
|
|
7481
|
-
}
|
|
7482
7479
|
getMessageService() {
|
|
7483
7480
|
return this.messageService;
|
|
7484
7481
|
}
|
|
7485
7482
|
getDataProvider() {
|
|
7486
7483
|
return this._dataProvider;
|
|
7487
7484
|
}
|
|
7485
|
+
getActions() {
|
|
7486
|
+
return this.actions;
|
|
7487
|
+
}
|
|
7488
|
+
setActions(actions) {
|
|
7489
|
+
this.actions = actions;
|
|
7490
|
+
}
|
|
7491
|
+
getTableReload$() {
|
|
7492
|
+
return this._tableReloadSubject.asObservable();
|
|
7493
|
+
}
|
|
7494
|
+
reloadTable(event) {
|
|
7495
|
+
this._tableReloadSubject.next(event ?? {});
|
|
7496
|
+
}
|
|
7497
|
+
getEditorReset$() {
|
|
7498
|
+
return this._editorResetSubject.asObservable();
|
|
7499
|
+
}
|
|
7500
|
+
resetEditor(event) {
|
|
7501
|
+
this._editorResetSubject.next(event ?? {});
|
|
7502
|
+
}
|
|
7488
7503
|
}
|
|
7489
7504
|
MngViewContainerComponentService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngViewContainerComponentService, deps: [{ token: i2.MessageService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
7490
7505
|
MngViewContainerComponentService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngViewContainerComponentService });
|
|
@@ -7596,9 +7611,9 @@ class MngActionComponent {
|
|
|
7596
7611
|
if (this.action instanceof ActionLinkDescriptor) {
|
|
7597
7612
|
this.actionLink = this.action;
|
|
7598
7613
|
}
|
|
7599
|
-
if (this.action.
|
|
7600
|
-
if (routeData.tableviewPermissions[this.action.
|
|
7601
|
-
this.routePermissions = routeData.tableviewPermissions[this.action.
|
|
7614
|
+
if (this.action.tableviewCategory && routeData.tableviewPermissions) {
|
|
7615
|
+
if (routeData.tableviewPermissions[this.action.tableviewCategory]) {
|
|
7616
|
+
this.routePermissions = routeData.tableviewPermissions[this.action.tableviewCategory];
|
|
7602
7617
|
}
|
|
7603
7618
|
}
|
|
7604
7619
|
this.processSubscriptions();
|
|
@@ -7643,7 +7658,7 @@ class MngActionComponent {
|
|
|
7643
7658
|
next: () => {
|
|
7644
7659
|
this.finishEventEmitter.next(instance);
|
|
7645
7660
|
if (this.action.hasItemsSelection) {
|
|
7646
|
-
this.
|
|
7661
|
+
this.viewContainer?.reloadTable?.({ data: { event: event } });
|
|
7647
7662
|
}
|
|
7648
7663
|
}
|
|
7649
7664
|
}));
|
|
@@ -7707,10 +7722,10 @@ class MngActionComponent {
|
|
|
7707
7722
|
}
|
|
7708
7723
|
}
|
|
7709
7724
|
MngActionComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngActionComponent, deps: [{ token: i1.ActivatedRoute }, { token: i1$2.TranslateService }, { token: MngAuthorizationService }, { token: MngActionExecutorService }, { token: i2.ConfirmationService }, { token: MngViewContainerComponentService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
7710
|
-
MngActionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngActionComponent, selector: "mng-action", inputs: { action: "action", item: "item", itemId: "itemId", actionData: "actionData", queryParam: "queryParam", dataProvider: "dataProvider", inputDisabled: ["disabled", "inputDisabled"], inputLoading: ["loading", "inputLoading"], viewContainerInit: ["viewContainer", "viewContainerInit"], selectedItems: "selectedItems" }, outputs: { finishEventEmitter: "finish" }, host: { properties: { "class": "this.hostClass", "class.m-0": "this.isHostHidden" } }, providers: [ConfirmationService], usesOnChanges: true, ngImport: i0, template: "<ng-container *ngIf=\"($isVisible | async) && ($isPermitted | async)\">\n <a\n *ngIf=\"actionLink && actionLink.url !== ''; else routerLink\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [href]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false) ? null : (actionLink.url | parametrize: itemId:item:actionData)\"\n [target]=\"actionLink.target\"\n [class.disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n [class]=\"buttonClass\"\n >{{ ($label | async) ?? '' }}</a\n >\n <ng-template #routerLink>\n <a\n *ngIf=\"actionLink; else button\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [target]=\"actionLink.target\"\n [replaceUrl]=\"actionLink.replaceUrl\"\n [routerLink]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false) ? null : (actionLink.pathSegments | parametrize: itemId:item:actionData)\"\n [queryParams]=\"actionLink.queryParams | parametrize: itemId:item:actionData\"\n [queryParamsHandling]=\"actionLink.queryParamsHandling\"\n [class.disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n [class]=\"buttonClass\"\n >{{ ($label | async) ?? '' }}</a\n >\n </ng-template>\n <ng-template #button>\n <button\n type=\"button\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [label]=\"($label | async) ?? ''\"\n [pTooltip]=\"$any($tooltip | async)\"\n [loading]=\"(($loading | async) ?? false) || ((inputLoading | async) ?? false)\"\n [disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n (click)=\"triggerAction($event)\"\n [class]=\"buttonClass\"></button>\n </ng-template>\n <p-confirmDialog\n *ngIf=\"action.runConfirmationDialogDescriptor\"\n [key]=\"action.actionName + '_' + cmpId\"\n [baseZIndex]=\"50\"\n appendTo=\"body\"\n [closable]=\"action.runConfirmationDialogDescriptor.closable\"></p-confirmDialog>\n</ng-container>\n", styles: [":host{display:inline-block}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i7.Tooltip, selector: "[pTooltip]", inputs: ["tooltipPosition", "tooltipEvent", "appendTo", "positionStyle", "tooltipStyleClass", "tooltipZIndex", "escape", "showDelay", "hideDelay", "life", "positionTop", "positionLeft", "fitContent", "pTooltip", "tooltipDisabled", "tooltipOptions"] }, { kind: "directive", type: i4$1.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { kind: "component", type: i9.ConfirmDialog, selector: "p-confirmDialog", inputs: ["header", "icon", "message", "style", "styleClass", "maskStyleClass", "acceptIcon", "acceptLabel", "acceptAriaLabel", "acceptVisible", "rejectIcon", "rejectLabel", "rejectAriaLabel", "rejectVisible", "acceptButtonStyleClass", "rejectButtonStyleClass", "closeOnEscape", "dismissableMask", "blockScroll", "rtl", "closable", "appendTo", "key", "autoZIndex", "baseZIndex", "transitionOptions", "focusTrap", "defaultFocus", "breakpoints", "visible", "position"], outputs: ["onHide"] }, { kind: "directive", type:
|
|
7725
|
+
MngActionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngActionComponent, selector: "mng-action", inputs: { action: "action", item: "item", itemId: "itemId", actionData: "actionData", queryParam: "queryParam", dataProvider: "dataProvider", inputDisabled: ["disabled", "inputDisabled"], inputLoading: ["loading", "inputLoading"], viewContainerInit: ["viewContainer", "viewContainerInit"], selectedItems: "selectedItems" }, outputs: { finishEventEmitter: "finish" }, host: { properties: { "class": "this.hostClass", "class.m-0": "this.isHostHidden" } }, providers: [ConfirmationService], usesOnChanges: true, ngImport: i0, template: "<ng-container *ngIf=\"($isVisible | async) && ($isPermitted | async)\">\n <a\n *ngIf=\"actionLink && actionLink.url !== ''; else routerLink\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [href]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false) ? null : (actionLink.url | parametrize: itemId:item:actionData)\"\n [target]=\"actionLink.target\"\n [class.disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n [pTooltip]=\"$any($tooltip | async)\"\n [class]=\"buttonClass\"\n >{{ ($label | async) ?? '' }}</a\n >\n <ng-template #routerLink>\n <a\n *ngIf=\"actionLink; else button\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [target]=\"actionLink.target\"\n [replaceUrl]=\"actionLink.replaceUrl\"\n [routerLink]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false) ? null : (actionLink.pathSegments | parametrize: itemId:item:actionData)\"\n [queryParams]=\"actionLink.queryParams | parametrize: itemId:item:actionData\"\n [queryParamsHandling]=\"actionLink.queryParamsHandling\"\n [class.disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n [pTooltip]=\"$any($tooltip | async)\"\n [class]=\"buttonClass\"\n >{{ ($label | async) ?? '' }}</a\n >\n </ng-template>\n <ng-template #button>\n <button\n type=\"button\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [label]=\"($label | async) ?? ''\"\n [pTooltip]=\"$any($tooltip | async)\"\n [loading]=\"(($loading | async) ?? false) || ((inputLoading | async) ?? false)\"\n [disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n (click)=\"triggerAction($event)\"\n [class]=\"buttonClass\"></button>\n </ng-template>\n <p-confirmDialog\n *ngIf=\"action.runConfirmationDialogDescriptor\"\n [key]=\"action.actionName + '_' + cmpId\"\n [baseZIndex]=\"50\"\n appendTo=\"body\"\n [closable]=\"action.runConfirmationDialogDescriptor.closable\"></p-confirmDialog>\n</ng-container>\n", styles: [":host{display:inline-block}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i7.Tooltip, selector: "[pTooltip]", inputs: ["tooltipPosition", "tooltipEvent", "appendTo", "positionStyle", "tooltipStyleClass", "tooltipZIndex", "escape", "showDelay", "hideDelay", "life", "positionTop", "positionLeft", "fitContent", "pTooltip", "tooltipDisabled", "tooltipOptions"] }, { kind: "directive", type: i4$1.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { kind: "component", type: i9.ConfirmDialog, selector: "p-confirmDialog", inputs: ["header", "icon", "message", "style", "styleClass", "maskStyleClass", "acceptIcon", "acceptLabel", "acceptAriaLabel", "acceptVisible", "rejectIcon", "rejectLabel", "rejectAriaLabel", "rejectVisible", "acceptButtonStyleClass", "rejectButtonStyleClass", "closeOnEscape", "dismissableMask", "blockScroll", "rtl", "closable", "appendTo", "key", "autoZIndex", "baseZIndex", "transitionOptions", "focusTrap", "defaultFocus", "breakpoints", "visible", "position"], outputs: ["onHide"] }, { kind: "directive", type: i5.Ripple, selector: "[pRipple]" }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: MngParametrizePipe, name: "parametrize" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
7711
7726
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngActionComponent, decorators: [{
|
|
7712
7727
|
type: Component,
|
|
7713
|
-
args: [{ selector: 'mng-action', changeDetection: ChangeDetectionStrategy.OnPush, providers: [ConfirmationService], template: "<ng-container *ngIf=\"($isVisible | async) && ($isPermitted | async)\">\n <a\n *ngIf=\"actionLink && actionLink.url !== ''; else routerLink\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [href]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false) ? null : (actionLink.url | parametrize: itemId:item:actionData)\"\n [target]=\"actionLink.target\"\n [class.disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n [class]=\"buttonClass\"\n >{{ ($label | async) ?? '' }}</a\n >\n <ng-template #routerLink>\n <a\n *ngIf=\"actionLink; else button\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [target]=\"actionLink.target\"\n [replaceUrl]=\"actionLink.replaceUrl\"\n [routerLink]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false) ? null : (actionLink.pathSegments | parametrize: itemId:item:actionData)\"\n [queryParams]=\"actionLink.queryParams | parametrize: itemId:item:actionData\"\n [queryParamsHandling]=\"actionLink.queryParamsHandling\"\n [class.disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n [class]=\"buttonClass\"\n >{{ ($label | async) ?? '' }}</a\n >\n </ng-template>\n <ng-template #button>\n <button\n type=\"button\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [label]=\"($label | async) ?? ''\"\n [pTooltip]=\"$any($tooltip | async)\"\n [loading]=\"(($loading | async) ?? false) || ((inputLoading | async) ?? false)\"\n [disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n (click)=\"triggerAction($event)\"\n [class]=\"buttonClass\"></button>\n </ng-template>\n <p-confirmDialog\n *ngIf=\"action.runConfirmationDialogDescriptor\"\n [key]=\"action.actionName + '_' + cmpId\"\n [baseZIndex]=\"50\"\n appendTo=\"body\"\n [closable]=\"action.runConfirmationDialogDescriptor.closable\"></p-confirmDialog>\n</ng-container>\n", styles: [":host{display:inline-block}\n"] }]
|
|
7728
|
+
args: [{ selector: 'mng-action', changeDetection: ChangeDetectionStrategy.OnPush, providers: [ConfirmationService], template: "<ng-container *ngIf=\"($isVisible | async) && ($isPermitted | async)\">\n <a\n *ngIf=\"actionLink && actionLink.url !== ''; else routerLink\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [href]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false) ? null : (actionLink.url | parametrize: itemId:item:actionData)\"\n [target]=\"actionLink.target\"\n [class.disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n [pTooltip]=\"$any($tooltip | async)\"\n [class]=\"buttonClass\"\n >{{ ($label | async) ?? '' }}</a\n >\n <ng-template #routerLink>\n <a\n *ngIf=\"actionLink; else button\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [target]=\"actionLink.target\"\n [replaceUrl]=\"actionLink.replaceUrl\"\n [routerLink]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false) ? null : (actionLink.pathSegments | parametrize: itemId:item:actionData)\"\n [queryParams]=\"actionLink.queryParams | parametrize: itemId:item:actionData\"\n [queryParamsHandling]=\"actionLink.queryParamsHandling\"\n [class.disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n [pTooltip]=\"$any($tooltip | async)\"\n [class]=\"buttonClass\"\n >{{ ($label | async) ?? '' }}</a\n >\n </ng-template>\n <ng-template #button>\n <button\n type=\"button\"\n pButton\n pRipple\n [icon]=\"$any(action.button.icon)\"\n [label]=\"($label | async) ?? ''\"\n [pTooltip]=\"$any($tooltip | async)\"\n [loading]=\"(($loading | async) ?? false) || ((inputLoading | async) ?? false)\"\n [disabled]=\"($isEnabled | async) === false || ((inputDisabled | async) ?? false)\"\n (click)=\"triggerAction($event)\"\n [class]=\"buttonClass\"></button>\n </ng-template>\n <p-confirmDialog\n *ngIf=\"action.runConfirmationDialogDescriptor\"\n [key]=\"action.actionName + '_' + cmpId\"\n [baseZIndex]=\"50\"\n appendTo=\"body\"\n [closable]=\"action.runConfirmationDialogDescriptor.closable\"></p-confirmDialog>\n</ng-container>\n", styles: [":host{display:inline-block}\n"] }]
|
|
7714
7729
|
}], ctorParameters: function () { return [{ type: i1.ActivatedRoute }, { type: i1$2.TranslateService }, { type: MngAuthorizationService }, { type: MngActionExecutorService }, { type: i2.ConfirmationService }, { type: MngViewContainerComponentService, decorators: [{
|
|
7715
7730
|
type: Optional
|
|
7716
7731
|
}] }]; }, propDecorators: { hostClass: [{
|
|
@@ -7760,7 +7775,7 @@ class MngActionRouteComponent {
|
|
|
7760
7775
|
this.subscriptions = [];
|
|
7761
7776
|
}
|
|
7762
7777
|
ngOnInit() {
|
|
7763
|
-
this.actions = this.viewContainerService?.
|
|
7778
|
+
this.actions = this.viewContainerService?.getActions().filter(a => a.activationTrigger === ActionActivationTriggerEnum.OnRoute) ?? [];
|
|
7764
7779
|
const subscription = this.route.params.subscribe(p => {
|
|
7765
7780
|
const action = this.findActiveAction(p);
|
|
7766
7781
|
if (action) {
|
|
@@ -7806,7 +7821,7 @@ class MngActionRouteComponent {
|
|
|
7806
7821
|
if (!this.viewContainerService) {
|
|
7807
7822
|
console.warn(`View container service could not be found, table reload will not be triggered.`);
|
|
7808
7823
|
}
|
|
7809
|
-
this.viewContainerService?.
|
|
7824
|
+
this.viewContainerService?.reloadTable({ data: { event: actionEv } }); // reload only if no error in action and
|
|
7810
7825
|
}
|
|
7811
7826
|
this.untriggerAction();
|
|
7812
7827
|
});
|
|
@@ -8006,6 +8021,34 @@ class MngFormEditorComponent {
|
|
|
8006
8021
|
});
|
|
8007
8022
|
return formValue;
|
|
8008
8023
|
}
|
|
8024
|
+
resetFormModel(item) {
|
|
8025
|
+
this.formOrigItem = item;
|
|
8026
|
+
// TODO: to check if this is ok, could be problems with dates, if so, try lodash
|
|
8027
|
+
const formModel = JSON.parse(JSON.stringify(item ?? {}));
|
|
8028
|
+
this.descriptor.fields.forEach(field => {
|
|
8029
|
+
if (field.getter && item) {
|
|
8030
|
+
const splitPath = field.property.split('.');
|
|
8031
|
+
let currentObject = formModel;
|
|
8032
|
+
for (let i = 0; i < splitPath.length; i++) {
|
|
8033
|
+
const currentSubPath = splitPath[i];
|
|
8034
|
+
if (i === splitPath.length - 1) {
|
|
8035
|
+
currentObject[currentSubPath] = field.getter(item);
|
|
8036
|
+
}
|
|
8037
|
+
else {
|
|
8038
|
+
if (typeof currentObject[currentSubPath] !== 'object') {
|
|
8039
|
+
currentObject[currentSubPath] = {};
|
|
8040
|
+
}
|
|
8041
|
+
currentObject = currentObject[currentSubPath];
|
|
8042
|
+
}
|
|
8043
|
+
}
|
|
8044
|
+
}
|
|
8045
|
+
});
|
|
8046
|
+
if (typeof this.formOptions.resetModel === 'function') {
|
|
8047
|
+
// could not be initiated yet
|
|
8048
|
+
this.formOptions.resetModel(this.formModel);
|
|
8049
|
+
}
|
|
8050
|
+
this.formModel = formModel;
|
|
8051
|
+
}
|
|
8009
8052
|
getFormField(key) {
|
|
8010
8053
|
return this.findFormField(this.form, key.split('.'));
|
|
8011
8054
|
}
|
|
@@ -8073,40 +8116,12 @@ class MngFormEditorComponent {
|
|
|
8073
8116
|
}
|
|
8074
8117
|
return false;
|
|
8075
8118
|
}
|
|
8076
|
-
resetFormModel(item) {
|
|
8077
|
-
this.formOrigItem = item;
|
|
8078
|
-
// TODO: to check if this is ok, could be problems with dates, if so, try lodash
|
|
8079
|
-
const formModel = JSON.parse(JSON.stringify(item ?? {}));
|
|
8080
|
-
this.descriptor.fields.forEach(field => {
|
|
8081
|
-
if (field.getter && item) {
|
|
8082
|
-
const splitPath = field.property.split('.');
|
|
8083
|
-
let currentObject = formModel;
|
|
8084
|
-
for (let i = 0; i < splitPath.length; i++) {
|
|
8085
|
-
const currentSubPath = splitPath[i];
|
|
8086
|
-
if (i === splitPath.length - 1) {
|
|
8087
|
-
currentObject[currentSubPath] = field.getter(item);
|
|
8088
|
-
}
|
|
8089
|
-
else {
|
|
8090
|
-
if (typeof currentObject[currentSubPath] !== 'object') {
|
|
8091
|
-
currentObject[currentSubPath] = {};
|
|
8092
|
-
}
|
|
8093
|
-
currentObject = currentObject[currentSubPath];
|
|
8094
|
-
}
|
|
8095
|
-
}
|
|
8096
|
-
}
|
|
8097
|
-
});
|
|
8098
|
-
if (typeof this.formOptions.resetModel === 'function') {
|
|
8099
|
-
// could not be initiated yet
|
|
8100
|
-
this.formOptions.resetModel(this.formModel);
|
|
8101
|
-
}
|
|
8102
|
-
this.formModel = formModel;
|
|
8103
|
-
}
|
|
8104
8119
|
updateFormState() {
|
|
8105
8120
|
this.formOptions.formState.disabled = this.isFormDisabled !== null ? this.isFormDisabled === true : this.descriptor.disabled;
|
|
8106
8121
|
}
|
|
8107
8122
|
}
|
|
8108
8123
|
MngFormEditorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormEditorComponent, deps: [{ token: i1$2.TranslateService }], target: i0.ɵɵFactoryTarget.Component });
|
|
8109
|
-
MngFormEditorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngFormEditorComponent, selector: "mng-form-editor", inputs: { descriptor: "descriptor", submitLoading: "submitLoading", item: "item", isSubmitButtonVisible: "isSubmitButtonVisible", isFormDisabled: "isFormDisabled" }, outputs: { formSubmitEventEmitter: "formSubmit" }, queries: [{ propertyName: "templates", predicate: MngTemplateDirective }], viewQueries: [{ propertyName: "submitButtonElementRef", first: true, predicate: ["submitButton"], descendants: true }], ngImport: i0, template: "<form [formGroup]=\"form\" (ngSubmit)=\"onSubmit($event)\">\n <formly-form [form]=\"form\" [fields]=\"formFields\" [options]=\"formOptions\" [model]=\"formModel\"></formly-form>\n <button #submitButton pButton type=\"submit\" [class.hidden]=\"!isSubmitButtonVisible\" [disabled]=\"form.disabled\" [loading]=\"(submitLoading$ | async) ?? false\"></button>\n</form>\n<p-messages [value]=\"formMessages\" [enableService]=\"false\"></p-messages>\n", dependencies: [{ kind: "directive", type: i2$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i2$2.FormlyForm, selector: "formly-form", inputs: ["form", "model", "fields", "options"], outputs: ["modelChange"] }, { kind: "directive", type: i4$1.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { kind: "component", type: i5.Messages, selector: "p-messages", inputs: ["value", "closable", "style", "styleClass", "enableService", "key", "escape", "severity", "showTransitionOptions", "hideTransitionOptions"], outputs: ["valueChange"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
8124
|
+
MngFormEditorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngFormEditorComponent, selector: "mng-form-editor", inputs: { descriptor: "descriptor", submitLoading: "submitLoading", item: "item", isSubmitButtonVisible: "isSubmitButtonVisible", isFormDisabled: "isFormDisabled" }, outputs: { formSubmitEventEmitter: "formSubmit" }, queries: [{ propertyName: "templates", predicate: MngTemplateDirective }], viewQueries: [{ propertyName: "submitButtonElementRef", first: true, predicate: ["submitButton"], descendants: true }], ngImport: i0, template: "<form [formGroup]=\"form\" (ngSubmit)=\"onSubmit($event)\">\n <formly-form [form]=\"form\" [fields]=\"formFields\" [options]=\"formOptions\" [model]=\"formModel\"></formly-form>\n <button #submitButton pButton type=\"submit\" [class.hidden]=\"!isSubmitButtonVisible\" [disabled]=\"form.disabled\" [loading]=\"(submitLoading$ | async) ?? false\"></button>\n</form>\n<p-messages [value]=\"formMessages\" [enableService]=\"false\"></p-messages>\n", dependencies: [{ kind: "directive", type: i2$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i2$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2$1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "component", type: i2$2.FormlyForm, selector: "formly-form", inputs: ["form", "model", "fields", "options"], outputs: ["modelChange"] }, { kind: "directive", type: i4$1.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { kind: "component", type: i5$1.Messages, selector: "p-messages", inputs: ["value", "closable", "style", "styleClass", "enableService", "key", "escape", "severity", "showTransitionOptions", "hideTransitionOptions"], outputs: ["valueChange"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
8110
8125
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormEditorComponent, decorators: [{
|
|
8111
8126
|
type: Component,
|
|
8112
8127
|
args: [{ selector: 'mng-form-editor', changeDetection: ChangeDetectionStrategy.OnPush, template: "<form [formGroup]=\"form\" (ngSubmit)=\"onSubmit($event)\">\n <formly-form [form]=\"form\" [fields]=\"formFields\" [options]=\"formOptions\" [model]=\"formModel\"></formly-form>\n <button #submitButton pButton type=\"submit\" [class.hidden]=\"!isSubmitButtonVisible\" [disabled]=\"form.disabled\" [loading]=\"(submitLoading$ | async) ?? false\"></button>\n</form>\n<p-messages [value]=\"formMessages\" [enableService]=\"false\"></p-messages>\n" }]
|
|
@@ -8576,7 +8591,7 @@ class MngDropdownComponent {
|
|
|
8576
8591
|
}
|
|
8577
8592
|
}
|
|
8578
8593
|
MngDropdownComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngDropdownComponent, deps: [{ token: i0.Injector }, { token: i1$2.TranslateService }, { token: MngFormlyFieldWrapperComponent, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
8579
|
-
MngDropdownComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngDropdownComponent, selector: "mng-dropdown", inputs: { dataProvider: "dataProvider", dataKeyProperty: "dataKeyProperty", itemsLabelPropertyInit: ["itemsLabelProperty", "itemsLabelPropertyInit"], itemsLabelTranslate: "itemsLabelTranslate", itemsValuePropertyInit: ["itemsValueProperty", "itemsValuePropertyInit"], itemsDisabledProperty: "itemsDisabledProperty", multiselect: "multiselect", placeholder: "placeholder", showClear: "showClear", selectFirstItem: "selectFirstItem", className: "className", dropdownClassName: "dropdownClassName", changeValueOnBlur: "changeValueOnBlur" }, outputs: { valueChangeEventEmitter: "valueChange" }, providers: [MNG_DROPDOWN_VALUE_ACCESSOR], viewQueries: [{ propertyName: "primeDropdown", first: true, predicate: Dropdown, descendants: true }], ngImport: i0, template: "<p-dropdown\n *ngIf=\"!multiselect; else pMultiselect\"\n [formControl]=\"dropdownFormControl\"\n [placeholder]=\"$any(placeholder)\"\n [dataKey]=\"$any(dataKeyProperty)\"\n [optionLabel]=\"$any(itemsLabelProperty)\"\n [optionValue]=\"$any(itemsValueProperty)\"\n [optionDisabled]=\"$any(itemsDisabledProperty)\"\n [options]=\"$any(items$ | async)\"\n [showClear]=\"showClear\"\n [autoDisplayFirst]=\"false\"\n [styleClass]=\"$any(className)\"\n [panelStyleClass]=\"$any(dropdownClassName)\"\n (onBlur)=\"onDropdownBlur($event)\"\n [dropdownIcon]=\"($loading | async) ?? false ? 'pi pi-spinner pi-spin' : 'pi pi-chevron-down'\"\n appendTo=\"body\">\n</p-dropdown>\n<ng-template #pMultiselect>\n <p-multiSelect\n [maxSelectedLabels]=\"1\"\n [selectedItemsLabel]=\"'mngDropdown.multiselectOverMaxDisplayLimit' | translate\"\n [formControl]=\"dropdownFormControl\"\n [defaultLabel]=\"$any(placeholder)\"\n [dataKey]=\"$any(dataKeyProperty)\"\n [optionLabel]=\"$any(itemsLabelProperty)\"\n [optionValue]=\"$any(itemsValueProperty)\"\n [optionDisabled]=\"$any(itemsDisabledProperty)\"\n [options]=\"(items$ | async) ?? []\"\n [styleClass]=\"$any(className)\"\n [panelStyleClass]=\"$any(dropdownClassName)\"\n [filter]=\"true\"\n [showToggleAll]=\"false\"\n (onPanelHide)=\"onPanelHide($event)\"\n appendTo=\"body\">\n </p-multiSelect>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i5$
|
|
8594
|
+
MngDropdownComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngDropdownComponent, selector: "mng-dropdown", inputs: { dataProvider: "dataProvider", dataKeyProperty: "dataKeyProperty", itemsLabelPropertyInit: ["itemsLabelProperty", "itemsLabelPropertyInit"], itemsLabelTranslate: "itemsLabelTranslate", itemsValuePropertyInit: ["itemsValueProperty", "itemsValuePropertyInit"], itemsDisabledProperty: "itemsDisabledProperty", multiselect: "multiselect", placeholder: "placeholder", showClear: "showClear", selectFirstItem: "selectFirstItem", className: "className", dropdownClassName: "dropdownClassName", changeValueOnBlur: "changeValueOnBlur" }, outputs: { valueChangeEventEmitter: "valueChange" }, providers: [MNG_DROPDOWN_VALUE_ACCESSOR], viewQueries: [{ propertyName: "primeDropdown", first: true, predicate: Dropdown, descendants: true }], ngImport: i0, template: "<p-dropdown\n *ngIf=\"!multiselect; else pMultiselect\"\n [formControl]=\"dropdownFormControl\"\n [placeholder]=\"$any(placeholder)\"\n [dataKey]=\"$any(dataKeyProperty)\"\n [optionLabel]=\"$any(itemsLabelProperty)\"\n [optionValue]=\"$any(itemsValueProperty)\"\n [optionDisabled]=\"$any(itemsDisabledProperty)\"\n [options]=\"$any(items$ | async)\"\n [showClear]=\"showClear\"\n [autoDisplayFirst]=\"false\"\n [styleClass]=\"$any(className)\"\n [panelStyleClass]=\"$any(dropdownClassName)\"\n (onBlur)=\"onDropdownBlur($event)\"\n [dropdownIcon]=\"($loading | async) ?? false ? 'pi pi-spinner pi-spin' : 'pi pi-chevron-down'\"\n appendTo=\"body\">\n</p-dropdown>\n<ng-template #pMultiselect>\n <p-multiSelect\n [maxSelectedLabels]=\"1\"\n [selectedItemsLabel]=\"'mngDropdown.multiselectOverMaxDisplayLimit' | translate\"\n [formControl]=\"dropdownFormControl\"\n [defaultLabel]=\"$any(placeholder)\"\n [dataKey]=\"$any(dataKeyProperty)\"\n [optionLabel]=\"$any(itemsLabelProperty)\"\n [optionValue]=\"$any(itemsValueProperty)\"\n [optionDisabled]=\"$any(itemsDisabledProperty)\"\n [options]=\"(items$ | async) ?? []\"\n [styleClass]=\"$any(className)\"\n [panelStyleClass]=\"$any(dropdownClassName)\"\n [filter]=\"true\"\n [showToggleAll]=\"false\"\n (onPanelHide)=\"onPanelHide($event)\"\n appendTo=\"body\">\n </p-multiSelect>\n</ng-template>\n", dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i5$2.Dropdown, selector: "p-dropdown", inputs: ["scrollHeight", "filter", "name", "style", "panelStyle", "styleClass", "panelStyleClass", "readonly", "required", "editable", "appendTo", "tabindex", "placeholder", "filterPlaceholder", "filterLocale", "inputId", "selectId", "dataKey", "filterBy", "autofocus", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "autoDisplayFirst", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "maxlength", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "disabled", "itemSize", "options", "filterValue"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "component", type: i6.MultiSelect, selector: "p-multiSelect", inputs: ["style", "styleClass", "panelStyle", "panelStyleClass", "inputId", "disabled", "readonly", "group", "filter", "filterPlaceHolder", "filterLocale", "overlayVisible", "tabindex", "appendTo", "dataKey", "name", "label", "ariaLabelledBy", "displaySelectedLabel", "maxSelectedLabels", "selectionLimit", "selectedItemsLabel", "showToggleAll", "emptyFilterMessage", "emptyMessage", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "showHeader", "autoZIndex", "baseZIndex", "filterBy", "scrollHeight", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "showTransitionOptions", "hideTransitionOptions", "ariaFilterLabel", "filterMatchMode", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "display", "autocomplete", "showClear", "defaultLabel", "placeholder", "options", "filterValue", "itemSize"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onClear", "onPanelShow", "onPanelHide", "onLazyLoad"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
8580
8595
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngDropdownComponent, decorators: [{
|
|
8581
8596
|
type: Component,
|
|
8582
8597
|
args: [{ selector: 'mng-dropdown', providers: [MNG_DROPDOWN_VALUE_ACCESSOR], changeDetection: ChangeDetectionStrategy.OnPush, template: "<p-dropdown\n *ngIf=\"!multiselect; else pMultiselect\"\n [formControl]=\"dropdownFormControl\"\n [placeholder]=\"$any(placeholder)\"\n [dataKey]=\"$any(dataKeyProperty)\"\n [optionLabel]=\"$any(itemsLabelProperty)\"\n [optionValue]=\"$any(itemsValueProperty)\"\n [optionDisabled]=\"$any(itemsDisabledProperty)\"\n [options]=\"$any(items$ | async)\"\n [showClear]=\"showClear\"\n [autoDisplayFirst]=\"false\"\n [styleClass]=\"$any(className)\"\n [panelStyleClass]=\"$any(dropdownClassName)\"\n (onBlur)=\"onDropdownBlur($event)\"\n [dropdownIcon]=\"($loading | async) ?? false ? 'pi pi-spinner pi-spin' : 'pi pi-chevron-down'\"\n appendTo=\"body\">\n</p-dropdown>\n<ng-template #pMultiselect>\n <p-multiSelect\n [maxSelectedLabels]=\"1\"\n [selectedItemsLabel]=\"'mngDropdown.multiselectOverMaxDisplayLimit' | translate\"\n [formControl]=\"dropdownFormControl\"\n [defaultLabel]=\"$any(placeholder)\"\n [dataKey]=\"$any(dataKeyProperty)\"\n [optionLabel]=\"$any(itemsLabelProperty)\"\n [optionValue]=\"$any(itemsValueProperty)\"\n [optionDisabled]=\"$any(itemsDisabledProperty)\"\n [options]=\"(items$ | async) ?? []\"\n [styleClass]=\"$any(className)\"\n [panelStyleClass]=\"$any(dropdownClassName)\"\n [filter]=\"true\"\n [showToggleAll]=\"false\"\n (onPanelHide)=\"onPanelHide($event)\"\n appendTo=\"body\">\n </p-multiSelect>\n</ng-template>\n" }]
|
|
@@ -8732,9 +8747,7 @@ class MngActionEditorComponent {
|
|
|
8732
8747
|
this.viewContainerService = viewContainerService;
|
|
8733
8748
|
this.actionRunEventEmitter = new EventEmitter();
|
|
8734
8749
|
this.actionCancelEventEmitter = new EventEmitter();
|
|
8735
|
-
this.cmpId = Math.random().toString(36).substring(2);
|
|
8736
8750
|
this.isDialog = true;
|
|
8737
|
-
this.isSaveButton = true;
|
|
8738
8751
|
this.toolbarLeftActions = [];
|
|
8739
8752
|
this.toolbarRightActions = [];
|
|
8740
8753
|
this.footerLeftActions = [];
|
|
@@ -8774,7 +8787,6 @@ class MngActionEditorComponent {
|
|
|
8774
8787
|
this.isDialog = false;
|
|
8775
8788
|
this.viewContainer = this.viewContainerInit ?? this.viewContainerService ?? undefined;
|
|
8776
8789
|
}
|
|
8777
|
-
this.isSaveButton = typeof this.action.submitFunction === 'function';
|
|
8778
8790
|
this.setTitle();
|
|
8779
8791
|
for (const action of this.action.editorActions) {
|
|
8780
8792
|
if (action instanceof ActionEditorSubmitDescriptor) {
|
|
@@ -8799,24 +8811,32 @@ class MngActionEditorComponent {
|
|
|
8799
8811
|
});
|
|
8800
8812
|
}
|
|
8801
8813
|
}
|
|
8802
|
-
|
|
8803
|
-
|
|
8804
|
-
|
|
8805
|
-
|
|
8806
|
-
case ActionPositionEnum.ToolbarRight:
|
|
8807
|
-
this.toolbarRightActions.push(action);
|
|
8808
|
-
break;
|
|
8809
|
-
case ActionPositionEnum.FooterLeft:
|
|
8810
|
-
this.footerLeftActions.push(action);
|
|
8811
|
-
break;
|
|
8812
|
-
case ActionPositionEnum.FooterRight:
|
|
8813
|
-
this.footerRightActions.push(action);
|
|
8814
|
-
break;
|
|
8815
|
-
}
|
|
8814
|
+
this.placeActionsOnPositions(action);
|
|
8815
|
+
}
|
|
8816
|
+
for (const action of this.viewContainer?.getActions().filter(value => value.positionTableviewCategories?.includes(this.action.tableviewCategory)) ?? []) {
|
|
8817
|
+
this.placeActionsOnPositions(action);
|
|
8816
8818
|
}
|
|
8817
8819
|
this.toolbarRightActions = this.toolbarRightActions.reverse();
|
|
8818
8820
|
this.footerRightActions = this.footerRightActions.reverse();
|
|
8819
8821
|
this.loadItemWithDataProvider();
|
|
8822
|
+
if (typeof this.viewContainer.getEditorReset$ === 'function') {
|
|
8823
|
+
const viewContainerEditor = this.viewContainer;
|
|
8824
|
+
viewContainerEditor.getEditorReset$().subscribe({
|
|
8825
|
+
next: e => {
|
|
8826
|
+
if (e.fetch) {
|
|
8827
|
+
this.loadItemWithDataProvider();
|
|
8828
|
+
}
|
|
8829
|
+
else if (e.item) {
|
|
8830
|
+
this.editorComponent?.resetFormModel(e.item);
|
|
8831
|
+
}
|
|
8832
|
+
else if (e.fields) {
|
|
8833
|
+
for (const key in e.fields) {
|
|
8834
|
+
this.editorComponent?.resetFormFieldValue(key, e.fields[key]);
|
|
8835
|
+
}
|
|
8836
|
+
}
|
|
8837
|
+
}
|
|
8838
|
+
});
|
|
8839
|
+
}
|
|
8820
8840
|
}
|
|
8821
8841
|
ngOnDestroy() {
|
|
8822
8842
|
this.subscriptions.forEach(s => s.unsubscribe());
|
|
@@ -8907,12 +8927,28 @@ class MngActionEditorComponent {
|
|
|
8907
8927
|
this.actionExecutor.deactivateAction(this.instance);
|
|
8908
8928
|
}
|
|
8909
8929
|
}
|
|
8930
|
+
placeActionsOnPositions(action) {
|
|
8931
|
+
switch (action.position) {
|
|
8932
|
+
case ActionPositionEnum.ToolbarLeft:
|
|
8933
|
+
this.toolbarLeftActions.push(action);
|
|
8934
|
+
break;
|
|
8935
|
+
case ActionPositionEnum.ToolbarRight:
|
|
8936
|
+
this.toolbarRightActions.push(action);
|
|
8937
|
+
break;
|
|
8938
|
+
case ActionPositionEnum.FooterLeft:
|
|
8939
|
+
this.footerLeftActions.push(action);
|
|
8940
|
+
break;
|
|
8941
|
+
case ActionPositionEnum.FooterRight:
|
|
8942
|
+
this.footerRightActions.push(action);
|
|
8943
|
+
break;
|
|
8944
|
+
}
|
|
8945
|
+
}
|
|
8910
8946
|
}
|
|
8911
8947
|
MngActionEditorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngActionEditorComponent, deps: [{ token: i0.Injector }, { token: i1$2.TranslateService }, { token: MngActionExecutorService }, { token: MngCommonsService }, { token: MngNavigationService }, { token: i3.DynamicDialogRef, optional: true }, { token: i3.DynamicDialogConfig, optional: true }, { token: MngViewContainerComponentService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
8912
|
-
MngActionEditorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngActionEditorComponent, selector: "mng-action-editor", inputs: { action: "action", itemId: "itemId", item: "item", actionData: "actionData", dataProvider: "dataProvider", viewContainerInit: ["viewContainer", "viewContainerInit"] }, outputs: { actionRunEventEmitter: "actionSubmit", actionCancelEventEmitter: "actionCancel" }, queries: [{ propertyName: "templates", predicate: MngTemplateDirective }], viewQueries: [{ propertyName: "submitButtonElementRef", first: true, predicate: ["submitButton"], descendants: true }, { propertyName: "editorComponent", first: true, predicate: MngFormEditorComponent, descendants: true }], ngImport: i0, template: "<h5 *ngIf=\"!isDialog && title\">{{ title }}</h5>\n<div class=\"h-full flex flex-column\">\n <div class=\"flex-grow-1\" *ngIf=\"toolbarLeftActions.length > 0 || toolbarRightActions.length > 0\">\n <p-toolbar styleClass=\"mng-action-editor-toolbar\">\n <ng-template pTemplate=\"left\">\n <mng-action
|
|
8948
|
+
MngActionEditorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngActionEditorComponent, selector: "mng-action-editor", inputs: { action: "action", itemId: "itemId", item: "item", actionData: "actionData", dataProvider: "dataProvider", viewContainerInit: ["viewContainer", "viewContainerInit"] }, outputs: { actionRunEventEmitter: "actionSubmit", actionCancelEventEmitter: "actionCancel" }, queries: [{ propertyName: "templates", predicate: MngTemplateDirective }], viewQueries: [{ propertyName: "submitButtonElementRef", first: true, predicate: ["submitButton"], descendants: true }, { propertyName: "editorComponent", first: true, predicate: MngFormEditorComponent, descendants: true }], ngImport: i0, template: "<h5 *ngIf=\"!isDialog && title\">{{ title }}</h5>\n<div class=\"h-full flex flex-column\">\n <div class=\"flex-grow-1 mng-action-editor-toolbar-container\" *ngIf=\"toolbarLeftActions.length > 0 || toolbarRightActions.length > 0\">\n <p-toolbar styleClass=\"mng-action-editor-toolbar\">\n <ng-template pTemplate=\"left\">\n <mng-action\n *ngFor=\"let action of toolbarLeftActions\"\n [action]=\"action\"\n [disabled]=\"submitLoading$\"\n [viewContainer]=\"viewContainer\"\n [item]=\"item\"\n [itemId]=\"itemId\"></mng-action>\n </ng-template>\n <ng-template pTemplate=\"right\">\n <mng-action\n *ngFor=\"let action of toolbarRightActions\"\n [action]=\"action\"\n [disabled]=\"submitLoading$\"\n [viewContainer]=\"viewContainer\"\n [item]=\"item\"\n [itemId]=\"itemId\"></mng-action>\n </ng-template>\n </p-toolbar>\n </div>\n\n <div class=\"flex-grow-1 mng-action-editor-form-container\">\n <div class=\"text-center\" *ngIf=\"loading$ | async\">\n <p-progressSpinner [style]=\"{width: '3rem', height: '3rem'}\" strokeWidth=\"3\"></p-progressSpinner>\n </div>\n <mng-form-editor *ngIf=\"action.editorDescriptor && (loading$ | async) === false\" [descriptor]=\"action.editorDescriptor\" [item]=\"item\" (formSubmit)=\"onSubmit($event)\">\n </mng-form-editor>\n </div>\n\n <div class=\"flex flex-row justify-content-between mng-action-editor-footer-container\">\n <div>\n <mng-action\n *ngFor=\"let action of footerLeftActions\"\n [action]=\"action\"\n [disabled]=\"submitLoading$\"\n [viewContainer]=\"viewContainer\"\n [item]=\"item\"\n [itemId]=\"itemId\"></mng-action>\n </div>\n <div>\n <mng-action\n *ngFor=\"let action of footerRightActions\"\n [action]=\"action\"\n [disabled]=\"submitLoading$\"\n [viewContainer]=\"viewContainer\"\n [item]=\"item\"\n [itemId]=\"itemId\"></mng-action>\n </div>\n </div>\n</div>\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i6$1.Toolbar, selector: "p-toolbar", inputs: ["style", "styleClass"] }, { kind: "component", type: i7$1.ProgressSpinner, selector: "p-progressSpinner", inputs: ["style", "styleClass", "strokeWidth", "fill", "animationDuration"] }, { kind: "component", type: MngFormEditorComponent, selector: "mng-form-editor", inputs: ["descriptor", "submitLoading", "item", "isSubmitButtonVisible", "isFormDisabled"], outputs: ["formSubmit"] }, { kind: "component", type: MngActionComponent, selector: "mng-action", inputs: ["action", "item", "itemId", "actionData", "queryParam", "dataProvider", "disabled", "loading", "viewContainer", "selectedItems"], outputs: ["finish"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
8913
8949
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngActionEditorComponent, decorators: [{
|
|
8914
8950
|
type: Component,
|
|
8915
|
-
args: [{ selector: 'mng-action-editor', changeDetection: ChangeDetectionStrategy.OnPush, template: "<h5 *ngIf=\"!isDialog && title\">{{ title }}</h5>\n<div class=\"h-full flex flex-column\">\n <div class=\"flex-grow-1\" *ngIf=\"toolbarLeftActions.length > 0 || toolbarRightActions.length > 0\">\n <p-toolbar styleClass=\"mng-action-editor-toolbar\">\n <ng-template pTemplate=\"left\">\n <mng-action
|
|
8951
|
+
args: [{ selector: 'mng-action-editor', changeDetection: ChangeDetectionStrategy.OnPush, template: "<h5 *ngIf=\"!isDialog && title\">{{ title }}</h5>\n<div class=\"h-full flex flex-column\">\n <div class=\"flex-grow-1 mng-action-editor-toolbar-container\" *ngIf=\"toolbarLeftActions.length > 0 || toolbarRightActions.length > 0\">\n <p-toolbar styleClass=\"mng-action-editor-toolbar\">\n <ng-template pTemplate=\"left\">\n <mng-action\n *ngFor=\"let action of toolbarLeftActions\"\n [action]=\"action\"\n [disabled]=\"submitLoading$\"\n [viewContainer]=\"viewContainer\"\n [item]=\"item\"\n [itemId]=\"itemId\"></mng-action>\n </ng-template>\n <ng-template pTemplate=\"right\">\n <mng-action\n *ngFor=\"let action of toolbarRightActions\"\n [action]=\"action\"\n [disabled]=\"submitLoading$\"\n [viewContainer]=\"viewContainer\"\n [item]=\"item\"\n [itemId]=\"itemId\"></mng-action>\n </ng-template>\n </p-toolbar>\n </div>\n\n <div class=\"flex-grow-1 mng-action-editor-form-container\">\n <div class=\"text-center\" *ngIf=\"loading$ | async\">\n <p-progressSpinner [style]=\"{width: '3rem', height: '3rem'}\" strokeWidth=\"3\"></p-progressSpinner>\n </div>\n <mng-form-editor *ngIf=\"action.editorDescriptor && (loading$ | async) === false\" [descriptor]=\"action.editorDescriptor\" [item]=\"item\" (formSubmit)=\"onSubmit($event)\">\n </mng-form-editor>\n </div>\n\n <div class=\"flex flex-row justify-content-between mng-action-editor-footer-container\">\n <div>\n <mng-action\n *ngFor=\"let action of footerLeftActions\"\n [action]=\"action\"\n [disabled]=\"submitLoading$\"\n [viewContainer]=\"viewContainer\"\n [item]=\"item\"\n [itemId]=\"itemId\"></mng-action>\n </div>\n <div>\n <mng-action\n *ngFor=\"let action of footerRightActions\"\n [action]=\"action\"\n [disabled]=\"submitLoading$\"\n [viewContainer]=\"viewContainer\"\n [item]=\"item\"\n [itemId]=\"itemId\"></mng-action>\n </div>\n </div>\n</div>\n" }]
|
|
8916
8952
|
}], ctorParameters: function () { return [{ type: i0.Injector }, { type: i1$2.TranslateService }, { type: MngActionExecutorService }, { type: MngCommonsService }, { type: MngNavigationService }, { type: i3.DynamicDialogRef, decorators: [{
|
|
8917
8953
|
type: Optional
|
|
8918
8954
|
}] }, { type: i3.DynamicDialogConfig, decorators: [{
|
|
@@ -9063,7 +9099,7 @@ class MngFormlyFieldInputComponent extends FieldType {
|
|
|
9063
9099
|
}
|
|
9064
9100
|
}
|
|
9065
9101
|
MngFormlyFieldInputComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormlyFieldInputComponent, deps: [{ token: LOCALE_ID }], target: i0.ɵɵFactoryTarget.Component });
|
|
9066
|
-
MngFormlyFieldInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngFormlyFieldInputComponent, selector: "mng-formly-field-input", usesInheritance: true, ngImport: i0, template: "<ng-container [ngSwitch]=\"to.type\">\n <p-inputNumber\n *ngSwitchCase=\"'number'\"\n [id]=\"$any(key)\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [min]=\"$any(descriptor.numberMin)\"\n [max]=\"$any(descriptor.numberMax)\"\n [step]=\"$any(descriptor.numberStep)\"\n [useGrouping]=\"$any(descriptor.numberUseGrouping)\"\n [minFractionDigits]=\"descriptor.numberMinFractionDigits || 0\"\n [maxFractionDigits]=\"descriptor.numberMaxFractionDigits || 0\"\n [inputStyleClass]=\"descriptor.inputClassName\"\n [locale]=\"$any(descriptor.locale ?? applicationLocale)\"\n [mode]=\"$any(numberFieldMode)\"\n [currency]=\"$any(currency)\"\n [currencyDisplay]=\"$any(descriptor.currencyDisplay)\">\n </p-inputNumber>\n\n <div *ngSwitchCase=\"'switch'\" class=\"field flex flex-column\">\n <label [for]=\"key\" [class]=\"descriptor.labelClassName\">{{ to?.label! | translate }} <span *ngIf=\"to.required && to['hideRequiredMarker'] !== true\">*</span></label>\n <p-inputSwitch [id]=\"$any(key)\" [formControl]=\"iFormControl\" [formlyAttributes]=\"field\" [styleClass]=\"descriptor.inputClassName\"></p-inputSwitch>\n <small *ngIf=\"showError\" class=\"p-error\">\n <formly-validation-message [field]=\"field\"></formly-validation-message>\n </small>\n </div>\n\n <ng-container *ngSwitchCase=\"'radio'\">\n <div *ngFor=\"let option of descriptor.radioOptions\" [id]=\"$any(key)\" class=\"field-radiobutton\">\n <p-radioButton\n [name]=\"$any(key)\"\n [value]=\"option.value\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [styleClass]=\"descriptor.inputClassName\"></p-radioButton>\n <label [for]=\"option.value\" [class]=\"'mng-radio-button-label ' + descriptor.labelClassName\">{{ option.title | translate }}</label>\n </div>\n </ng-container>\n\n <textarea\n *ngSwitchCase=\"'textarea'\"\n [id]=\"$any(key)\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [rows]=\"descriptor.rows ?? 3\"\n pInputTextarea\n [class]=\"descriptor.inputClassName\">\n </textarea>\n\n <p-calendar\n *ngSwitchCase=\"'datepicker'\"\n appendTo=\"body\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [dateFormat]=\"descriptor.datePickerFormat ?? 'dd.mm.yy'\"\n [minDate]=\"$any(descriptor.datePickerMin)\"\n [maxDate]=\"$any(descriptor.datePickerMax)\"\n [showTime]=\"descriptor.datePickerShowTime\"\n [showSeconds]=\"descriptor.datePickerShowSeconds\"\n [showIcon]=\"true\"\n [inputStyleClass]=\"descriptor.inputClassName\">\n </p-calendar>\n\n <p-inputMask\n *ngSwitchCase=\"'mask'\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [mask]=\"$any(descriptor.mask)\"\n [placeholder]=\"$any(descriptor.placeholder)\"\n [slotChar]=\"$any(descriptor.slotChar)\"\n [styleClass]=\"descriptor.inputClassName\">\n </p-inputMask>\n\n <p-fileUpload\n *ngSwitchCase=\"'file'\"\n [multiple]=\"descriptor.fileMultiple\"\n [accept]=\"$any(descriptor.fileAccept)\"\n [maxFileSize]=\"descriptor.fileMaxFileSize\"\n [showUploadButton]=\"false\"\n (onSelect)=\"onFileSelect($event)\"\n (onRemove)=\"onFileRemove($event)\"\n (onClear)=\"onFileClear($event)\">\n </p-fileUpload>\n\n <input *ngSwitchDefault pInputText [id]=\"$any(key)\" [type]=\"to.type || 'text'\" [formControl]=\"iFormControl\" [formlyAttributes]=\"field\" />\n</ng-container>\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1$1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "directive", type: i2$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2$2.ɵFormlyAttributes, selector: "[formlyAttributes]", inputs: ["formlyAttributes", "id"] }, { kind: "component", type: i2$2.ɵFormlyValidationMessage, selector: "formly-validation-message", inputs: ["field"] }, { kind: "component", type: i4$3.Calendar, selector: "p-calendar", inputs: ["style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "view", "defaultDate", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "component", type: i5$
|
|
9102
|
+
MngFormlyFieldInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngFormlyFieldInputComponent, selector: "mng-formly-field-input", usesInheritance: true, ngImport: i0, template: "<ng-container [ngSwitch]=\"to.type\">\n <p-inputNumber\n *ngSwitchCase=\"'number'\"\n [id]=\"$any(key)\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [min]=\"$any(descriptor.numberMin)\"\n [max]=\"$any(descriptor.numberMax)\"\n [step]=\"$any(descriptor.numberStep)\"\n [useGrouping]=\"$any(descriptor.numberUseGrouping)\"\n [minFractionDigits]=\"descriptor.numberMinFractionDigits || 0\"\n [maxFractionDigits]=\"descriptor.numberMaxFractionDigits || 0\"\n [inputStyleClass]=\"descriptor.inputClassName\"\n [locale]=\"$any(descriptor.locale ?? applicationLocale)\"\n [mode]=\"$any(numberFieldMode)\"\n [currency]=\"$any(currency)\"\n [currencyDisplay]=\"$any(descriptor.currencyDisplay)\">\n </p-inputNumber>\n\n <div *ngSwitchCase=\"'switch'\" class=\"field flex flex-column\">\n <label [for]=\"key\" [class]=\"descriptor.labelClassName\">{{ to?.label! | translate }} <span *ngIf=\"to.required && to['hideRequiredMarker'] !== true\">*</span></label>\n <p-inputSwitch [id]=\"$any(key)\" [formControl]=\"iFormControl\" [formlyAttributes]=\"field\" [styleClass]=\"descriptor.inputClassName\"></p-inputSwitch>\n <small *ngIf=\"showError\" class=\"p-error\">\n <formly-validation-message [field]=\"field\"></formly-validation-message>\n </small>\n </div>\n\n <ng-container *ngSwitchCase=\"'radio'\">\n <div *ngFor=\"let option of descriptor.radioOptions\" [id]=\"$any(key)\" class=\"field-radiobutton\">\n <p-radioButton\n [name]=\"$any(key)\"\n [value]=\"option.value\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [styleClass]=\"descriptor.inputClassName\"></p-radioButton>\n <label [for]=\"option.value\" [class]=\"'mng-radio-button-label ' + descriptor.labelClassName\">{{ option.title | translate }}</label>\n </div>\n </ng-container>\n\n <textarea\n *ngSwitchCase=\"'textarea'\"\n [id]=\"$any(key)\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [rows]=\"descriptor.rows ?? 3\"\n pInputTextarea\n [class]=\"descriptor.inputClassName\">\n </textarea>\n\n <p-calendar\n *ngSwitchCase=\"'datepicker'\"\n appendTo=\"body\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [dateFormat]=\"descriptor.datePickerFormat ?? 'dd.mm.yy'\"\n [minDate]=\"$any(descriptor.datePickerMin)\"\n [maxDate]=\"$any(descriptor.datePickerMax)\"\n [showTime]=\"descriptor.datePickerShowTime\"\n [showSeconds]=\"descriptor.datePickerShowSeconds\"\n [showIcon]=\"true\"\n [inputStyleClass]=\"descriptor.inputClassName\">\n </p-calendar>\n\n <p-inputMask\n *ngSwitchCase=\"'mask'\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [mask]=\"$any(descriptor.mask)\"\n [placeholder]=\"$any(descriptor.placeholder)\"\n [slotChar]=\"$any(descriptor.slotChar)\"\n [styleClass]=\"descriptor.inputClassName\">\n </p-inputMask>\n\n <p-fileUpload\n *ngSwitchCase=\"'file'\"\n [multiple]=\"descriptor.fileMultiple\"\n [accept]=\"$any(descriptor.fileAccept)\"\n [maxFileSize]=\"descriptor.fileMaxFileSize\"\n [showUploadButton]=\"false\"\n (onSelect)=\"onFileSelect($event)\"\n (onRemove)=\"onFileRemove($event)\"\n (onClear)=\"onFileClear($event)\">\n </p-fileUpload>\n\n <input *ngSwitchDefault pInputText [id]=\"$any(key)\" [type]=\"to.type || 'text'\" [formControl]=\"iFormControl\" [formlyAttributes]=\"field\" />\n</ng-container>\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i1$1.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "directive", type: i2$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2$2.ɵFormlyAttributes, selector: "[formlyAttributes]", inputs: ["formlyAttributes", "id"] }, { kind: "component", type: i2$2.ɵFormlyValidationMessage, selector: "formly-validation-message", inputs: ["field"] }, { kind: "component", type: i4$3.Calendar, selector: "p-calendar", inputs: ["style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "view", "defaultDate", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "component", type: i5$3.FileUpload, selector: "p-fileUpload", inputs: ["name", "url", "method", "multiple", "accept", "disabled", "auto", "withCredentials", "maxFileSize", "invalidFileSizeMessageSummary", "invalidFileSizeMessageDetail", "invalidFileTypeMessageSummary", "invalidFileTypeMessageDetail", "invalidFileLimitMessageDetail", "invalidFileLimitMessageSummary", "style", "styleClass", "previewWidth", "chooseLabel", "uploadLabel", "cancelLabel", "chooseIcon", "uploadIcon", "cancelIcon", "showUploadButton", "showCancelButton", "mode", "headers", "customUpload", "fileLimit", "files"], outputs: ["onBeforeUpload", "onSend", "onUpload", "onError", "onClear", "onRemove", "onSelect", "onProgress", "uploadHandler"] }, { kind: "component", type: i6$2.InputNumber, selector: "p-inputNumber", inputs: ["showButtons", "format", "buttonLayout", "inputId", "styleClass", "style", "placeholder", "size", "maxlength", "tabindex", "title", "ariaLabel", "ariaRequired", "name", "required", "autocomplete", "min", "max", "incrementButtonClass", "decrementButtonClass", "incrementButtonIcon", "decrementButtonIcon", "readonly", "step", "allowEmpty", "locale", "localeMatcher", "mode", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "prefix", "suffix", "inputStyle", "inputStyleClass", "showClear", "disabled"], outputs: ["onInput", "onFocus", "onBlur", "onKeyDown", "onClear"] }, { kind: "component", type: i7$2.InputMask, selector: "p-inputMask", inputs: ["type", "slotChar", "autoClear", "showClear", "style", "inputId", "styleClass", "placeholder", "size", "maxlength", "tabindex", "title", "ariaLabel", "ariaRequired", "disabled", "readonly", "unmask", "name", "required", "characterPattern", "autoFocus", "autocomplete", "mask"], outputs: ["onComplete", "onFocus", "onBlur", "onInput", "onKeydown", "onClear"] }, { kind: "component", type: i8.InputSwitch, selector: "p-inputSwitch", inputs: ["style", "styleClass", "tabindex", "inputId", "name", "disabled", "readonly", "trueValue", "falseValue", "ariaLabel", "ariaLabelledBy"], outputs: ["onChange"] }, { kind: "directive", type: i9$1.InputText, selector: "[pInputText]" }, { kind: "directive", type: i10.InputTextarea, selector: "[pInputTextarea]", inputs: ["autoResize"], outputs: ["onResize"] }, { kind: "component", type: i11.RadioButton, selector: "p-radioButton", inputs: ["value", "formControlName", "name", "disabled", "label", "tabindex", "inputId", "ariaLabelledBy", "ariaLabel", "style", "styleClass", "labelStyleClass"], outputs: ["onClick", "onFocus", "onBlur"] }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
9067
9103
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormlyFieldInputComponent, decorators: [{
|
|
9068
9104
|
type: Component,
|
|
9069
9105
|
args: [{ selector: 'mng-formly-field-input', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container [ngSwitch]=\"to.type\">\n <p-inputNumber\n *ngSwitchCase=\"'number'\"\n [id]=\"$any(key)\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [min]=\"$any(descriptor.numberMin)\"\n [max]=\"$any(descriptor.numberMax)\"\n [step]=\"$any(descriptor.numberStep)\"\n [useGrouping]=\"$any(descriptor.numberUseGrouping)\"\n [minFractionDigits]=\"descriptor.numberMinFractionDigits || 0\"\n [maxFractionDigits]=\"descriptor.numberMaxFractionDigits || 0\"\n [inputStyleClass]=\"descriptor.inputClassName\"\n [locale]=\"$any(descriptor.locale ?? applicationLocale)\"\n [mode]=\"$any(numberFieldMode)\"\n [currency]=\"$any(currency)\"\n [currencyDisplay]=\"$any(descriptor.currencyDisplay)\">\n </p-inputNumber>\n\n <div *ngSwitchCase=\"'switch'\" class=\"field flex flex-column\">\n <label [for]=\"key\" [class]=\"descriptor.labelClassName\">{{ to?.label! | translate }} <span *ngIf=\"to.required && to['hideRequiredMarker'] !== true\">*</span></label>\n <p-inputSwitch [id]=\"$any(key)\" [formControl]=\"iFormControl\" [formlyAttributes]=\"field\" [styleClass]=\"descriptor.inputClassName\"></p-inputSwitch>\n <small *ngIf=\"showError\" class=\"p-error\">\n <formly-validation-message [field]=\"field\"></formly-validation-message>\n </small>\n </div>\n\n <ng-container *ngSwitchCase=\"'radio'\">\n <div *ngFor=\"let option of descriptor.radioOptions\" [id]=\"$any(key)\" class=\"field-radiobutton\">\n <p-radioButton\n [name]=\"$any(key)\"\n [value]=\"option.value\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [styleClass]=\"descriptor.inputClassName\"></p-radioButton>\n <label [for]=\"option.value\" [class]=\"'mng-radio-button-label ' + descriptor.labelClassName\">{{ option.title | translate }}</label>\n </div>\n </ng-container>\n\n <textarea\n *ngSwitchCase=\"'textarea'\"\n [id]=\"$any(key)\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [rows]=\"descriptor.rows ?? 3\"\n pInputTextarea\n [class]=\"descriptor.inputClassName\">\n </textarea>\n\n <p-calendar\n *ngSwitchCase=\"'datepicker'\"\n appendTo=\"body\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [dateFormat]=\"descriptor.datePickerFormat ?? 'dd.mm.yy'\"\n [minDate]=\"$any(descriptor.datePickerMin)\"\n [maxDate]=\"$any(descriptor.datePickerMax)\"\n [showTime]=\"descriptor.datePickerShowTime\"\n [showSeconds]=\"descriptor.datePickerShowSeconds\"\n [showIcon]=\"true\"\n [inputStyleClass]=\"descriptor.inputClassName\">\n </p-calendar>\n\n <p-inputMask\n *ngSwitchCase=\"'mask'\"\n [formControl]=\"iFormControl\"\n [formlyAttributes]=\"field\"\n [mask]=\"$any(descriptor.mask)\"\n [placeholder]=\"$any(descriptor.placeholder)\"\n [slotChar]=\"$any(descriptor.slotChar)\"\n [styleClass]=\"descriptor.inputClassName\">\n </p-inputMask>\n\n <p-fileUpload\n *ngSwitchCase=\"'file'\"\n [multiple]=\"descriptor.fileMultiple\"\n [accept]=\"$any(descriptor.fileAccept)\"\n [maxFileSize]=\"descriptor.fileMaxFileSize\"\n [showUploadButton]=\"false\"\n (onSelect)=\"onFileSelect($event)\"\n (onRemove)=\"onFileRemove($event)\"\n (onClear)=\"onFileClear($event)\">\n </p-fileUpload>\n\n <input *ngSwitchDefault pInputText [id]=\"$any(key)\" [type]=\"to.type || 'text'\" [formControl]=\"iFormControl\" [formlyAttributes]=\"field\" />\n</ng-container>\n" }]
|
|
@@ -9186,7 +9222,7 @@ class MngTableColumnValueComponent {
|
|
|
9186
9222
|
}
|
|
9187
9223
|
}
|
|
9188
9224
|
MngTableColumnValueComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTableColumnValueComponent, deps: [{ token: i0.ElementRef }, { token: i2.MessageService }, { token: i1$2.TranslateService }], target: i0.ɵɵFactoryTarget.Component });
|
|
9189
|
-
MngTableColumnValueComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTableColumnValueComponent, selector: "mng-table-column-value", inputs: { descriptor: "descriptor", item: "item" }, host: { properties: { "style.max-width.px": "this.styleMaxWidth", "class": "this.className" } }, ngImport: i0, template: "<ng-container [ngSwitch]=\"descriptor.columnType\">\n <ng-container *ngSwitchCase=\"columnTypeString\">\n {{ item | jsonPath: jsonPath | getter: descriptor.getter | template: descriptor.template }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeNumber\">\n {{ item | jsonPath: jsonPath | number: descriptor.displayFormat:descriptor.locale }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeCurrency\">\n {{ item | jsonPath: jsonPath | currency: currency:descriptor.currencyDisplay:descriptor.displayFormat:descriptor.locale }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeDate\">\n {{ item | jsonPath: jsonPath | date: descriptor.displayFormat }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeBoolean\">\n <ng-container *ngIf=\"descriptor.booleanAsIcon; else booleanText\"></ng-container>\n <i [class]=\"item | jsonPath: jsonPath | boolean: descriptor.booleanYes:descriptor.booleanNo:true\"></i>\n <ng-template #booleanText>\n {{ item | jsonPath: jsonPath | boolean: descriptor.booleanYes:descriptor.booleanNo | translate }}\n </ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeEnum\">\n {{ item | jsonPath: jsonPath | enum: descriptor.enumType:descriptor.enumTitlePath:descriptor.enumNameAsValue | translate }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeCustom\">\n <ng-container\n [mngComponent]=\"descriptor.customComponentType!\"\n [inputs]=\"{\n value: item | jsonPath: jsonPath,\n item: item,\n descriptor: descriptor\n }\"></ng-container>\n </ng-container>\n</ng-container>\n<div class=\"help-buttons\" *ngIf=\"descriptor.hasCopyToClipboard\">\n <button pButton pRipple type=\"button\" icon=\"pi pi-copy\" class=\"p-button-rounded p-button-info p-button-sm\" (click)=\"copyToClipboard($event)\"></button>\n</div>\n", styles: [":host{display:inline-block;overflow:hidden}:host.nowrap{white-space:nowrap;text-overflow:ellipsis}:host:hover .help-buttons{display:block}.help-buttons{display:none;position:absolute;right:0;top:50%;transform:translateY(-50%)}.help-buttons .p-button{height:1.9rem;width:1.9rem;padding:0}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i4$1.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { kind: "directive", type:
|
|
9225
|
+
MngTableColumnValueComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTableColumnValueComponent, selector: "mng-table-column-value", inputs: { descriptor: "descriptor", item: "item" }, host: { properties: { "style.max-width.px": "this.styleMaxWidth", "class": "this.className" } }, ngImport: i0, template: "<ng-container [ngSwitch]=\"descriptor.columnType\">\n <ng-container *ngSwitchCase=\"columnTypeString\">\n {{ item | jsonPath: jsonPath | getter: descriptor.getter | template: descriptor.template }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeNumber\">\n {{ item | jsonPath: jsonPath | number: descriptor.displayFormat:descriptor.locale }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeCurrency\">\n {{ item | jsonPath: jsonPath | currency: currency:descriptor.currencyDisplay:descriptor.displayFormat:descriptor.locale }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeDate\">\n {{ item | jsonPath: jsonPath | date: descriptor.displayFormat }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeBoolean\">\n <ng-container *ngIf=\"descriptor.booleanAsIcon; else booleanText\"></ng-container>\n <i [class]=\"item | jsonPath: jsonPath | boolean: descriptor.booleanYes:descriptor.booleanNo:true\"></i>\n <ng-template #booleanText>\n {{ item | jsonPath: jsonPath | boolean: descriptor.booleanYes:descriptor.booleanNo | translate }}\n </ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeEnum\">\n {{ item | jsonPath: jsonPath | enum: descriptor.enumType:descriptor.enumTitlePath:descriptor.enumNameAsValue | translate }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeCustom\">\n <ng-container\n [mngComponent]=\"descriptor.customComponentType!\"\n [inputs]=\"{\n value: item | jsonPath: jsonPath,\n item: item,\n descriptor: descriptor\n }\"></ng-container>\n </ng-container>\n</ng-container>\n<div class=\"help-buttons\" *ngIf=\"descriptor.hasCopyToClipboard\">\n <button pButton pRipple type=\"button\" icon=\"pi pi-copy\" class=\"p-button-rounded p-button-info p-button-sm\" (click)=\"copyToClipboard($event)\"></button>\n</div>\n", styles: [":host{display:inline-block;overflow:hidden}:host.nowrap{white-space:nowrap;text-overflow:ellipsis}:host:hover .help-buttons{display:block}.help-buttons{display:none;position:absolute;right:0;top:50%;transform:translateY(-50%)}.help-buttons .p-button{height:1.9rem;width:1.9rem;padding:0}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i4$1.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { kind: "directive", type: i5.Ripple, selector: "[pRipple]" }, { kind: "directive", type: MngComponentDirective, selector: "[mngComponent]", inputs: ["mngComponent", "inputs"], outputs: ["instanceCreated"] }, { kind: "pipe", type: i1$1.DecimalPipe, name: "number" }, { kind: "pipe", type: i1$1.CurrencyPipe, name: "currency" }, { kind: "pipe", type: i1$1.DatePipe, name: "date" }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }, { kind: "pipe", type: JsonPathPipe, name: "jsonPath" }, { kind: "pipe", type: MngEnumPipe, name: "enum" }, { kind: "pipe", type: MngBooleanPipe, name: "boolean" }, { kind: "pipe", type: MngGetterPipe, name: "getter" }, { kind: "pipe", type: MngTemplatePipe, name: "template" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
9190
9226
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTableColumnValueComponent, decorators: [{
|
|
9191
9227
|
type: Component,
|
|
9192
9228
|
args: [{ selector: 'mng-table-column-value', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-container [ngSwitch]=\"descriptor.columnType\">\n <ng-container *ngSwitchCase=\"columnTypeString\">\n {{ item | jsonPath: jsonPath | getter: descriptor.getter | template: descriptor.template }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeNumber\">\n {{ item | jsonPath: jsonPath | number: descriptor.displayFormat:descriptor.locale }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeCurrency\">\n {{ item | jsonPath: jsonPath | currency: currency:descriptor.currencyDisplay:descriptor.displayFormat:descriptor.locale }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeDate\">\n {{ item | jsonPath: jsonPath | date: descriptor.displayFormat }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeBoolean\">\n <ng-container *ngIf=\"descriptor.booleanAsIcon; else booleanText\"></ng-container>\n <i [class]=\"item | jsonPath: jsonPath | boolean: descriptor.booleanYes:descriptor.booleanNo:true\"></i>\n <ng-template #booleanText>\n {{ item | jsonPath: jsonPath | boolean: descriptor.booleanYes:descriptor.booleanNo | translate }}\n </ng-template>\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeEnum\">\n {{ item | jsonPath: jsonPath | enum: descriptor.enumType:descriptor.enumTitlePath:descriptor.enumNameAsValue | translate }}\n </ng-container>\n <ng-container *ngSwitchCase=\"columnTypeCustom\">\n <ng-container\n [mngComponent]=\"descriptor.customComponentType!\"\n [inputs]=\"{\n value: item | jsonPath: jsonPath,\n item: item,\n descriptor: descriptor\n }\"></ng-container>\n </ng-container>\n</ng-container>\n<div class=\"help-buttons\" *ngIf=\"descriptor.hasCopyToClipboard\">\n <button pButton pRipple type=\"button\" icon=\"pi pi-copy\" class=\"p-button-rounded p-button-info p-button-sm\" (click)=\"copyToClipboard($event)\"></button>\n</div>\n", styles: [":host{display:inline-block;overflow:hidden}:host.nowrap{white-space:nowrap;text-overflow:ellipsis}:host:hover .help-buttons{display:block}.help-buttons{display:none;position:absolute;right:0;top:50%;transform:translateY(-50%)}.help-buttons .p-button{height:1.9rem;width:1.9rem;padding:0}\n"] }]
|
|
@@ -9295,7 +9331,7 @@ class MngTableColumnFilterComponent {
|
|
|
9295
9331
|
}
|
|
9296
9332
|
}
|
|
9297
9333
|
MngTableColumnFilterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTableColumnFilterComponent, deps: [{ token: i2.PrimeNGConfig }], target: i0.ɵɵFactoryTarget.Component });
|
|
9298
|
-
MngTableColumnFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTableColumnFilterComponent, selector: "mng-table-column-filter", inputs: { descriptor: "descriptor", display: "display" }, viewQueries: [{ propertyName: "primeColumnFilter", first: true, predicate: ColumnFilter, descendants: true }], ngImport: i0, template: "<p-columnFilter\n class=\"ml-auto\"\n [type]=\"primeType\"\n [field]=\"descriptor.property\"\n [display]=\"primeDisplay\"\n [matchMode]=\"$any(primeDefaultMatchMode)\"\n [matchModeOptions]=\"$any(primeMatchModes)\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.typeToFilter' | translate\"\n [showMatchModes]=\"true\"\n [showOperator]=\"false\"\n [showAddButton]=\"false\"\n [hideOnClear]=\"true\"\n [showMenu]=\"primeShowMatchMode\"\n [minFractionDigits]=\"$any(descriptor.numberMinFractionDigits)\"\n [maxFractionDigits]=\"$any(descriptor.numberMaxFractionDigits)\"\n [useGrouping]=\"descriptor.numberUseGrouping\">\n <ng-template *ngIf=\"primeType === 'date'\" pTemplate=\"filter\" let-value let-filterCallback=\"filterCallback\">\n <ng-container *ngIf=\"activeMatchMode === 'between'; else datePicker\">\n <mng-date-range\n [ngModel]=\"value\"\n (ngModelChange)=\"dateFilter($event, filterCallback)\"\n [showTime]=\"descriptor.datePickerShowTime\"\n [dateFormat]=\"descriptor.datePickerFormat\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.typeToFilter' | translate\"></mng-date-range>\n </ng-container>\n <ng-template #datePicker>\n <p-calendar\n appendTo=\"body\"\n [ngModel]=\"value\"\n (ngModelChange)=\"dateFilter($event, filterCallback)\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.typeToFilter' | translate\"\n [showIcon]=\"true\"\n [dateFormat]=\"descriptor.datePickerFormat ?? 'dd.mm.yy'\"\n [showTime]=\"descriptor.datePickerShowTime\">\n </p-calendar>\n </ng-template>\n </ng-template>\n <ng-template *ngIf=\"lookupDescriptor\" pTemplate=\"filter\" let-value let-filterCallback=\"filterCallback\">\n <ng-container [ngSwitch]=\"lookupDescriptor.lookupType\">\n <mng-autocomplete\n *ngSwitchCase=\"lookupTypeAutocomplete\"\n [ngModel]=\"value\"\n [dataProvider]=\"lookupDescriptor.dataProvider\"\n [dataKeyProperty]=\"lookupDescriptor.dataKeyProperty\"\n [itemsValueProperty]=\"lookupDescriptor.itemsValueProperty\"\n [itemsLabelProperty]=\"lookupDescriptor.itemsLabelProperty\"\n [itemsLabelTranslate]=\"lookupDescriptor.itemsLabelTranslate\"\n [multiselect]=\"lookupDescriptor.multiselect\"\n [openOnFocus]=\"lookupDescriptor.autocompleteOpenOnFocus\"\n [inlineSearch]=\"lookupDescriptor.autocompleteInlineSearch\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.searchToFilter' | translate\"\n [className]=\"lookupDescriptor.className\"\n [dropdownClassName]=\"lookupDescriptor.dropdownClassName\"\n (valueChange)=\"autocompleteFilter($event, filterCallback)\">\n </mng-autocomplete>\n <mng-dropdown\n *ngSwitchCase=\"lookupTypeDropdown\"\n [ngModel]=\"value\"\n [dataProvider]=\"lookupDescriptor.dataProvider\"\n [itemsValueProperty]=\"lookupDescriptor.itemsValueProperty\"\n [itemsLabelProperty]=\"lookupDescriptor.itemsLabelProperty\"\n [itemsLabelTranslate]=\"lookupDescriptor.itemsLabelTranslate\"\n [multiselect]=\"lookupDescriptor.multiselect\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.selectToFilter' | translate\"\n [className]=\"lookupDescriptor.className\"\n [dropdownClassName]=\"lookupDescriptor.dropdownClassName\"\n [showClear]=\"false\"\n [changeValueOnBlur]=\"lookupDescriptor.multiselect\"\n (valueChange)=\"dropdownFilter($event, filterCallback)\">\n </mng-dropdown>\n </ng-container>\n </ng-template>\n</p-columnFilter>\n", dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i4$3.Calendar, selector: "p-calendar", inputs: ["style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "view", "defaultDate", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6$
|
|
9334
|
+
MngTableColumnFilterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTableColumnFilterComponent, selector: "mng-table-column-filter", inputs: { descriptor: "descriptor", display: "display" }, viewQueries: [{ propertyName: "primeColumnFilter", first: true, predicate: ColumnFilter, descendants: true }], ngImport: i0, template: "<p-columnFilter\n class=\"ml-auto\"\n [type]=\"primeType\"\n [field]=\"descriptor.property\"\n [display]=\"primeDisplay\"\n [matchMode]=\"$any(primeDefaultMatchMode)\"\n [matchModeOptions]=\"$any(primeMatchModes)\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.typeToFilter' | translate\"\n [showMatchModes]=\"true\"\n [showOperator]=\"false\"\n [showAddButton]=\"false\"\n [hideOnClear]=\"true\"\n [showMenu]=\"primeShowMatchMode\"\n [minFractionDigits]=\"$any(descriptor.numberMinFractionDigits)\"\n [maxFractionDigits]=\"$any(descriptor.numberMaxFractionDigits)\"\n [useGrouping]=\"descriptor.numberUseGrouping\">\n <ng-template *ngIf=\"primeType === 'date'\" pTemplate=\"filter\" let-value let-filterCallback=\"filterCallback\">\n <ng-container *ngIf=\"activeMatchMode === 'between'; else datePicker\">\n <mng-date-range\n [ngModel]=\"value\"\n (ngModelChange)=\"dateFilter($event, filterCallback)\"\n [showTime]=\"descriptor.datePickerShowTime\"\n [dateFormat]=\"descriptor.datePickerFormat\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.typeToFilter' | translate\"></mng-date-range>\n </ng-container>\n <ng-template #datePicker>\n <p-calendar\n appendTo=\"body\"\n [ngModel]=\"value\"\n (ngModelChange)=\"dateFilter($event, filterCallback)\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.typeToFilter' | translate\"\n [showIcon]=\"true\"\n [dateFormat]=\"descriptor.datePickerFormat ?? 'dd.mm.yy'\"\n [showTime]=\"descriptor.datePickerShowTime\">\n </p-calendar>\n </ng-template>\n </ng-template>\n <ng-template *ngIf=\"lookupDescriptor\" pTemplate=\"filter\" let-value let-filterCallback=\"filterCallback\">\n <ng-container [ngSwitch]=\"lookupDescriptor.lookupType\">\n <mng-autocomplete\n *ngSwitchCase=\"lookupTypeAutocomplete\"\n [ngModel]=\"value\"\n [dataProvider]=\"lookupDescriptor.dataProvider\"\n [dataKeyProperty]=\"lookupDescriptor.dataKeyProperty\"\n [itemsValueProperty]=\"lookupDescriptor.itemsValueProperty\"\n [itemsLabelProperty]=\"lookupDescriptor.itemsLabelProperty\"\n [itemsLabelTranslate]=\"lookupDescriptor.itemsLabelTranslate\"\n [multiselect]=\"lookupDescriptor.multiselect\"\n [openOnFocus]=\"lookupDescriptor.autocompleteOpenOnFocus\"\n [inlineSearch]=\"lookupDescriptor.autocompleteInlineSearch\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.searchToFilter' | translate\"\n [className]=\"lookupDescriptor.className\"\n [dropdownClassName]=\"lookupDescriptor.dropdownClassName\"\n (valueChange)=\"autocompleteFilter($event, filterCallback)\">\n </mng-autocomplete>\n <mng-dropdown\n *ngSwitchCase=\"lookupTypeDropdown\"\n [ngModel]=\"value\"\n [dataProvider]=\"lookupDescriptor.dataProvider\"\n [itemsValueProperty]=\"lookupDescriptor.itemsValueProperty\"\n [itemsLabelProperty]=\"lookupDescriptor.itemsLabelProperty\"\n [itemsLabelTranslate]=\"lookupDescriptor.itemsLabelTranslate\"\n [multiselect]=\"lookupDescriptor.multiselect\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.selectToFilter' | translate\"\n [className]=\"lookupDescriptor.className\"\n [dropdownClassName]=\"lookupDescriptor.dropdownClassName\"\n [showClear]=\"false\"\n [changeValueOnBlur]=\"lookupDescriptor.multiselect\"\n (valueChange)=\"dropdownFilter($event, filterCallback)\">\n </mng-dropdown>\n </ng-container>\n </ng-template>\n</p-columnFilter>\n", dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i4$3.Calendar, selector: "p-calendar", inputs: ["style", "styleClass", "inputStyle", "inputId", "name", "inputStyleClass", "placeholder", "ariaLabelledBy", "iconAriaLabel", "disabled", "dateFormat", "multipleSeparator", "rangeSeparator", "inline", "showOtherMonths", "selectOtherMonths", "showIcon", "icon", "appendTo", "readonlyInput", "shortYearCutoff", "monthNavigator", "yearNavigator", "hourFormat", "timeOnly", "stepHour", "stepMinute", "stepSecond", "showSeconds", "required", "showOnFocus", "showWeek", "showClear", "dataType", "selectionMode", "maxDateCount", "showButtonBar", "todayButtonStyleClass", "clearButtonStyleClass", "autoZIndex", "baseZIndex", "panelStyleClass", "panelStyle", "keepInvalid", "hideOnDateTimeSelect", "touchUI", "timeSeparator", "focusTrap", "showTransitionOptions", "hideTransitionOptions", "tabindex", "view", "defaultDate", "minDate", "maxDate", "disabledDates", "disabledDays", "yearRange", "showTime", "responsiveOptions", "numberOfMonths", "firstDayOfWeek", "locale"], outputs: ["onFocus", "onBlur", "onClose", "onSelect", "onClear", "onInput", "onTodayClick", "onClearClick", "onMonthChange", "onYearChange", "onClickOutside", "onShow"] }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "component", type: i6$3.ColumnFilter, selector: "p-columnFilter", inputs: ["field", "type", "display", "showMenu", "matchMode", "operator", "showOperator", "showClearButton", "showApplyButton", "showMatchModes", "showAddButton", "hideOnClear", "placeholder", "matchModeOptions", "maxConstraints", "minFractionDigits", "maxFractionDigits", "prefix", "suffix", "locale", "localeMatcher", "currency", "currencyDisplay", "useGrouping"] }, { kind: "component", type: MngAutocompleteComponent, selector: "mng-autocomplete", inputs: ["dataProvider", "dataKeyProperty", "itemsValueProperty", "itemsLabelProperty", "itemsLabelTranslate", "inlineSearch", "openOnFocus", "multiselect", "placeholder", "className", "dropdownClassName", "showClear", "autoClear", "selectFirst"], outputs: ["valueChange"] }, { kind: "component", type: MngDropdownComponent, selector: "mng-dropdown", inputs: ["dataProvider", "dataKeyProperty", "itemsLabelProperty", "itemsLabelTranslate", "itemsValueProperty", "itemsDisabledProperty", "multiselect", "placeholder", "showClear", "selectFirstItem", "className", "dropdownClassName", "changeValueOnBlur"], outputs: ["valueChange"] }, { kind: "component", type: MngDateRangeComponent, selector: "mng-date-range", inputs: ["placeholder", "showTime", "showSeconds", "dateFormat"] }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }] });
|
|
9299
9335
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTableColumnFilterComponent, decorators: [{
|
|
9300
9336
|
type: Component,
|
|
9301
9337
|
args: [{ selector: 'mng-table-column-filter', template: "<p-columnFilter\n class=\"ml-auto\"\n [type]=\"primeType\"\n [field]=\"descriptor.property\"\n [display]=\"primeDisplay\"\n [matchMode]=\"$any(primeDefaultMatchMode)\"\n [matchModeOptions]=\"$any(primeMatchModes)\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.typeToFilter' | translate\"\n [showMatchModes]=\"true\"\n [showOperator]=\"false\"\n [showAddButton]=\"false\"\n [hideOnClear]=\"true\"\n [showMenu]=\"primeShowMatchMode\"\n [minFractionDigits]=\"$any(descriptor.numberMinFractionDigits)\"\n [maxFractionDigits]=\"$any(descriptor.numberMaxFractionDigits)\"\n [useGrouping]=\"descriptor.numberUseGrouping\">\n <ng-template *ngIf=\"primeType === 'date'\" pTemplate=\"filter\" let-value let-filterCallback=\"filterCallback\">\n <ng-container *ngIf=\"activeMatchMode === 'between'; else datePicker\">\n <mng-date-range\n [ngModel]=\"value\"\n (ngModelChange)=\"dateFilter($event, filterCallback)\"\n [showTime]=\"descriptor.datePickerShowTime\"\n [dateFormat]=\"descriptor.datePickerFormat\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.typeToFilter' | translate\"></mng-date-range>\n </ng-container>\n <ng-template #datePicker>\n <p-calendar\n appendTo=\"body\"\n [ngModel]=\"value\"\n (ngModelChange)=\"dateFilter($event, filterCallback)\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.typeToFilter' | translate\"\n [showIcon]=\"true\"\n [dateFormat]=\"descriptor.datePickerFormat ?? 'dd.mm.yy'\"\n [showTime]=\"descriptor.datePickerShowTime\">\n </p-calendar>\n </ng-template>\n </ng-template>\n <ng-template *ngIf=\"lookupDescriptor\" pTemplate=\"filter\" let-value let-filterCallback=\"filterCallback\">\n <ng-container [ngSwitch]=\"lookupDescriptor.lookupType\">\n <mng-autocomplete\n *ngSwitchCase=\"lookupTypeAutocomplete\"\n [ngModel]=\"value\"\n [dataProvider]=\"lookupDescriptor.dataProvider\"\n [dataKeyProperty]=\"lookupDescriptor.dataKeyProperty\"\n [itemsValueProperty]=\"lookupDescriptor.itemsValueProperty\"\n [itemsLabelProperty]=\"lookupDescriptor.itemsLabelProperty\"\n [itemsLabelTranslate]=\"lookupDescriptor.itemsLabelTranslate\"\n [multiselect]=\"lookupDescriptor.multiselect\"\n [openOnFocus]=\"lookupDescriptor.autocompleteOpenOnFocus\"\n [inlineSearch]=\"lookupDescriptor.autocompleteInlineSearch\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.searchToFilter' | translate\"\n [className]=\"lookupDescriptor.className\"\n [dropdownClassName]=\"lookupDescriptor.dropdownClassName\"\n (valueChange)=\"autocompleteFilter($event, filterCallback)\">\n </mng-autocomplete>\n <mng-dropdown\n *ngSwitchCase=\"lookupTypeDropdown\"\n [ngModel]=\"value\"\n [dataProvider]=\"lookupDescriptor.dataProvider\"\n [itemsValueProperty]=\"lookupDescriptor.itemsValueProperty\"\n [itemsLabelProperty]=\"lookupDescriptor.itemsLabelProperty\"\n [itemsLabelTranslate]=\"lookupDescriptor.itemsLabelTranslate\"\n [multiselect]=\"lookupDescriptor.multiselect\"\n [placeholder]=\"descriptor.placeholder ?? 'mngTable.selectToFilter' | translate\"\n [className]=\"lookupDescriptor.className\"\n [dropdownClassName]=\"lookupDescriptor.dropdownClassName\"\n [showClear]=\"false\"\n [changeValueOnBlur]=\"lookupDescriptor.multiselect\"\n (valueChange)=\"dropdownFilter($event, filterCallback)\">\n </mng-dropdown>\n </ng-container>\n </ng-template>\n</p-columnFilter>\n" }]
|
|
@@ -9775,7 +9811,7 @@ class MngTableComponent {
|
|
|
9775
9811
|
}
|
|
9776
9812
|
}
|
|
9777
9813
|
MngTableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTableComponent, deps: [{ token: i0.Injector }, { token: i1.Router }, { token: i1.ActivatedRoute }, { token: i1$2.TranslateService }, { token: MngActionExecutorService }, { token: MngViewContainerComponentService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
|
|
9778
|
-
MngTableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTableComponent, selector: "mng-table", inputs: { initialDescriptor: ["descriptor", "initialDescriptor"], items: "items", queryResult: "queryResult", loading: "loading", dataProvider: "dataProvider", useQueryParams: "useQueryParams", selectionMode: "selectionMode", selectionEnabled: "selectionEnabled", actions: "actions", isColumnClickable: "isColumnClickable", viewContainerInit: ["viewContainer", "viewContainerInit"], captionComponent: "captionComponent", columnActionComponent: "columnActionComponent", columnActionMinWidth: "columnActionMinWidth" }, outputs: { loadEventEmitter: "tableLoad", cellClickEventEmitter: "cellClick", selectionChangeEventEmitter: "selectionChange", captionCmpInstEventEmitter: "captionComponentInstance", columnActionCmpInstEventEmitter: "columnActionComponentInstance" }, queries: [{ propertyName: "templates", predicate: MngTemplateDirective }], viewQueries: [{ propertyName: "primeTable", first: true, predicate: Table, descendants: true }, { propertyName: "components", predicate: MngComponentDirective, descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div [style.height]=\"scrollHeight === 'flex' ? 'calc(100vh - ' + tableFullHeightOffset + 'px)' : null\">\n <!-- MUST NOT use observable for value when using virtual scroll - does not work for some reason -->\n <p-table\n *ngIf=\"!useQueryParams || (useQueryParamsInitialized$ | async)\"\n [value]=\"infiniteScroll ? dataProviderInfiniteScrollItems : (queryResult$ | async)?.pageData ?? []\"\n [dataKey]=\"$any(descriptor?.dataKeyProperty ?? null)\"\n [lazy]=\"useDataProvider\"\n [loading]=\"(loading$ | async) ?? false\"\n [paginator]=\"useDataProvider && !infiniteScroll\"\n [rows]=\"$any(infiniteScroll ? 20 : rows)\"\n [first]=\"$any(infiniteScroll ? 0 : offset)\"\n [totalRecords]=\"$any(infiniteScroll ? null : (queryResult$ | async)?.allDataCount ?? 0)\"\n [rowsPerPageOptions]=\"$any(infiniteScroll ? null : rowsPerPageOptions)\"\n [showCurrentPageReport]=\"!infiniteScroll\"\n [currentPageReportTemplate]=\"'mngTable.paginationMsg' | translate\"\n [multiSortMeta]=\"$any(multiSortMeta)\"\n [filters]=\"filterMetadata\"\n [(selection)]=\"selection\"\n (selectionChange)=\"onSelectionChange($event)\"\n [scrollable]=\"infiniteScroll\"\n [virtualScroll]=\"infiniteScroll\"\n [virtualRowHeight]=\"$any(rowHeight)\"\n [scrollHeight]=\"$any(scrollHeight)\"\n [selectionMode]=\"$any(selectionEnabled ? selectionMode : null)\"\n [rowHover]=\"descriptor?.hasHover ?? true\"\n [styleClass]=\"className\"\n (onLazyLoad)=\"onTableLazyLoad($event)\"\n (onSort)=\"onTableSort($event)\"\n (onFilter)=\"onTableFilter($event)\"\n sortMode=\"multiple\"\n responsiveLayout=\"scroll\"\n [resizableColumns]=\"true\"\n [autoLayout]=\"true\">\n <ng-template *ngIf=\"captionTemplate || captionComponent || descriptor?.title\" pTemplate=\"caption\">\n <ng-container *ngIf=\"captionTemplate; else componentOrDefaultCaption\">\n <ng-container *ngTemplateOutlet=\"captionTemplate\"></ng-container>\n </ng-container>\n <ng-template #componentOrDefaultCaption>\n <div *ngIf=\"captionComponent; else defaultCaption\" [mngComponent]=\"captionComponent\" (instanceCreated)=\"onCaptionCmpInst($event)\"></div>\n <ng-template #defaultCaption>\n <h5 class=\"p-0 m-0\">{{ descriptor?.title }}</h5>\n </ng-template>\n </ng-template>\n </ng-template>\n\n <ng-template pTemplate=\"header\">\n <tr *ngIf=\"!descriptor?.hideHeader\" class=\"mng-table-header\" [class]=\"descriptor?.headerClassName\">\n <th *ngIf=\"selectionEnabled && selectionMode === 'multiple'\">\n <p-tableHeaderCheckbox></p-tableHeaderCheckbox>\n </th>\n <!-- We need the line below, because otherwise p-tableRadioButton shifts the rest of the columns in table -->\n <th *ngIf=\"selectionEnabled && selectionMode === 'single'\" style=\"min-width: 36px\"></th>\n <ng-container *ngFor=\"let col of descriptor?.columns\">\n <th *ngIf=\"col.isSortEnabled\" [pSortableColumn]=\"col.property\" [style.width.%]=\"col.width\" [style.min-width.px]=\"col.minWidth\" [class]=\"col.headerClassName\">\n <div class=\"flex justify-content-between align-items-center\">\n {{ col.title ?? (col.property | i18nProperty: descriptor!.model) | translate }}\n <p-sortIcon [field]=\"col.property\"></p-sortIcon>\n <mng-table-column-filter\n *ngIf=\"col.filterDescriptor && descriptor!.filterDisplay === filterDisplayMenu\"\n class=\"ml-auto\"\n [display]=\"descriptor!.filterDisplay\"\n [descriptor]=\"col.filterDescriptor\">\n </mng-table-column-filter>\n </div>\n </th>\n <th *ngIf=\"!col.isSortEnabled\">\n {{ col.title ?? (col.property | i18nProperty: descriptor!.model) | translate }}\n <ng-container>\n <mng-table-column-filter\n *ngIf=\"col.filterDescriptor && descriptor!.filterDisplay === filterDisplayMenu\"\n class=\"ml-auto\"\n [display]=\"descriptor!.filterDisplay\"\n [descriptor]=\"col.filterDescriptor\">\n </mng-table-column-filter>\n </ng-container>\n </th>\n </ng-container>\n <th *ngIf=\"showInlineActionsColumn\"></th>\n </tr>\n <tr *ngIf=\"descriptor?.filterDisplay === filterDisplayRow && hasColumnFilters\" class=\"mng-column-filter-row\">\n <!-- We need the line below, because otherwise p-tableRadioButton shifts the rest of the columns in table -->\n <th *ngIf=\"selectionEnabled && selectionMode === 'single'\" style=\"min-width: 36px\"></th>\n <th\n *ngFor=\"let col of descriptor?.columns\"\n [class]=\"(col.filterDescriptor ? 'mng-column-filter-' + col.filterDescriptor.filterType + ' ' : ' ') + col.filterDescriptor?.columnClassName\"\n [style.width.%]=\"col.filterDescriptor?.columnWidth ?? col.width\"\n [style.min-width.px]=\"col.filterDescriptor?.columnMinWidth ?? col.minWidth\">\n <div class=\"flex\" *ngIf=\"col.filterDescriptor\">\n <mng-table-column-filter [display]=\"descriptor!.filterDisplay\" [descriptor]=\"col.filterDescriptor\"></mng-table-column-filter>\n </div>\n </th>\n <th *ngIf=\"showInlineActionsColumn\"></th>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"body\" let-item let-idx=\"rowIndex\">\n <tr [style.height.px]=\"rowHeight\" [class]=\"descriptor?.rowClassName | mngClassMapPipe: descriptor?.rowClassNameMapFn:item\">\n <td *ngIf=\"selectionEnabled && selectionMode === 'multiple'\" style=\"width: 3rem\">\n <p-tableCheckbox [value]=\"item\"></p-tableCheckbox>\n </td>\n <td *ngIf=\"selectionEnabled && selectionMode === 'single'\" style=\"width: 3rem\">\n <p-tableRadioButton [value]=\"item\"></p-tableRadioButton>\n </td>\n <td\n *ngFor=\"let col of descriptor?.columns\"\n (click)=\"onCellClick($event, col, item, idx)\"\n [class]=\"col.className\"\n [class.clickable]=\"isColumnClickable\"\n [style.width.%]=\"col.width\"\n [style.min-width.px]=\"col.minWidth\">\n <mng-table-column-value [descriptor]=\"col\" [item]=\"item\"></mng-table-column-value>\n </td>\n <td *ngIf=\"showInlineActionsColumn\" class=\"column-action text-right\" [style.min-width.px]=\"columnActionMinWidth\">\n <ng-container *ngIf=\"columnActionTemplate; else showColumnActionComponentOrDefault\">\n <ng-container *ngTemplateOutlet=\"columnActionTemplate; context: {rowItem: item, rowIndex: idx}\"></ng-container>\n </ng-container>\n <ng-template #showColumnActionComponentOrDefault>\n <span\n *ngIf=\"columnActionComponent; else defaultColumnActions\"\n [mngComponent]=\"columnActionComponent!\"\n (instanceCreated)=\"onColumnActionCmpInst($event)\"></span>\n </ng-template>\n <ng-template #defaultColumnActions>\n <mng-action\n *ngFor=\"let action of rowInlineActions\"\n [action]=\"action\"\n [item]=\"item\"\n [itemId]=\"descriptor?.model?.idPropertyName ? item[descriptor!.model!.idPropertyName!] : null\"\n [actionData]=\"{itemIndex: idx}\"\n (finish)=\"onActionFinish($event)\">\n </mng-action>\n </ng-template>\n </td>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"loadingbody\">\n <tr [style.height.px]=\"rowHeight\">\n <td [attr.colspan]=\"(descriptor?.columns?.length ?? 0) + (showInlineActionsColumn ? 1 : 0) + (selectionEnabled ? 1 : 0)\">\n <div class=\"loading-text\"></div>\n <p-skeleton [ngStyle]=\"{width: '100%'}\"></p-skeleton>\n </td>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"emptymessage\">\n <tr [style.height.px]=\"rowHeight\">\n <td [attr.colspan]=\"(descriptor?.columns?.length ?? 0) + (showInlineActionsColumn ? 1 : 0) + (selectionEnabled ? 1 : 0)\">\n {{ 'mngTable.noItems' | translate }}\n </td>\n </tr>\n </ng-template>\n\n <ng-template *ngIf=\"footerTemplate\" pTemplate=\"summary\">\n <ng-container [ngTemplateOutlet]=\"footerTemplate\" [ngTemplateOutletContext]=\"{queryResult: queryResult}\"></ng-container>\n </ng-template>\n </p-table>\n</div>\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i6$4.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "virtualRowHeight", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll"], outputs: ["selectAllChange", "selectionChange", "contextMenuSelectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i6$4.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i6$4.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6$4.TableRadioButton, selector: "p-tableRadioButton", inputs: ["disabled", "value", "index", "inputId", "name", "ariaLabel"] }, { kind: "component", type: i6$4.TableCheckbox, selector: "p-tableCheckbox", inputs: ["disabled", "value", "index", "inputId", "name", "required", "ariaLabel"] }, { kind: "component", type: i6$4.TableHeaderCheckbox, selector: "p-tableHeaderCheckbox", inputs: ["disabled", "inputId", "name", "ariaLabel"] }, { kind: "component", type: i7$3.Skeleton, selector: "p-skeleton", inputs: ["styleClass", "style", "shape", "animation", "borderRadius", "size", "width", "height"] }, { kind: "directive", type: MngComponentDirective, selector: "[mngComponent]", inputs: ["mngComponent", "inputs"], outputs: ["instanceCreated"] }, { kind: "component", type: MngTableColumnValueComponent, selector: "mng-table-column-value", inputs: ["descriptor", "item"] }, { kind: "component", type: MngTableColumnFilterComponent, selector: "mng-table-column-filter", inputs: ["descriptor", "display"] }, { kind: "component", type: MngActionComponent, selector: "mng-action", inputs: ["action", "item", "itemId", "actionData", "queryParam", "dataProvider", "disabled", "loading", "viewContainer", "selectedItems"], outputs: ["finish"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }, { kind: "pipe", type: MngI18nPropertyPipe, name: "i18nProperty" }, { kind: "pipe", type: MngClassMapPipe, name: "mngClassMapPipe" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
9814
|
+
MngTableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTableComponent, selector: "mng-table", inputs: { initialDescriptor: ["descriptor", "initialDescriptor"], items: "items", queryResult: "queryResult", loading: "loading", dataProvider: "dataProvider", useQueryParams: "useQueryParams", selectionMode: "selectionMode", selectionEnabled: "selectionEnabled", actions: "actions", isColumnClickable: "isColumnClickable", viewContainerInit: ["viewContainer", "viewContainerInit"], captionComponent: "captionComponent", columnActionComponent: "columnActionComponent", columnActionMinWidth: "columnActionMinWidth" }, outputs: { loadEventEmitter: "tableLoad", cellClickEventEmitter: "cellClick", selectionChangeEventEmitter: "selectionChange", captionCmpInstEventEmitter: "captionComponentInstance", columnActionCmpInstEventEmitter: "columnActionComponentInstance" }, queries: [{ propertyName: "templates", predicate: MngTemplateDirective }], viewQueries: [{ propertyName: "primeTable", first: true, predicate: Table, descendants: true }, { propertyName: "components", predicate: MngComponentDirective, descendants: true }], usesOnChanges: true, ngImport: i0, template: "<div [style.height]=\"scrollHeight === 'flex' ? 'calc(100vh - ' + tableFullHeightOffset + 'px)' : null\">\n <!-- MUST NOT use observable for value when using virtual scroll - does not work for some reason -->\n <p-table\n *ngIf=\"!useQueryParams || (useQueryParamsInitialized$ | async)\"\n [value]=\"infiniteScroll ? dataProviderInfiniteScrollItems : (queryResult$ | async)?.pageData ?? []\"\n [dataKey]=\"$any(descriptor?.dataKeyProperty ?? null)\"\n [lazy]=\"useDataProvider\"\n [loading]=\"(loading$ | async) ?? false\"\n [paginator]=\"useDataProvider && !infiniteScroll\"\n [rows]=\"$any(infiniteScroll ? 20 : rows)\"\n [first]=\"$any(infiniteScroll ? 0 : offset)\"\n [totalRecords]=\"$any(infiniteScroll ? null : (queryResult$ | async)?.allDataCount ?? 0)\"\n [rowsPerPageOptions]=\"$any(infiniteScroll ? null : rowsPerPageOptions)\"\n [showCurrentPageReport]=\"!infiniteScroll\"\n [currentPageReportTemplate]=\"'mngTable.paginationMsg' | translate\"\n [multiSortMeta]=\"$any(multiSortMeta)\"\n [filters]=\"filterMetadata\"\n [(selection)]=\"selection\"\n (selectionChange)=\"onSelectionChange($event)\"\n [scrollable]=\"infiniteScroll\"\n [virtualScroll]=\"infiniteScroll\"\n [virtualRowHeight]=\"$any(rowHeight)\"\n [scrollHeight]=\"$any(scrollHeight)\"\n [selectionMode]=\"$any(selectionEnabled ? selectionMode : null)\"\n [rowHover]=\"descriptor?.hasHover ?? true\"\n [styleClass]=\"className\"\n (onLazyLoad)=\"onTableLazyLoad($event)\"\n (onSort)=\"onTableSort($event)\"\n (onFilter)=\"onTableFilter($event)\"\n sortMode=\"multiple\"\n responsiveLayout=\"scroll\"\n [resizableColumns]=\"true\"\n [autoLayout]=\"true\">\n <ng-template *ngIf=\"captionTemplate || captionComponent || descriptor?.title\" pTemplate=\"caption\">\n <ng-container *ngIf=\"captionTemplate; else componentOrDefaultCaption\">\n <ng-container *ngTemplateOutlet=\"captionTemplate\"></ng-container>\n </ng-container>\n <ng-template #componentOrDefaultCaption>\n <div *ngIf=\"captionComponent; else defaultCaption\" [mngComponent]=\"captionComponent\" (instanceCreated)=\"onCaptionCmpInst($event)\"></div>\n <ng-template #defaultCaption>\n <h5 class=\"p-0 m-0\">{{ descriptor?.title }}</h5>\n </ng-template>\n </ng-template>\n </ng-template>\n\n <ng-template pTemplate=\"header\">\n <tr *ngIf=\"!descriptor?.hideHeader\" class=\"mng-table-header\" [class]=\"descriptor?.headerClassName\">\n <th *ngIf=\"selectionEnabled && selectionMode === 'multiple'\">\n <p-tableHeaderCheckbox></p-tableHeaderCheckbox>\n </th>\n <!-- We need the line below, because otherwise p-tableRadioButton shifts the rest of the columns in table -->\n <th *ngIf=\"selectionEnabled && selectionMode === 'single'\" style=\"min-width: 36px\"></th>\n <ng-container *ngFor=\"let col of descriptor?.columns\">\n <th *ngIf=\"col.isSortEnabled\" [pSortableColumn]=\"col.property\" [style.width.%]=\"col.width\" [style.min-width.px]=\"col.minWidth\" [class]=\"col.headerClassName\">\n <div class=\"flex justify-content-between align-items-center\">\n {{ col.title ?? (col.property | i18nProperty: descriptor!.model) | translate }}\n <p-sortIcon [field]=\"col.property\"></p-sortIcon>\n <mng-table-column-filter\n *ngIf=\"col.filterDescriptor && descriptor!.filterDisplay === filterDisplayMenu\"\n class=\"ml-auto\"\n [display]=\"descriptor!.filterDisplay\"\n [descriptor]=\"col.filterDescriptor\">\n </mng-table-column-filter>\n </div>\n </th>\n <th *ngIf=\"!col.isSortEnabled\">\n {{ col.title ?? (col.property | i18nProperty: descriptor!.model) | translate }}\n <ng-container>\n <mng-table-column-filter\n *ngIf=\"col.filterDescriptor && descriptor!.filterDisplay === filterDisplayMenu\"\n class=\"ml-auto\"\n [display]=\"descriptor!.filterDisplay\"\n [descriptor]=\"col.filterDescriptor\">\n </mng-table-column-filter>\n </ng-container>\n </th>\n </ng-container>\n <th *ngIf=\"showInlineActionsColumn\"></th>\n </tr>\n <tr *ngIf=\"descriptor?.filterDisplay === filterDisplayRow && hasColumnFilters\" class=\"mng-column-filter-row\">\n <!-- We need the line below, because otherwise p-tableRadioButton shifts the rest of the columns in table -->\n <th *ngIf=\"selectionEnabled && selectionMode === 'single'\" style=\"min-width: 36px\"></th>\n <th\n *ngFor=\"let col of descriptor?.columns\"\n [class]=\"(col.filterDescriptor ? 'mng-column-filter-' + col.filterDescriptor.filterType + ' ' : ' ') + col.filterDescriptor?.columnClassName\"\n [style.width.%]=\"col.filterDescriptor?.columnWidth ?? col.width\"\n [style.min-width.px]=\"col.filterDescriptor?.columnMinWidth ?? col.minWidth\">\n <div class=\"flex\" *ngIf=\"col.filterDescriptor\">\n <mng-table-column-filter [display]=\"descriptor!.filterDisplay\" [descriptor]=\"col.filterDescriptor\"></mng-table-column-filter>\n </div>\n </th>\n <th *ngIf=\"showInlineActionsColumn\"></th>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"body\" let-item let-idx=\"rowIndex\">\n <tr [style.height.px]=\"rowHeight\" [class]=\"descriptor?.rowClassName | mngClassMapPipe: descriptor?.rowClassNameMapFn:item\">\n <td *ngIf=\"selectionEnabled && selectionMode === 'multiple'\" style=\"width: 3rem\">\n <p-tableCheckbox [value]=\"item\"></p-tableCheckbox>\n </td>\n <td *ngIf=\"selectionEnabled && selectionMode === 'single'\" style=\"width: 3rem\">\n <p-tableRadioButton [value]=\"item\"></p-tableRadioButton>\n </td>\n <td\n *ngFor=\"let col of descriptor?.columns\"\n (click)=\"onCellClick($event, col, item, idx)\"\n [class]=\"col.className\"\n [class.clickable]=\"isColumnClickable\"\n [style.width.%]=\"col.width\"\n [style.min-width.px]=\"col.minWidth\">\n <mng-table-column-value [descriptor]=\"col\" [item]=\"item\"></mng-table-column-value>\n </td>\n <td *ngIf=\"showInlineActionsColumn\" class=\"column-action text-right\" [style.min-width.px]=\"columnActionMinWidth\">\n <ng-container *ngIf=\"columnActionTemplate; else showColumnActionComponentOrDefault\">\n <ng-container *ngTemplateOutlet=\"columnActionTemplate; context: {rowItem: item, rowIndex: idx}\"></ng-container>\n </ng-container>\n <ng-template #showColumnActionComponentOrDefault>\n <span\n *ngIf=\"columnActionComponent; else defaultColumnActions\"\n [mngComponent]=\"columnActionComponent!\"\n (instanceCreated)=\"onColumnActionCmpInst($event)\"></span>\n </ng-template>\n <ng-template #defaultColumnActions>\n <mng-action\n *ngFor=\"let action of rowInlineActions\"\n [action]=\"action\"\n [item]=\"item\"\n [itemId]=\"descriptor?.model?.idPropertyName ? item[descriptor!.model!.idPropertyName!] : null\"\n [actionData]=\"{itemIndex: idx}\"\n (finish)=\"onActionFinish($event)\">\n </mng-action>\n </ng-template>\n </td>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"loadingbody\">\n <tr [style.height.px]=\"rowHeight\">\n <td [attr.colspan]=\"(descriptor?.columns?.length ?? 0) + (showInlineActionsColumn ? 1 : 0) + (selectionEnabled ? 1 : 0)\">\n <div class=\"loading-text\"></div>\n <p-skeleton [ngStyle]=\"{width: '100%'}\"></p-skeleton>\n </td>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"emptymessage\">\n <tr [style.height.px]=\"rowHeight\">\n <td [attr.colspan]=\"(descriptor?.columns?.length ?? 0) + (showInlineActionsColumn ? 1 : 0) + (selectionEnabled ? 1 : 0)\">\n {{ 'mngTable.noItems' | translate }}\n </td>\n </tr>\n </ng-template>\n\n <ng-template *ngIf=\"footerTemplate\" pTemplate=\"summary\">\n <ng-container [ngTemplateOutlet]=\"footerTemplate\" [ngTemplateOutletContext]=\"{queryResult: queryResult}\"></ng-container>\n </ng-template>\n </p-table>\n</div>\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1$1.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i6$3.Table, selector: "p-table", inputs: ["frozenColumns", "frozenValue", "style", "styleClass", "tableStyle", "tableStyleClass", "paginator", "pageLinks", "rowsPerPageOptions", "alwaysShowPaginator", "paginatorPosition", "paginatorDropdownAppendTo", "paginatorDropdownScrollHeight", "currentPageReportTemplate", "showCurrentPageReport", "showJumpToPageDropdown", "showJumpToPageInput", "showFirstLastIcon", "showPageLinks", "defaultSortOrder", "sortMode", "resetPageOnSort", "selectionMode", "selectionPageOnly", "contextMenuSelection", "contextMenuSelectionMode", "dataKey", "metaKeySelection", "rowSelectable", "rowTrackBy", "lazy", "lazyLoadOnInit", "compareSelectionBy", "csvSeparator", "exportFilename", "filters", "globalFilterFields", "filterDelay", "filterLocale", "expandedRowKeys", "editingRowKeys", "rowExpandMode", "scrollable", "scrollDirection", "rowGroupMode", "scrollHeight", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "virtualScrollDelay", "frozenWidth", "responsive", "contextMenu", "resizableColumns", "columnResizeMode", "reorderableColumns", "loading", "loadingIcon", "showLoader", "rowHover", "customSort", "showInitialSortBadge", "autoLayout", "exportFunction", "exportHeader", "stateKey", "stateStorage", "editMode", "groupRowsBy", "groupRowsByOrder", "responsiveLayout", "breakpoint", "virtualRowHeight", "value", "columns", "first", "rows", "totalRecords", "sortField", "sortOrder", "multiSortMeta", "selection", "selectAll"], outputs: ["selectAllChange", "selectionChange", "contextMenuSelectionChange", "onRowSelect", "onRowUnselect", "onPage", "onSort", "onFilter", "onLazyLoad", "onRowExpand", "onRowCollapse", "onContextMenuSelect", "onColResize", "onColReorder", "onRowReorder", "onEditInit", "onEditComplete", "onEditCancel", "onHeaderCheckboxToggle", "sortFunction", "firstChange", "rowsChange", "onStateSave", "onStateRestore"] }, { kind: "directive", type: i6$3.SortableColumn, selector: "[pSortableColumn]", inputs: ["pSortableColumn", "pSortableColumnDisabled"] }, { kind: "component", type: i6$3.SortIcon, selector: "p-sortIcon", inputs: ["field"] }, { kind: "component", type: i6$3.TableRadioButton, selector: "p-tableRadioButton", inputs: ["disabled", "value", "index", "inputId", "name", "ariaLabel"] }, { kind: "component", type: i6$3.TableCheckbox, selector: "p-tableCheckbox", inputs: ["disabled", "value", "index", "inputId", "name", "required", "ariaLabel"] }, { kind: "component", type: i6$3.TableHeaderCheckbox, selector: "p-tableHeaderCheckbox", inputs: ["disabled", "inputId", "name", "ariaLabel"] }, { kind: "component", type: i7$3.Skeleton, selector: "p-skeleton", inputs: ["styleClass", "style", "shape", "animation", "borderRadius", "size", "width", "height"] }, { kind: "directive", type: MngComponentDirective, selector: "[mngComponent]", inputs: ["mngComponent", "inputs"], outputs: ["instanceCreated"] }, { kind: "component", type: MngTableColumnValueComponent, selector: "mng-table-column-value", inputs: ["descriptor", "item"] }, { kind: "component", type: MngTableColumnFilterComponent, selector: "mng-table-column-filter", inputs: ["descriptor", "display"] }, { kind: "component", type: MngActionComponent, selector: "mng-action", inputs: ["action", "item", "itemId", "actionData", "queryParam", "dataProvider", "disabled", "loading", "viewContainer", "selectedItems"], outputs: ["finish"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }, { kind: "pipe", type: MngI18nPropertyPipe, name: "i18nProperty" }, { kind: "pipe", type: MngClassMapPipe, name: "mngClassMapPipe" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
9779
9815
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTableComponent, decorators: [{
|
|
9780
9816
|
type: Component,
|
|
9781
9817
|
args: [{ selector: 'mng-table', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div [style.height]=\"scrollHeight === 'flex' ? 'calc(100vh - ' + tableFullHeightOffset + 'px)' : null\">\n <!-- MUST NOT use observable for value when using virtual scroll - does not work for some reason -->\n <p-table\n *ngIf=\"!useQueryParams || (useQueryParamsInitialized$ | async)\"\n [value]=\"infiniteScroll ? dataProviderInfiniteScrollItems : (queryResult$ | async)?.pageData ?? []\"\n [dataKey]=\"$any(descriptor?.dataKeyProperty ?? null)\"\n [lazy]=\"useDataProvider\"\n [loading]=\"(loading$ | async) ?? false\"\n [paginator]=\"useDataProvider && !infiniteScroll\"\n [rows]=\"$any(infiniteScroll ? 20 : rows)\"\n [first]=\"$any(infiniteScroll ? 0 : offset)\"\n [totalRecords]=\"$any(infiniteScroll ? null : (queryResult$ | async)?.allDataCount ?? 0)\"\n [rowsPerPageOptions]=\"$any(infiniteScroll ? null : rowsPerPageOptions)\"\n [showCurrentPageReport]=\"!infiniteScroll\"\n [currentPageReportTemplate]=\"'mngTable.paginationMsg' | translate\"\n [multiSortMeta]=\"$any(multiSortMeta)\"\n [filters]=\"filterMetadata\"\n [(selection)]=\"selection\"\n (selectionChange)=\"onSelectionChange($event)\"\n [scrollable]=\"infiniteScroll\"\n [virtualScroll]=\"infiniteScroll\"\n [virtualRowHeight]=\"$any(rowHeight)\"\n [scrollHeight]=\"$any(scrollHeight)\"\n [selectionMode]=\"$any(selectionEnabled ? selectionMode : null)\"\n [rowHover]=\"descriptor?.hasHover ?? true\"\n [styleClass]=\"className\"\n (onLazyLoad)=\"onTableLazyLoad($event)\"\n (onSort)=\"onTableSort($event)\"\n (onFilter)=\"onTableFilter($event)\"\n sortMode=\"multiple\"\n responsiveLayout=\"scroll\"\n [resizableColumns]=\"true\"\n [autoLayout]=\"true\">\n <ng-template *ngIf=\"captionTemplate || captionComponent || descriptor?.title\" pTemplate=\"caption\">\n <ng-container *ngIf=\"captionTemplate; else componentOrDefaultCaption\">\n <ng-container *ngTemplateOutlet=\"captionTemplate\"></ng-container>\n </ng-container>\n <ng-template #componentOrDefaultCaption>\n <div *ngIf=\"captionComponent; else defaultCaption\" [mngComponent]=\"captionComponent\" (instanceCreated)=\"onCaptionCmpInst($event)\"></div>\n <ng-template #defaultCaption>\n <h5 class=\"p-0 m-0\">{{ descriptor?.title }}</h5>\n </ng-template>\n </ng-template>\n </ng-template>\n\n <ng-template pTemplate=\"header\">\n <tr *ngIf=\"!descriptor?.hideHeader\" class=\"mng-table-header\" [class]=\"descriptor?.headerClassName\">\n <th *ngIf=\"selectionEnabled && selectionMode === 'multiple'\">\n <p-tableHeaderCheckbox></p-tableHeaderCheckbox>\n </th>\n <!-- We need the line below, because otherwise p-tableRadioButton shifts the rest of the columns in table -->\n <th *ngIf=\"selectionEnabled && selectionMode === 'single'\" style=\"min-width: 36px\"></th>\n <ng-container *ngFor=\"let col of descriptor?.columns\">\n <th *ngIf=\"col.isSortEnabled\" [pSortableColumn]=\"col.property\" [style.width.%]=\"col.width\" [style.min-width.px]=\"col.minWidth\" [class]=\"col.headerClassName\">\n <div class=\"flex justify-content-between align-items-center\">\n {{ col.title ?? (col.property | i18nProperty: descriptor!.model) | translate }}\n <p-sortIcon [field]=\"col.property\"></p-sortIcon>\n <mng-table-column-filter\n *ngIf=\"col.filterDescriptor && descriptor!.filterDisplay === filterDisplayMenu\"\n class=\"ml-auto\"\n [display]=\"descriptor!.filterDisplay\"\n [descriptor]=\"col.filterDescriptor\">\n </mng-table-column-filter>\n </div>\n </th>\n <th *ngIf=\"!col.isSortEnabled\">\n {{ col.title ?? (col.property | i18nProperty: descriptor!.model) | translate }}\n <ng-container>\n <mng-table-column-filter\n *ngIf=\"col.filterDescriptor && descriptor!.filterDisplay === filterDisplayMenu\"\n class=\"ml-auto\"\n [display]=\"descriptor!.filterDisplay\"\n [descriptor]=\"col.filterDescriptor\">\n </mng-table-column-filter>\n </ng-container>\n </th>\n </ng-container>\n <th *ngIf=\"showInlineActionsColumn\"></th>\n </tr>\n <tr *ngIf=\"descriptor?.filterDisplay === filterDisplayRow && hasColumnFilters\" class=\"mng-column-filter-row\">\n <!-- We need the line below, because otherwise p-tableRadioButton shifts the rest of the columns in table -->\n <th *ngIf=\"selectionEnabled && selectionMode === 'single'\" style=\"min-width: 36px\"></th>\n <th\n *ngFor=\"let col of descriptor?.columns\"\n [class]=\"(col.filterDescriptor ? 'mng-column-filter-' + col.filterDescriptor.filterType + ' ' : ' ') + col.filterDescriptor?.columnClassName\"\n [style.width.%]=\"col.filterDescriptor?.columnWidth ?? col.width\"\n [style.min-width.px]=\"col.filterDescriptor?.columnMinWidth ?? col.minWidth\">\n <div class=\"flex\" *ngIf=\"col.filterDescriptor\">\n <mng-table-column-filter [display]=\"descriptor!.filterDisplay\" [descriptor]=\"col.filterDescriptor\"></mng-table-column-filter>\n </div>\n </th>\n <th *ngIf=\"showInlineActionsColumn\"></th>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"body\" let-item let-idx=\"rowIndex\">\n <tr [style.height.px]=\"rowHeight\" [class]=\"descriptor?.rowClassName | mngClassMapPipe: descriptor?.rowClassNameMapFn:item\">\n <td *ngIf=\"selectionEnabled && selectionMode === 'multiple'\" style=\"width: 3rem\">\n <p-tableCheckbox [value]=\"item\"></p-tableCheckbox>\n </td>\n <td *ngIf=\"selectionEnabled && selectionMode === 'single'\" style=\"width: 3rem\">\n <p-tableRadioButton [value]=\"item\"></p-tableRadioButton>\n </td>\n <td\n *ngFor=\"let col of descriptor?.columns\"\n (click)=\"onCellClick($event, col, item, idx)\"\n [class]=\"col.className\"\n [class.clickable]=\"isColumnClickable\"\n [style.width.%]=\"col.width\"\n [style.min-width.px]=\"col.minWidth\">\n <mng-table-column-value [descriptor]=\"col\" [item]=\"item\"></mng-table-column-value>\n </td>\n <td *ngIf=\"showInlineActionsColumn\" class=\"column-action text-right\" [style.min-width.px]=\"columnActionMinWidth\">\n <ng-container *ngIf=\"columnActionTemplate; else showColumnActionComponentOrDefault\">\n <ng-container *ngTemplateOutlet=\"columnActionTemplate; context: {rowItem: item, rowIndex: idx}\"></ng-container>\n </ng-container>\n <ng-template #showColumnActionComponentOrDefault>\n <span\n *ngIf=\"columnActionComponent; else defaultColumnActions\"\n [mngComponent]=\"columnActionComponent!\"\n (instanceCreated)=\"onColumnActionCmpInst($event)\"></span>\n </ng-template>\n <ng-template #defaultColumnActions>\n <mng-action\n *ngFor=\"let action of rowInlineActions\"\n [action]=\"action\"\n [item]=\"item\"\n [itemId]=\"descriptor?.model?.idPropertyName ? item[descriptor!.model!.idPropertyName!] : null\"\n [actionData]=\"{itemIndex: idx}\"\n (finish)=\"onActionFinish($event)\">\n </mng-action>\n </ng-template>\n </td>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"loadingbody\">\n <tr [style.height.px]=\"rowHeight\">\n <td [attr.colspan]=\"(descriptor?.columns?.length ?? 0) + (showInlineActionsColumn ? 1 : 0) + (selectionEnabled ? 1 : 0)\">\n <div class=\"loading-text\"></div>\n <p-skeleton [ngStyle]=\"{width: '100%'}\"></p-skeleton>\n </td>\n </tr>\n </ng-template>\n\n <ng-template pTemplate=\"emptymessage\">\n <tr [style.height.px]=\"rowHeight\">\n <td [attr.colspan]=\"(descriptor?.columns?.length ?? 0) + (showInlineActionsColumn ? 1 : 0) + (selectionEnabled ? 1 : 0)\">\n {{ 'mngTable.noItems' | translate }}\n </td>\n </tr>\n </ng-template>\n\n <ng-template *ngIf=\"footerTemplate\" pTemplate=\"summary\">\n <ng-container [ngTemplateOutlet]=\"footerTemplate\" [ngTemplateOutletContext]=\"{queryResult: queryResult}\"></ng-container>\n </ng-template>\n </p-table>\n</div>\n" }]
|
|
@@ -9847,8 +9883,7 @@ class MngTableviewComponent {
|
|
|
9847
9883
|
this.actionExecutor = actionExecutor;
|
|
9848
9884
|
this.viewContainerService = viewContainerService;
|
|
9849
9885
|
this.actions = [];
|
|
9850
|
-
this.
|
|
9851
|
-
this.rowInlineActions = [];
|
|
9886
|
+
this.tableActions = [];
|
|
9852
9887
|
this.toolbarLeftActions = [];
|
|
9853
9888
|
this.toolbarRightActions = [];
|
|
9854
9889
|
this.subscriptions = [];
|
|
@@ -9856,28 +9891,27 @@ class MngTableviewComponent {
|
|
|
9856
9891
|
this.selectedItems = [];
|
|
9857
9892
|
}
|
|
9858
9893
|
ngOnInit() {
|
|
9859
|
-
this.viewContainerService.
|
|
9894
|
+
this.viewContainerService.setActions(this.actions);
|
|
9860
9895
|
if (this.dataProvider) {
|
|
9861
9896
|
this.viewContainerService.dataProvider = this.dataProvider;
|
|
9862
9897
|
}
|
|
9863
|
-
const reloadTableSubscription = this.viewContainerService.
|
|
9898
|
+
const reloadTableSubscription = this.viewContainerService.getTableReload$().subscribe(() => {
|
|
9864
9899
|
this.reloadTable();
|
|
9865
9900
|
});
|
|
9866
9901
|
this.subscriptions.push(reloadTableSubscription);
|
|
9867
|
-
for (const action of this.actions) {
|
|
9902
|
+
for (const action of this.actions.filter(value => value.positionTableviewCategories?.includes(TableviewActionDefaultCategories.READ) ?? true)) {
|
|
9868
9903
|
switch (action.position) {
|
|
9869
|
-
case ActionPositionEnum.RowClick:
|
|
9870
|
-
this.rowClickActions.push(action);
|
|
9871
|
-
break;
|
|
9872
|
-
case ActionPositionEnum.RowInline:
|
|
9873
|
-
this.rowInlineActions.push(action);
|
|
9874
|
-
break;
|
|
9875
9904
|
case ActionPositionEnum.ToolbarLeft:
|
|
9876
9905
|
this.toolbarLeftActions.push(action);
|
|
9877
9906
|
break;
|
|
9878
9907
|
case ActionPositionEnum.ToolbarRight:
|
|
9879
9908
|
this.toolbarRightActions.push(action);
|
|
9880
9909
|
break;
|
|
9910
|
+
case ActionPositionEnum.TableHeader:
|
|
9911
|
+
case ActionPositionEnum.RowInline:
|
|
9912
|
+
case ActionPositionEnum.RowClick:
|
|
9913
|
+
this.tableActions.push(action);
|
|
9914
|
+
break;
|
|
9881
9915
|
}
|
|
9882
9916
|
}
|
|
9883
9917
|
this.toolbarRightActions = this.toolbarRightActions.reverse();
|
|
@@ -9901,6 +9935,9 @@ class MngTableviewComponent {
|
|
|
9901
9935
|
getDataProvider() {
|
|
9902
9936
|
return this.dataProvider;
|
|
9903
9937
|
}
|
|
9938
|
+
getActions() {
|
|
9939
|
+
return this.actions;
|
|
9940
|
+
}
|
|
9904
9941
|
reloadTable() {
|
|
9905
9942
|
this.tableComponent?.reload();
|
|
9906
9943
|
}
|
|
@@ -9912,10 +9949,10 @@ class MngTableviewComponent {
|
|
|
9912
9949
|
}
|
|
9913
9950
|
}
|
|
9914
9951
|
MngTableviewComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTableviewComponent, deps: [{ token: i1.ActivatedRoute }, { token: i2.MessageService }, { token: i1$2.TranslateService }, { token: i3.DialogService }, { token: i2.ConfirmationService }, { token: MngActionExecutorService }, { token: MngViewContainerComponentService }], target: i0.ɵɵFactoryTarget.Component });
|
|
9915
|
-
MngTableviewComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTableviewComponent, selector: "mng-tableview", inputs: { descriptor: "descriptor", dataProvider: "dataProvider", actions: "actions" }, providers: [MessageService, ConfirmationService, MngViewContainerComponentService], queries: [{ propertyName: "templates", predicate: MngTemplateDirective }], viewQueries: [{ propertyName: "tableComponent", first: true, predicate: MngTableComponent, descendants: true }], ngImport: i0, template: "<div class=\"mng-tableview\">\n <p-toast></p-toast>\n\n <div class=\"card\">\n <p-toolbar styleClass=\"mb-4\" *ngIf=\"toolbarLeftActions.length > 0 || toolbarRightActions.length > 0\">\n <ng-template pTemplate=\"left\">\n <mng-action *ngFor=\"let action of toolbarLeftActions\" [action]=\"action\" [queryParam]=\"tableQueryParam\" [selectedItems]=\"selectedItems\"></mng-action>\n </ng-template>\n\n <ng-template pTemplate=\"right\">\n <mng-action *ngFor=\"let action of toolbarRightActions\" [action]=\"action\" [queryParam]=\"tableQueryParam\" [selectedItems]=\"selectedItems\"></mng-action>\n </ng-template>\n </p-toolbar>\n\n <mng-table\n [descriptor]=\"descriptor.table\"\n [dataProvider]=\"dataProvider\"\n [useQueryParams]=\"true\"\n [actions]=\"
|
|
9952
|
+
MngTableviewComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTableviewComponent, selector: "mng-tableview", inputs: { descriptor: "descriptor", dataProvider: "dataProvider", actions: "actions" }, providers: [MessageService, ConfirmationService, MngViewContainerComponentService], queries: [{ propertyName: "templates", predicate: MngTemplateDirective }], viewQueries: [{ propertyName: "tableComponent", first: true, predicate: MngTableComponent, descendants: true }], ngImport: i0, template: "<div class=\"mng-tableview\">\n <p-toast></p-toast>\n\n <div class=\"card\">\n <p-toolbar styleClass=\"mb-4\" *ngIf=\"toolbarLeftActions.length > 0 || toolbarRightActions.length > 0\">\n <ng-template pTemplate=\"left\">\n <mng-action *ngFor=\"let action of toolbarLeftActions\" [action]=\"action\" [queryParam]=\"tableQueryParam\" [selectedItems]=\"selectedItems\"></mng-action>\n </ng-template>\n\n <ng-template pTemplate=\"right\">\n <mng-action *ngFor=\"let action of toolbarRightActions\" [action]=\"action\" [queryParam]=\"tableQueryParam\" [selectedItems]=\"selectedItems\"></mng-action>\n </ng-template>\n </p-toolbar>\n\n <mng-table\n [descriptor]=\"descriptor.table\"\n [dataProvider]=\"dataProvider\"\n [useQueryParams]=\"true\"\n [actions]=\"tableActions\"\n [selectionEnabled]=\"hasItemSelectionAction\"\n [selectionMode]=\"'multiple'\"\n (tableLoad)=\"onTableLoad($event)\"\n (selectionChange)=\"selectionChange($event)\">\n <ng-template mngTemplate=\"caption\">\n <div class=\"flex flex-column md:flex-row md:justify-content-between table-header\">\n <h5 class=\"p-0 m-0\">{{ descriptor.tableTitle ?? '' | translate }}</h5>\n </div>\n </ng-template>\n\n <ng-template let-queryResult=\"queryResult\" mngTemplate=\"footer\">\n <ng-container *ngIf=\"footerTemplate\" [ngTemplateOutlet]=\"footerTemplate\" [ngTemplateOutletContext]=\"{queryResult: queryResult}\"></ng-container>\n </ng-template>\n </mng-table>\n </div>\n\n <router-outlet></router-outlet>\n</div>\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.RouterOutlet, selector: "router-outlet", outputs: ["activate", "deactivate", "attach", "detach"], exportAs: ["outlet"] }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "component", type: i7$4.Toast, selector: "p-toast", inputs: ["key", "autoZIndex", "baseZIndex", "style", "styleClass", "position", "preventOpenDuplicates", "preventDuplicates", "showTransformOptions", "hideTransformOptions", "showTransitionOptions", "hideTransitionOptions", "breakpoints"], outputs: ["onClose"] }, { kind: "component", type: i6$1.Toolbar, selector: "p-toolbar", inputs: ["style", "styleClass"] }, { kind: "directive", type: MngTemplateDirective, selector: "[mngTemplate]", inputs: ["type", "mngTemplate"] }, { kind: "component", type: MngTableComponent, selector: "mng-table", inputs: ["descriptor", "items", "queryResult", "loading", "dataProvider", "useQueryParams", "selectionMode", "selectionEnabled", "actions", "isColumnClickable", "viewContainer", "captionComponent", "columnActionComponent", "columnActionMinWidth"], outputs: ["tableLoad", "cellClick", "selectionChange", "captionComponentInstance", "columnActionComponentInstance"] }, { kind: "component", type: MngActionComponent, selector: "mng-action", inputs: ["action", "item", "itemId", "actionData", "queryParam", "dataProvider", "disabled", "loading", "viewContainer", "selectedItems"], outputs: ["finish"] }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }] });
|
|
9916
9953
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTableviewComponent, decorators: [{
|
|
9917
9954
|
type: Component,
|
|
9918
|
-
args: [{ selector: 'mng-tableview', providers: [MessageService, ConfirmationService, MngViewContainerComponentService], template: "<div class=\"mng-tableview\">\n <p-toast></p-toast>\n\n <div class=\"card\">\n <p-toolbar styleClass=\"mb-4\" *ngIf=\"toolbarLeftActions.length > 0 || toolbarRightActions.length > 0\">\n <ng-template pTemplate=\"left\">\n <mng-action *ngFor=\"let action of toolbarLeftActions\" [action]=\"action\" [queryParam]=\"tableQueryParam\" [selectedItems]=\"selectedItems\"></mng-action>\n </ng-template>\n\n <ng-template pTemplate=\"right\">\n <mng-action *ngFor=\"let action of toolbarRightActions\" [action]=\"action\" [queryParam]=\"tableQueryParam\" [selectedItems]=\"selectedItems\"></mng-action>\n </ng-template>\n </p-toolbar>\n\n <mng-table\n [descriptor]=\"descriptor.table\"\n [dataProvider]=\"dataProvider\"\n [useQueryParams]=\"true\"\n [actions]=\"
|
|
9955
|
+
args: [{ selector: 'mng-tableview', providers: [MessageService, ConfirmationService, MngViewContainerComponentService], template: "<div class=\"mng-tableview\">\n <p-toast></p-toast>\n\n <div class=\"card\">\n <p-toolbar styleClass=\"mb-4\" *ngIf=\"toolbarLeftActions.length > 0 || toolbarRightActions.length > 0\">\n <ng-template pTemplate=\"left\">\n <mng-action *ngFor=\"let action of toolbarLeftActions\" [action]=\"action\" [queryParam]=\"tableQueryParam\" [selectedItems]=\"selectedItems\"></mng-action>\n </ng-template>\n\n <ng-template pTemplate=\"right\">\n <mng-action *ngFor=\"let action of toolbarRightActions\" [action]=\"action\" [queryParam]=\"tableQueryParam\" [selectedItems]=\"selectedItems\"></mng-action>\n </ng-template>\n </p-toolbar>\n\n <mng-table\n [descriptor]=\"descriptor.table\"\n [dataProvider]=\"dataProvider\"\n [useQueryParams]=\"true\"\n [actions]=\"tableActions\"\n [selectionEnabled]=\"hasItemSelectionAction\"\n [selectionMode]=\"'multiple'\"\n (tableLoad)=\"onTableLoad($event)\"\n (selectionChange)=\"selectionChange($event)\">\n <ng-template mngTemplate=\"caption\">\n <div class=\"flex flex-column md:flex-row md:justify-content-between table-header\">\n <h5 class=\"p-0 m-0\">{{ descriptor.tableTitle ?? '' | translate }}</h5>\n </div>\n </ng-template>\n\n <ng-template let-queryResult=\"queryResult\" mngTemplate=\"footer\">\n <ng-container *ngIf=\"footerTemplate\" [ngTemplateOutlet]=\"footerTemplate\" [ngTemplateOutletContext]=\"{queryResult: queryResult}\"></ng-container>\n </ng-template>\n </mng-table>\n </div>\n\n <router-outlet></router-outlet>\n</div>\n" }]
|
|
9919
9956
|
}], ctorParameters: function () { return [{ type: i1.ActivatedRoute }, { type: i2.MessageService }, { type: i1$2.TranslateService }, { type: i3.DialogService }, { type: i2.ConfirmationService }, { type: MngActionExecutorService }, { type: MngViewContainerComponentService }]; }, propDecorators: { descriptor: [{
|
|
9920
9957
|
type: Input
|
|
9921
9958
|
}], dataProvider: [{
|
|
@@ -9952,7 +9989,7 @@ class AMngTableviewRouteComponent {
|
|
|
9952
9989
|
this.createActionDescriptorForExport()
|
|
9953
9990
|
].filter(e => e != null);
|
|
9954
9991
|
}
|
|
9955
|
-
createActionDescriptorForDetails(descriptor = this.descriptor.
|
|
9992
|
+
createActionDescriptorForDetails(descriptor = this.descriptor.detailsEditor) {
|
|
9956
9993
|
return !this.routeData.tableviewActions || this.routeData.tableviewActions.hasDetails ? new ActionEditorDetailsDescriptor(descriptor) : null;
|
|
9957
9994
|
}
|
|
9958
9995
|
createActionDescriptorForAdd(descriptor = this.descriptor.addEditor) {
|
|
@@ -9984,10 +10021,10 @@ class AMngTableviewRouteComponent {
|
|
|
9984
10021
|
createActionDescriptorForRefresh(descriptor = this.descriptor.model) {
|
|
9985
10022
|
const action = new ActionDescriptor(descriptor, 'refresh')
|
|
9986
10023
|
.withPosition(ActionPositionEnum.ToolbarRight)
|
|
9987
|
-
.
|
|
10024
|
+
.withTableviewCategory(TableviewActionDefaultCategories.READ)
|
|
9988
10025
|
.withRunNotificationSuccess(undefined, undefined, false)
|
|
9989
10026
|
.withRunFunction((ctx) => {
|
|
9990
|
-
ctx.parameters.viewContainer
|
|
10027
|
+
ctx.parameters.viewContainer?.reloadTable?.({});
|
|
9991
10028
|
return of(null);
|
|
9992
10029
|
});
|
|
9993
10030
|
action.button.withIcon('pi pi-refresh').styleClass.withActionLevel(StyleLevelEnum.Secondary);
|
|
@@ -10199,19 +10236,18 @@ class MngFormlyFieldLookupDialogComponent extends FieldType {
|
|
|
10199
10236
|
}
|
|
10200
10237
|
}
|
|
10201
10238
|
MngFormlyFieldLookupDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormlyFieldLookupDialogComponent, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
10202
|
-
MngFormlyFieldLookupDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngFormlyFieldLookupDialogComponent, selector: "mng-formly-field-lookup-dialog", viewQueries: [{ propertyName: "mngTable", first: true, predicate: MngTableComponent, descendants: true }], usesInheritance: true, ngImport: i0, template: "<div [class]=\"'p-inputgroup mng-dropdown-dialog' + descriptor.inputClassName\" [class.p-inputtext-sm]=\"descriptor.isSizeSmall\" [class.p-inputtext-lg]=\"descriptor.isSizeLarge\">\n <input pInputText type=\"text\" [id]=\"$any(key)\" [readonly]=\"true\" [formlyAttributes]=\"field\" [formControl]=\"fieldLabelFormControl\" />\n <i class=\"mng-dropdown-clear-icon pi pi-times\" (click)=\"clear()\" *ngIf=\"!to.required && formControl?.value && !formControl?.disabled\"></i>\n <button\n pButton\n pRipple\n class=\"mng-dropdown-dialog-search-button\"\n type=\"button\"\n [label]=\"'general.search' | translate: {item: ''}\"\n [disabled]=\"formControl?.disabled\"\n (click)=\"openSelectDialog()\"></button>\n</div>\n\n<p-dialog\n [(visible)]=\"isDialogVisible\"\n [draggable]=\"false\"\n [header]=\"'general.search' | translate: {item: to?.label!}\"\n [modal]=\"true\"\n appendTo=\"body\"\n styleClass=\"p-fluid mng-formly-field-lookup-dialog\">\n <ng-template pTemplate=\"content\">\n <mng-table\n [descriptor]=\"descriptor.dialogTableDescriptor!\"\n [dataProvider]=\"descriptor.dialogTableDataProvider\"\n [queryResult]=\"addItemsAsync\"\n [selectionEnabled]=\"true\"\n [selectionMode]=\"'single'\"\n [loading]=\"dialogIsLoading$\"\n [captionComponent]=\"config?.table?.captionComponent\"\n [columnActionComponent]=\"config?.table?.columnActionComponent\"\n (selectionChange)=\"onSelectionChange($event)\"\n (captionComponentInstance)=\"onCaptionCmpInst($event)\"\n (columnActionComponentInstance)=\"onColumnActionCmpInst($event)\">\n </mng-table>\n <p-messages [value]=\"dialogMessages\"></p-messages>\n </ng-template>\n\n <ng-template pTemplate=\"footer\">\n <button pButton pRipple type=\"button\" [label]=\"'general.cancel' | translate\" icon=\"pi pi-times\" class=\"p-button-text\" (click)=\"hideDialog()\"></button>\n <button\n pButton\n pRipple\n type=\"button\"\n [label]=\"'general.select' | translate\"\n icon=\"pi pi-check\"\n class=\"p-button-text\"\n (click)=\"addItem()\"\n [loading]=\"(dialogIsLoading$ | async) ?? false\"\n [disabled]=\"form.disabled\"></button>\n </ng-template>\n</p-dialog>\n", dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2$2.ɵFormlyAttributes, selector: "[formlyAttributes]", inputs: ["formlyAttributes", "id"] }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i4$1.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { kind: "component", type: i6$
|
|
10239
|
+
MngFormlyFieldLookupDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngFormlyFieldLookupDialogComponent, selector: "mng-formly-field-lookup-dialog", viewQueries: [{ propertyName: "mngTable", first: true, predicate: MngTableComponent, descendants: true }], usesInheritance: true, ngImport: i0, template: "<div [class]=\"'p-inputgroup mng-dropdown-dialog' + descriptor.inputClassName\" [class.p-inputtext-sm]=\"descriptor.isSizeSmall\" [class.p-inputtext-lg]=\"descriptor.isSizeLarge\">\n <input pInputText type=\"text\" [id]=\"$any(key)\" [readonly]=\"true\" [formlyAttributes]=\"field\" [formControl]=\"fieldLabelFormControl\" />\n <i class=\"mng-dropdown-clear-icon pi pi-times\" (click)=\"clear()\" *ngIf=\"!to.required && formControl?.value && !formControl?.disabled\"></i>\n <button\n pButton\n pRipple\n class=\"mng-dropdown-dialog-search-button\"\n type=\"button\"\n [label]=\"'general.search' | translate: {item: ''}\"\n [disabled]=\"formControl?.disabled\"\n (click)=\"openSelectDialog()\"></button>\n</div>\n\n<p-dialog\n [(visible)]=\"isDialogVisible\"\n [draggable]=\"false\"\n [header]=\"'general.search' | translate: {item: to?.label!}\"\n [modal]=\"true\"\n appendTo=\"body\"\n styleClass=\"p-fluid mng-dialog mng-formly-field-lookup-dialog\">\n <ng-template pTemplate=\"content\">\n <mng-table\n [descriptor]=\"descriptor.dialogTableDescriptor!\"\n [dataProvider]=\"descriptor.dialogTableDataProvider\"\n [queryResult]=\"addItemsAsync\"\n [selectionEnabled]=\"true\"\n [selectionMode]=\"'single'\"\n [loading]=\"dialogIsLoading$\"\n [captionComponent]=\"config?.table?.captionComponent\"\n [columnActionComponent]=\"config?.table?.columnActionComponent\"\n (selectionChange)=\"onSelectionChange($event)\"\n (captionComponentInstance)=\"onCaptionCmpInst($event)\"\n (columnActionComponentInstance)=\"onColumnActionCmpInst($event)\">\n </mng-table>\n <p-messages [value]=\"dialogMessages\"></p-messages>\n </ng-template>\n\n <ng-template pTemplate=\"footer\">\n <button pButton pRipple type=\"button\" [label]=\"'general.cancel' | translate\" icon=\"pi pi-times\" class=\"p-button-text\" (click)=\"hideDialog()\"></button>\n <button\n pButton\n pRipple\n type=\"button\"\n [label]=\"'general.select' | translate\"\n icon=\"pi pi-check\"\n class=\"p-button-text\"\n (click)=\"addItem()\"\n [loading]=\"(dialogIsLoading$ | async) ?? false\"\n [disabled]=\"form.disabled\"></button>\n </ng-template>\n</p-dialog>\n", dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i2$2.ɵFormlyAttributes, selector: "[formlyAttributes]", inputs: ["formlyAttributes", "id"] }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i4$1.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { kind: "component", type: i6$4.Dialog, selector: "p-dialog", inputs: ["header", "draggable", "resizable", "positionLeft", "positionTop", "contentStyle", "contentStyleClass", "modal", "closeOnEscape", "dismissableMask", "rtl", "closable", "responsive", "appendTo", "breakpoints", "styleClass", "maskStyleClass", "showHeader", "breakpoint", "blockScroll", "autoZIndex", "baseZIndex", "minX", "minY", "focusOnShow", "maximizable", "keepInViewport", "focusTrap", "transitionOptions", "closeIcon", "closeAriaLabel", "closeTabindex", "minimizeIcon", "maximizeIcon", "visible", "style", "position"], outputs: ["onShow", "onHide", "visibleChange", "onResizeInit", "onResizeEnd", "onDragEnd", "onMaximize"] }, { kind: "component", type: i5$1.Messages, selector: "p-messages", inputs: ["value", "closable", "style", "styleClass", "enableService", "key", "escape", "severity", "showTransitionOptions", "hideTransitionOptions"], outputs: ["valueChange"] }, { kind: "directive", type: i9$1.InputText, selector: "[pInputText]" }, { kind: "directive", type: i5.Ripple, selector: "[pRipple]" }, { kind: "component", type: MngTableComponent, selector: "mng-table", inputs: ["descriptor", "items", "queryResult", "loading", "dataProvider", "useQueryParams", "selectionMode", "selectionEnabled", "actions", "isColumnClickable", "viewContainer", "captionComponent", "columnActionComponent", "columnActionMinWidth"], outputs: ["tableLoad", "cellClick", "selectionChange", "captionComponentInstance", "columnActionComponentInstance"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
10203
10240
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormlyFieldLookupDialogComponent, decorators: [{
|
|
10204
10241
|
type: Component,
|
|
10205
|
-
args: [{ selector: 'mng-formly-field-lookup-dialog', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div [class]=\"'p-inputgroup mng-dropdown-dialog' + descriptor.inputClassName\" [class.p-inputtext-sm]=\"descriptor.isSizeSmall\" [class.p-inputtext-lg]=\"descriptor.isSizeLarge\">\n <input pInputText type=\"text\" [id]=\"$any(key)\" [readonly]=\"true\" [formlyAttributes]=\"field\" [formControl]=\"fieldLabelFormControl\" />\n <i class=\"mng-dropdown-clear-icon pi pi-times\" (click)=\"clear()\" *ngIf=\"!to.required && formControl?.value && !formControl?.disabled\"></i>\n <button\n pButton\n pRipple\n class=\"mng-dropdown-dialog-search-button\"\n type=\"button\"\n [label]=\"'general.search' | translate: {item: ''}\"\n [disabled]=\"formControl?.disabled\"\n (click)=\"openSelectDialog()\"></button>\n</div>\n\n<p-dialog\n [(visible)]=\"isDialogVisible\"\n [draggable]=\"false\"\n [header]=\"'general.search' | translate: {item: to?.label!}\"\n [modal]=\"true\"\n appendTo=\"body\"\n styleClass=\"p-fluid mng-formly-field-lookup-dialog\">\n <ng-template pTemplate=\"content\">\n <mng-table\n [descriptor]=\"descriptor.dialogTableDescriptor!\"\n [dataProvider]=\"descriptor.dialogTableDataProvider\"\n [queryResult]=\"addItemsAsync\"\n [selectionEnabled]=\"true\"\n [selectionMode]=\"'single'\"\n [loading]=\"dialogIsLoading$\"\n [captionComponent]=\"config?.table?.captionComponent\"\n [columnActionComponent]=\"config?.table?.columnActionComponent\"\n (selectionChange)=\"onSelectionChange($event)\"\n (captionComponentInstance)=\"onCaptionCmpInst($event)\"\n (columnActionComponentInstance)=\"onColumnActionCmpInst($event)\">\n </mng-table>\n <p-messages [value]=\"dialogMessages\"></p-messages>\n </ng-template>\n\n <ng-template pTemplate=\"footer\">\n <button pButton pRipple type=\"button\" [label]=\"'general.cancel' | translate\" icon=\"pi pi-times\" class=\"p-button-text\" (click)=\"hideDialog()\"></button>\n <button\n pButton\n pRipple\n type=\"button\"\n [label]=\"'general.select' | translate\"\n icon=\"pi pi-check\"\n class=\"p-button-text\"\n (click)=\"addItem()\"\n [loading]=\"(dialogIsLoading$ | async) ?? false\"\n [disabled]=\"form.disabled\"></button>\n </ng-template>\n</p-dialog>\n" }]
|
|
10242
|
+
args: [{ selector: 'mng-formly-field-lookup-dialog', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div [class]=\"'p-inputgroup mng-dropdown-dialog' + descriptor.inputClassName\" [class.p-inputtext-sm]=\"descriptor.isSizeSmall\" [class.p-inputtext-lg]=\"descriptor.isSizeLarge\">\n <input pInputText type=\"text\" [id]=\"$any(key)\" [readonly]=\"true\" [formlyAttributes]=\"field\" [formControl]=\"fieldLabelFormControl\" />\n <i class=\"mng-dropdown-clear-icon pi pi-times\" (click)=\"clear()\" *ngIf=\"!to.required && formControl?.value && !formControl?.disabled\"></i>\n <button\n pButton\n pRipple\n class=\"mng-dropdown-dialog-search-button\"\n type=\"button\"\n [label]=\"'general.search' | translate: {item: ''}\"\n [disabled]=\"formControl?.disabled\"\n (click)=\"openSelectDialog()\"></button>\n</div>\n\n<p-dialog\n [(visible)]=\"isDialogVisible\"\n [draggable]=\"false\"\n [header]=\"'general.search' | translate: {item: to?.label!}\"\n [modal]=\"true\"\n appendTo=\"body\"\n styleClass=\"p-fluid mng-dialog mng-formly-field-lookup-dialog\">\n <ng-template pTemplate=\"content\">\n <mng-table\n [descriptor]=\"descriptor.dialogTableDescriptor!\"\n [dataProvider]=\"descriptor.dialogTableDataProvider\"\n [queryResult]=\"addItemsAsync\"\n [selectionEnabled]=\"true\"\n [selectionMode]=\"'single'\"\n [loading]=\"dialogIsLoading$\"\n [captionComponent]=\"config?.table?.captionComponent\"\n [columnActionComponent]=\"config?.table?.columnActionComponent\"\n (selectionChange)=\"onSelectionChange($event)\"\n (captionComponentInstance)=\"onCaptionCmpInst($event)\"\n (columnActionComponentInstance)=\"onColumnActionCmpInst($event)\">\n </mng-table>\n <p-messages [value]=\"dialogMessages\"></p-messages>\n </ng-template>\n\n <ng-template pTemplate=\"footer\">\n <button pButton pRipple type=\"button\" [label]=\"'general.cancel' | translate\" icon=\"pi pi-times\" class=\"p-button-text\" (click)=\"hideDialog()\"></button>\n <button\n pButton\n pRipple\n type=\"button\"\n [label]=\"'general.select' | translate\"\n icon=\"pi pi-check\"\n class=\"p-button-text\"\n (click)=\"addItem()\"\n [loading]=\"(dialogIsLoading$ | async) ?? false\"\n [disabled]=\"form.disabled\"></button>\n </ng-template>\n</p-dialog>\n" }]
|
|
10206
10243
|
}], ctorParameters: function () { return [{ type: i0.Injector }]; }, propDecorators: { mngTable: [{
|
|
10207
10244
|
type: ViewChild,
|
|
10208
10245
|
args: [MngTableComponent]
|
|
10209
10246
|
}] } });
|
|
10210
10247
|
|
|
10211
10248
|
class MngFormlyFieldTableDialogFormComponent extends FieldType {
|
|
10212
|
-
constructor(
|
|
10213
|
-
super();
|
|
10214
|
-
this.actionExecutor = actionExecutor;
|
|
10249
|
+
constructor() {
|
|
10250
|
+
super(...arguments);
|
|
10215
10251
|
this.itemsSubject = new ReplaySubject(1);
|
|
10216
10252
|
this.items$ = this.itemsSubject.asObservable();
|
|
10217
10253
|
this.actions = [];
|
|
@@ -10221,15 +10257,14 @@ class MngFormlyFieldTableDialogFormComponent extends FieldType {
|
|
|
10221
10257
|
this.isEnabled$ = this.isDisabledSubject.asObservable().pipe(distinctUntilChanged(), map(e => !e));
|
|
10222
10258
|
}
|
|
10223
10259
|
ngOnInit() {
|
|
10224
|
-
this.descriptor = this.
|
|
10260
|
+
this.descriptor = this.props['descriptor'];
|
|
10225
10261
|
const hasViewAction = this.descriptor.fieldActions.some(a => a === FieldManyEditorActionEnum.View);
|
|
10226
10262
|
const hasAddAction = this.descriptor.fieldActions.some(a => a === FieldManyEditorActionEnum.Add);
|
|
10227
10263
|
const hasEditAction = this.descriptor.fieldActions.some(a => a === FieldManyEditorActionEnum.Edit);
|
|
10228
10264
|
const hasDeleteAction = this.descriptor.fieldActions.some(a => a === FieldManyEditorActionEnum.Delete);
|
|
10229
10265
|
if (hasViewAction) {
|
|
10230
|
-
const viewAction = new ActionEditorDescriptor(this.descriptor.tableviewDescriptor.
|
|
10266
|
+
const viewAction = new ActionEditorDescriptor(this.descriptor.tableviewDescriptor.detailsEditor, 'details', this.descriptor.editor.model.type, this.descriptor.property)
|
|
10231
10267
|
.withPosition(ActionPositionEnum.RowClick)
|
|
10232
|
-
.withDialogClassName('mng-field-dialog mng-action-editor-dialog')
|
|
10233
10268
|
.withDialogSize(StyleSizeEnum.Small);
|
|
10234
10269
|
viewAction.withEditorActions([new ActionEditorSubmitDescriptor(viewAction, ActionEditorSubmitTypeEnum.Cancel)]);
|
|
10235
10270
|
viewAction.button.withLabel(null);
|
|
@@ -10238,7 +10273,6 @@ class MngFormlyFieldTableDialogFormComponent extends FieldType {
|
|
|
10238
10273
|
if (hasAddAction) {
|
|
10239
10274
|
const addAction = new ActionEditorDescriptor(this.descriptor.tableviewDescriptor.addEditor, 'add', this.descriptor.editor.model.type, this.descriptor.property)
|
|
10240
10275
|
.withPosition(ActionPositionEnum.ToolbarRight)
|
|
10241
|
-
.withDialogClassName('mng-field-dialog mng-action-editor-dialog')
|
|
10242
10276
|
.withDialogSize(StyleSizeEnum.Small)
|
|
10243
10277
|
.withButtonDescriptor(new ActionButtonDescriptor().withStyleClass(new ButtonStyleBuilder().withSize(StyleSizeEnum.ExtraSmall)))
|
|
10244
10278
|
.withSubmitFunction(ctx => {
|
|
@@ -10259,7 +10293,6 @@ class MngFormlyFieldTableDialogFormComponent extends FieldType {
|
|
|
10259
10293
|
if (hasEditAction) {
|
|
10260
10294
|
const editAction = new ActionEditorDescriptor(this.descriptor.tableviewDescriptor.editEditor, 'edit', this.descriptor.editor.model.type, this.descriptor.property)
|
|
10261
10295
|
.withPosition(ActionPositionEnum.RowInline)
|
|
10262
|
-
.withDialogClassName('mng-field-dialog mng-action-editor-dialog')
|
|
10263
10296
|
.withDialogSize(StyleSizeEnum.Small)
|
|
10264
10297
|
.withButtonDescriptor(new ActionButtonDescriptor().withStyleClass(new ButtonStyleBuilder().withSize(StyleSizeEnum.ExtraSmall)))
|
|
10265
10298
|
.withSubmitFunction(ctx => {
|
|
@@ -10357,12 +10390,12 @@ class MngFormlyFieldTableDialogFormComponent extends FieldType {
|
|
|
10357
10390
|
});
|
|
10358
10391
|
}
|
|
10359
10392
|
}
|
|
10360
|
-
MngFormlyFieldTableDialogFormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormlyFieldTableDialogFormComponent, deps:
|
|
10393
|
+
MngFormlyFieldTableDialogFormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormlyFieldTableDialogFormComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
|
|
10361
10394
|
MngFormlyFieldTableDialogFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngFormlyFieldTableDialogFormComponent, selector: "mng-formly-table-dialog-form-field", usesInheritance: true, ngImport: i0, template: "<mng-table [descriptor]=\"descriptor.tableDescriptor\" [items]=\"items$\" [actions]=\"actions\">\n <ng-template mngTemplate=\"caption\">\n <div class=\"flex flex-column md:flex-row md:justify-content-end align-items-center table-header\">\n <label class=\"mng-datatable-form-label p-0 m-0\" [for]=\"key\">{{ to?.label! | translate }} <span *ngIf=\"to.required && to['hideRequiredMarker'] !== true\">*</span></label>\n <mng-action *ngFor=\"let action of toolbarRightActions\" [action]=\"action\"></mng-action>\n </div>\n </ng-template>\n</mng-table>\n", styles: [".submit-button{display:none!important;visibility:hidden}\n"], dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: MngTemplateDirective, selector: "[mngTemplate]", inputs: ["type", "mngTemplate"] }, { kind: "component", type: MngTableComponent, selector: "mng-table", inputs: ["descriptor", "items", "queryResult", "loading", "dataProvider", "useQueryParams", "selectionMode", "selectionEnabled", "actions", "isColumnClickable", "viewContainer", "captionComponent", "columnActionComponent", "columnActionMinWidth"], outputs: ["tableLoad", "cellClick", "selectionChange", "captionComponentInstance", "columnActionComponentInstance"] }, { kind: "component", type: MngActionComponent, selector: "mng-action", inputs: ["action", "item", "itemId", "actionData", "queryParam", "dataProvider", "disabled", "loading", "viewContainer", "selectedItems"], outputs: ["finish"] }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
10362
10395
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormlyFieldTableDialogFormComponent, decorators: [{
|
|
10363
10396
|
type: Component,
|
|
10364
10397
|
args: [{ selector: 'mng-formly-table-dialog-form-field', changeDetection: ChangeDetectionStrategy.OnPush, template: "<mng-table [descriptor]=\"descriptor.tableDescriptor\" [items]=\"items$\" [actions]=\"actions\">\n <ng-template mngTemplate=\"caption\">\n <div class=\"flex flex-column md:flex-row md:justify-content-end align-items-center table-header\">\n <label class=\"mng-datatable-form-label p-0 m-0\" [for]=\"key\">{{ to?.label! | translate }} <span *ngIf=\"to.required && to['hideRequiredMarker'] !== true\">*</span></label>\n <mng-action *ngFor=\"let action of toolbarRightActions\" [action]=\"action\"></mng-action>\n </div>\n </ng-template>\n</mng-table>\n", styles: [".submit-button{display:none!important;visibility:hidden}\n"] }]
|
|
10365
|
-
}]
|
|
10398
|
+
}] });
|
|
10366
10399
|
|
|
10367
10400
|
class MngFormlyFieldTableDialogMultiselectComponent extends FieldType {
|
|
10368
10401
|
constructor(injector) {
|
|
@@ -10378,7 +10411,6 @@ class MngFormlyFieldTableDialogMultiselectComponent extends FieldType {
|
|
|
10378
10411
|
this.isDialogVisible = false;
|
|
10379
10412
|
this.dialogAreItemsLoaded = false;
|
|
10380
10413
|
this.dialogSelectedAddItems = [];
|
|
10381
|
-
this.dialogMessages = [];
|
|
10382
10414
|
this.dialogIsLoading$ = this.dialogIsLoadingSubject.asObservable();
|
|
10383
10415
|
this.hasAddAction = false;
|
|
10384
10416
|
this.hasDeleteAction = false;
|
|
@@ -10491,10 +10523,10 @@ class MngFormlyFieldTableDialogMultiselectComponent extends FieldType {
|
|
|
10491
10523
|
}
|
|
10492
10524
|
}
|
|
10493
10525
|
MngFormlyFieldTableDialogMultiselectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormlyFieldTableDialogMultiselectComponent, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
10494
|
-
MngFormlyFieldTableDialogMultiselectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngFormlyFieldTableDialogMultiselectComponent, selector: "mng-formly-table-multiselect-add-field", usesInheritance: true, ngImport: i0, template: "<mng-table [descriptor]=\"descriptor.mainTableDescriptor\" [items]=\"itemsAsync\">\n <ng-template mngTemplate=\"caption\">\n <div class=\"flex flex-column md:flex-row md:justify-content-end align-items-center table-header pt-0\">\n <label class=\"mng-datatable-form-label p-0 m-0\" [for]=\"key\">{{ to?.label! | translate }} <span *ngIf=\"to.required && to['hideRequiredMarker'] !== true\">*</span></label>\n <button\n *ngIf=\"hasAddAction && !options?.formState?.disabled\"\n pButton\n pRipple\n type=\"button\"\n icon=\"pi pi-plus\"\n class=\"p-button-rounded
|
|
10526
|
+
MngFormlyFieldTableDialogMultiselectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngFormlyFieldTableDialogMultiselectComponent, selector: "mng-formly-table-multiselect-add-field", usesInheritance: true, ngImport: i0, template: "<mng-table [descriptor]=\"descriptor.mainTableDescriptor\" [items]=\"itemsAsync\">\n <ng-template mngTemplate=\"caption\">\n <div class=\"flex flex-column md:flex-row md:justify-content-end align-items-center table-header pt-0\">\n <label class=\"mng-datatable-form-label p-0 m-0\" [for]=\"key\">{{ to?.label! | translate }} <span *ngIf=\"to.required && to['hideRequiredMarker'] !== true\">*</span></label>\n <button\n *ngIf=\"hasAddAction && !options?.formState?.disabled\"\n pButton\n pRipple\n type=\"button\"\n icon=\"pi pi-plus\"\n class=\"p-button-rounded mng-button-xs\"\n (click)=\"openAddDialog()\"\n [disabled]=\"formControl!.disabled\"></button>\n </div>\n </ng-template>\n <ng-template mngTemplate=\"columnAction\" let-item=\"rowItem\">\n <button\n *ngIf=\"hasDeleteAction && !options?.formState?.disabled\"\n pButton\n pRipple\n type=\"button\"\n icon=\"pi pi-trash\"\n class=\"p-button-rounded p-button-danger mng-button-xs\"\n (click)=\"removeItem(item)\"\n [disabled]=\"formControl!.disabled\"></button>\n </ng-template>\n</mng-table>\n\n<p-dialog\n *ngIf=\"hasAddAction\"\n [(visible)]=\"isDialogVisible\"\n [draggable]=\"false\"\n [header]=\"'general.addItem' | translate: {item: to?.label! | translate}\"\n [modal]=\"true\"\n appendTo=\"body\"\n styleClass=\"p-fluid mng-dialog mng-dialog-sm mng-formly-field-table-multiselect-dialog\">\n <ng-template pTemplate=\"content\" class=\"table-container\">\n <div class=\"mng-formly-field-table-multiselect-dialog-table table-scroll\">\n <mng-table\n [descriptor]=\"descriptor.mainTableDescriptor\"\n [queryResult]=\"addItemsAsync\"\n [selectionEnabled]=\"true\"\n [loading]=\"dialogIsLoading$\"\n (selectionChange)=\"onSelectionChange($event)\">\n </mng-table>\n </div>\n\n <div class=\"flex flex-row justify-content-end mng-formly-field-table-multiselect-dialog-footer\">\n <button pButton pRipple type=\"button\" [label]=\"'general.cancel' | translate\" icon=\"pi pi-times\" class=\"p-button-text\" (click)=\"hideDialog()\"></button>\n <button\n pButton\n pRipple\n type=\"button\"\n [label]=\"'general.add' | translate\"\n icon=\"pi pi-check\"\n class=\"p-button-primary\"\n (click)=\"addItems()\"\n [loading]=\"(dialogIsLoading$ | async) ?? false\"\n [disabled]=\"form.disabled\"></button>\n </div>\n </ng-template>\n</p-dialog>\n", styles: [".table-footer{display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:flex-end;align-items:center;align-content:center;margin-top:2rem}.table-container{overflow:hidden}.table-footer button{width:8rem}.table-footer button:not(:first-child){margin-left:1.5rem}.table-scroll{max-height:75vh;overflow-y:auto}\n"], dependencies: [{ kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.PrimeTemplate, selector: "[pTemplate]", inputs: ["type", "pTemplate"] }, { kind: "directive", type: i4$1.ButtonDirective, selector: "[pButton]", inputs: ["iconPos", "loadingIcon", "label", "icon", "loading"] }, { kind: "component", type: i6$4.Dialog, selector: "p-dialog", inputs: ["header", "draggable", "resizable", "positionLeft", "positionTop", "contentStyle", "contentStyleClass", "modal", "closeOnEscape", "dismissableMask", "rtl", "closable", "responsive", "appendTo", "breakpoints", "styleClass", "maskStyleClass", "showHeader", "breakpoint", "blockScroll", "autoZIndex", "baseZIndex", "minX", "minY", "focusOnShow", "maximizable", "keepInViewport", "focusTrap", "transitionOptions", "closeIcon", "closeAriaLabel", "closeTabindex", "minimizeIcon", "maximizeIcon", "visible", "style", "position"], outputs: ["onShow", "onHide", "visibleChange", "onResizeInit", "onResizeEnd", "onDragEnd", "onMaximize"] }, { kind: "directive", type: i5.Ripple, selector: "[pRipple]" }, { kind: "directive", type: MngTemplateDirective, selector: "[mngTemplate]", inputs: ["type", "mngTemplate"] }, { kind: "component", type: MngTableComponent, selector: "mng-table", inputs: ["descriptor", "items", "queryResult", "loading", "dataProvider", "useQueryParams", "selectionMode", "selectionEnabled", "actions", "isColumnClickable", "viewContainer", "captionComponent", "columnActionComponent", "columnActionMinWidth"], outputs: ["tableLoad", "cellClick", "selectionChange", "captionComponentInstance", "columnActionComponentInstance"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
10495
10527
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngFormlyFieldTableDialogMultiselectComponent, decorators: [{
|
|
10496
10528
|
type: Component,
|
|
10497
|
-
args: [{ selector: 'mng-formly-table-multiselect-add-field', changeDetection: ChangeDetectionStrategy.OnPush, template: "<mng-table [descriptor]=\"descriptor.mainTableDescriptor\" [items]=\"itemsAsync\">\n <ng-template mngTemplate=\"caption\">\n <div class=\"flex flex-column md:flex-row md:justify-content-end align-items-center table-header pt-0\">\n <label class=\"mng-datatable-form-label p-0 m-0\" [for]=\"key\">{{ to?.label! | translate }} <span *ngIf=\"to.required && to['hideRequiredMarker'] !== true\">*</span></label>\n <button\n *ngIf=\"hasAddAction && !options?.formState?.disabled\"\n pButton\n pRipple\n type=\"button\"\n icon=\"pi pi-plus\"\n class=\"p-button-rounded
|
|
10529
|
+
args: [{ selector: 'mng-formly-table-multiselect-add-field', changeDetection: ChangeDetectionStrategy.OnPush, template: "<mng-table [descriptor]=\"descriptor.mainTableDescriptor\" [items]=\"itemsAsync\">\n <ng-template mngTemplate=\"caption\">\n <div class=\"flex flex-column md:flex-row md:justify-content-end align-items-center table-header pt-0\">\n <label class=\"mng-datatable-form-label p-0 m-0\" [for]=\"key\">{{ to?.label! | translate }} <span *ngIf=\"to.required && to['hideRequiredMarker'] !== true\">*</span></label>\n <button\n *ngIf=\"hasAddAction && !options?.formState?.disabled\"\n pButton\n pRipple\n type=\"button\"\n icon=\"pi pi-plus\"\n class=\"p-button-rounded mng-button-xs\"\n (click)=\"openAddDialog()\"\n [disabled]=\"formControl!.disabled\"></button>\n </div>\n </ng-template>\n <ng-template mngTemplate=\"columnAction\" let-item=\"rowItem\">\n <button\n *ngIf=\"hasDeleteAction && !options?.formState?.disabled\"\n pButton\n pRipple\n type=\"button\"\n icon=\"pi pi-trash\"\n class=\"p-button-rounded p-button-danger mng-button-xs\"\n (click)=\"removeItem(item)\"\n [disabled]=\"formControl!.disabled\"></button>\n </ng-template>\n</mng-table>\n\n<p-dialog\n *ngIf=\"hasAddAction\"\n [(visible)]=\"isDialogVisible\"\n [draggable]=\"false\"\n [header]=\"'general.addItem' | translate: {item: to?.label! | translate}\"\n [modal]=\"true\"\n appendTo=\"body\"\n styleClass=\"p-fluid mng-dialog mng-dialog-sm mng-formly-field-table-multiselect-dialog\">\n <ng-template pTemplate=\"content\" class=\"table-container\">\n <div class=\"mng-formly-field-table-multiselect-dialog-table table-scroll\">\n <mng-table\n [descriptor]=\"descriptor.mainTableDescriptor\"\n [queryResult]=\"addItemsAsync\"\n [selectionEnabled]=\"true\"\n [loading]=\"dialogIsLoading$\"\n (selectionChange)=\"onSelectionChange($event)\">\n </mng-table>\n </div>\n\n <div class=\"flex flex-row justify-content-end mng-formly-field-table-multiselect-dialog-footer\">\n <button pButton pRipple type=\"button\" [label]=\"'general.cancel' | translate\" icon=\"pi pi-times\" class=\"p-button-text\" (click)=\"hideDialog()\"></button>\n <button\n pButton\n pRipple\n type=\"button\"\n [label]=\"'general.add' | translate\"\n icon=\"pi pi-check\"\n class=\"p-button-primary\"\n (click)=\"addItems()\"\n [loading]=\"(dialogIsLoading$ | async) ?? false\"\n [disabled]=\"form.disabled\"></button>\n </div>\n </ng-template>\n</p-dialog>\n", styles: [".table-footer{display:flex;flex-direction:row;flex-wrap:nowrap;justify-content:flex-end;align-items:center;align-content:center;margin-top:2rem}.table-container{overflow:hidden}.table-footer button{width:8rem}.table-footer button:not(:first-child){margin-left:1.5rem}.table-scroll{max-height:75vh;overflow-y:auto}\n"] }]
|
|
10498
10530
|
}], ctorParameters: function () { return [{ type: i0.Injector }]; } });
|
|
10499
10531
|
|
|
10500
10532
|
class MngFormlyFieldTabsComponent extends FieldType {
|
|
@@ -10896,7 +10928,7 @@ class MngMenuItemComponent {
|
|
|
10896
10928
|
}
|
|
10897
10929
|
}
|
|
10898
10930
|
MngMenuItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngMenuItemComponent, deps: [{ token: i0.Injector }, { token: i1.Router }, { token: i1.ActivatedRoute }, { token: MngAuthorizationService }, { token: MngCommonsService }, { token: MngMainLayoutComponentService }], target: i0.ɵɵFactoryTarget.Component });
|
|
10899
|
-
MngMenuItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngMenuItemComponent, selector: "[mng-menuitem]", inputs: { item: "item", index: "index", root: "root", parentKey: "parentKey" }, host: { properties: { "class.layout-root-menuitem": "root", "class.active-menuitem": "active", "class.py-0": "this.hostClassNoPadding" } }, ngImport: i0, template: "<ng-container>\n <div *ngIf=\"root && item.visible !== false && (guardsIsAllowed$ | async) === true && (isPermitted$ | async) === true\" class=\"layout-menuitem-root-text\">\n {{ item.label! | translate }}\n </div>\n <a\n *ngIf=\"(!item.routerLink || item.items) && item.visible !== false && (guardsIsAllowed$ | async) === true && (isPermitted$ | async) === true\"\n [attr.href]=\"item.href\"\n (click)=\"itemClick($event)\"\n (mouseenter)=\"onMouseEnter()\"\n (keydown.enter)=\"itemClick($event)\"\n [routerLink]=\"item.routerLink\"\n [attr.target]=\"item.target\"\n [attr.tabindex]=\"0\"\n [ngClass]=\"item.className ?? ''\"\n pRipple>\n <i [ngClass]=\"item.icon ?? ''\" class=\"layout-menuitem-icon\"></i>\n <span class=\"layout-menuitem-text\">{{ item.label! | translate }}</span>\n <i class=\"pi pi-fw pi-angle-down layout-submenu-toggler\" *ngIf=\"item.items\"></i>\n <span class=\"menuitem-badge\" *ngIf=\"item.badge\">{{ item.badge }}</span>\n </a>\n <a\n *ngIf=\"item.routerLink && !item.items && item.visible !== false && (guardsIsAllowed$ | async) === true && (isPermitted$ | async) === true\"\n (click)=\"itemClick($event)\"\n (mouseenter)=\"hover = true\"\n (mouseleave)=\"hover = false\"\n [routerLink]=\"item.routerLink\"\n routerLinkActive=\"active-menuitem-routerlink\"\n [routerLinkActiveOptions]=\"{exact: true}\"\n [attr.target]=\"item.target\"\n [attr.tabindex]=\"0\"\n [ngClass]=\"item.className ?? ''\"\n pRipple>\n <i [ngClass]=\"item.icon ?? ''\" class=\"layout-menuitem-icon\"></i>\n <span class=\"layout-menuitem-text\">{{ item.label! | translate }}</span>\n <i class=\"pi pi-fw pi-angle-down layout-submenu-toggler\" *ngIf=\"item.items\"></i>\n <span class=\"menuitem-badge\" *ngIf=\"item.badge\">{{ item.badge }}</span>\n </a>\n <ul\n *ngIf=\"\n ((item.items && active) || (item.items && (mngCommons.menuModeIsStatic$ | async) && (root || active))) &&\n item.visible !== false &&\n (guardsIsAllowed$ | async) === true &&\n (isPermitted$ | async) === true\n \"\n [@children]=\"\n (mngCommons.menuModeIsSlim$ | async) && (mainLayoutService.isMobile$ | async) === false && root\n ? active\n ? 'visible'\n : 'hidden'\n : (mngCommons.menuModeIsStatic$ | async) && root && (mainLayoutService.isMobile$ | async) === false\n ? 'visible'\n : active\n ? 'visibleAnimated'\n : 'hiddenAnimated'\n \">\n <ng-template ngFor let-child let-i=\"index\" [ngForOf]=\"item.items\">\n <li mng-menuitem [item]=\"child\" [index]=\"i\" [parentKey]=\"key\" [class]=\"child.badgeClassName\"></li>\n </ng-template>\n </ul>\n</ng-container>\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i1.RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "directive", type:
|
|
10931
|
+
MngMenuItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngMenuItemComponent, selector: "[mng-menuitem]", inputs: { item: "item", index: "index", root: "root", parentKey: "parentKey" }, host: { properties: { "class.layout-root-menuitem": "root", "class.active-menuitem": "active", "class.py-0": "this.hostClassNoPadding" } }, ngImport: i0, template: "<ng-container>\n <div *ngIf=\"root && item.visible !== false && (guardsIsAllowed$ | async) === true && (isPermitted$ | async) === true\" class=\"layout-menuitem-root-text\">\n {{ item.label! | translate }}\n </div>\n <a\n *ngIf=\"(!item.routerLink || item.items) && item.visible !== false && (guardsIsAllowed$ | async) === true && (isPermitted$ | async) === true\"\n [attr.href]=\"item.href\"\n (click)=\"itemClick($event)\"\n (mouseenter)=\"onMouseEnter()\"\n (keydown.enter)=\"itemClick($event)\"\n [routerLink]=\"item.routerLink\"\n [attr.target]=\"item.target\"\n [attr.tabindex]=\"0\"\n [ngClass]=\"item.className ?? ''\"\n pRipple>\n <i [ngClass]=\"item.icon ?? ''\" class=\"layout-menuitem-icon\"></i>\n <span class=\"layout-menuitem-text\">{{ item.label! | translate }}</span>\n <i class=\"pi pi-fw pi-angle-down layout-submenu-toggler\" *ngIf=\"item.items\"></i>\n <span class=\"menuitem-badge\" *ngIf=\"item.badge\">{{ item.badge }}</span>\n </a>\n <a\n *ngIf=\"item.routerLink && !item.items && item.visible !== false && (guardsIsAllowed$ | async) === true && (isPermitted$ | async) === true\"\n (click)=\"itemClick($event)\"\n (mouseenter)=\"hover = true\"\n (mouseleave)=\"hover = false\"\n [routerLink]=\"item.routerLink\"\n routerLinkActive=\"active-menuitem-routerlink\"\n [routerLinkActiveOptions]=\"{exact: true}\"\n [attr.target]=\"item.target\"\n [attr.tabindex]=\"0\"\n [ngClass]=\"item.className ?? ''\"\n pRipple>\n <i [ngClass]=\"item.icon ?? ''\" class=\"layout-menuitem-icon\"></i>\n <span class=\"layout-menuitem-text\">{{ item.label! | translate }}</span>\n <i class=\"pi pi-fw pi-angle-down layout-submenu-toggler\" *ngIf=\"item.items\"></i>\n <span class=\"menuitem-badge\" *ngIf=\"item.badge\">{{ item.badge }}</span>\n </a>\n <ul\n *ngIf=\"\n ((item.items && active) || (item.items && (mngCommons.menuModeIsStatic$ | async) && (root || active))) &&\n item.visible !== false &&\n (guardsIsAllowed$ | async) === true &&\n (isPermitted$ | async) === true\n \"\n [@children]=\"\n (mngCommons.menuModeIsSlim$ | async) && (mainLayoutService.isMobile$ | async) === false && root\n ? active\n ? 'visible'\n : 'hidden'\n : (mngCommons.menuModeIsStatic$ | async) && root && (mainLayoutService.isMobile$ | async) === false\n ? 'visible'\n : active\n ? 'visibleAnimated'\n : 'hiddenAnimated'\n \">\n <ng-template ngFor let-child let-i=\"index\" [ngForOf]=\"item.items\">\n <li mng-menuitem [item]=\"child\" [index]=\"i\" [parentKey]=\"key\" [class]=\"child.badgeClassName\"></li>\n </ng-template>\n </ul>\n</ng-container>\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i1.RouterLinkActive, selector: "[routerLinkActive]", inputs: ["routerLinkActiveOptions", "ariaCurrentWhenActive", "routerLinkActive"], outputs: ["isActiveChange"], exportAs: ["routerLinkActive"] }, { kind: "directive", type: i5.Ripple, selector: "[pRipple]" }, { kind: "component", type: MngMenuItemComponent, selector: "[mng-menuitem]", inputs: ["item", "index", "root", "parentKey"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }], animations: [
|
|
10900
10932
|
trigger('children', [
|
|
10901
10933
|
state('void', style({
|
|
10902
10934
|
height: '0px'
|
|
@@ -11080,7 +11112,7 @@ class MngTopbarComponent {
|
|
|
11080
11112
|
this.menuComponent = routeData.menuComponent;
|
|
11081
11113
|
}
|
|
11082
11114
|
this.languages = this.mngCommons.appLanguages;
|
|
11083
|
-
this.selectedLanguage = this.mngCommons.
|
|
11115
|
+
this.selectedLanguage = this.mngCommons.getOrInitLanguage();
|
|
11084
11116
|
this.mngCommons.user$.subscribe(u => {
|
|
11085
11117
|
this.user = u;
|
|
11086
11118
|
});
|
|
@@ -11097,7 +11129,7 @@ class MngTopbarComponent {
|
|
|
11097
11129
|
}
|
|
11098
11130
|
}
|
|
11099
11131
|
MngTopbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTopbarComponent, deps: [{ token: i1.ActivatedRoute }, { token: MngCommonsService }, { token: MngMainLayoutComponentService }], target: i0.ɵɵFactoryTarget.Component });
|
|
11100
|
-
MngTopbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTopbarComponent, selector: "mng-topbar", viewQueries: [{ propertyName: "templates", predicate: MngTemplateDirective, descendants: true }], ngImport: i0, template: "<div class=\"layout-topbar\">\n <div class=\"layout-topbar-left\">\n <a\n href=\"#\"\n class=\"topbar-menu-button\"\n (click)=\"mainLayoutService.onMenuButtonClick($event)\"\n *ngIf=\"(mngCommons.menuModeIsOverlay$ | async) || (mainLayoutService.isMobile$ | async)\">\n <i class=\"pi pi-bars\"></i>\n </a>\n\n <ng-container [mngComponent]=\"breadcrumbComponent\"></ng-container>\n </div>\n\n <ng-container [mngComponent]=\"menuComponent\"></ng-container>\n\n <div class=\"layout-topbar-right\">\n <ul class=\"layout-topbar-right-items\">\n <li #profile class=\"profile-item\" [ngClass]=\"{'active-topmenuitem': (mainLayoutService.activeTopbarItem$ | async) === profile}\">\n <a href=\"#\" (click)=\"mainLayoutService.onTopbarItemClick($event, profile)\">\n <i class=\"pi pi-fw pi-user\"></i>\n </a>\n <ul class=\"fadeInDown\" *ngIf=\"user\">\n <li role=\"menuitem\">\n <a>\n {{ user?.displayName ?? user?.username }}\n </a>\n </li>\n <li role=\"menuitem\" *ngIf=\"user?.logout || user?.logoutUrl\">\n <a [href]=\"user?.logoutUrl\" (click)=\"logout(user, $event)\">\n <i class=\"pi pi-fw pi-sign-out\"></i>\n <span>{{ 'mngTopbar.logout' | translate }}</span>\n </a>\n </li>\n </ul>\n </li>\n <li *ngIf=\"languages.length > 1\" class=\"profile-item\" [ngClass]=\"{'active-topmenuitem': (mainLayoutService.activeTopbarItem$ | async) === profile}\">\n <i class=\"pi pi-fw pi-globe\"></i>\n <p-dropdown [ngModel]=\"selectedLanguage\" [options]=\"languages\" (onChange)=\"switchLanguage($event.value)\"></p-dropdown>\n </li>\n </ul>\n </div>\n</div>\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "component", type: i5$
|
|
11132
|
+
MngTopbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: MngTopbarComponent, selector: "mng-topbar", viewQueries: [{ propertyName: "templates", predicate: MngTemplateDirective, descendants: true }], ngImport: i0, template: "<div class=\"layout-topbar\">\n <div class=\"layout-topbar-left\">\n <a\n href=\"#\"\n class=\"topbar-menu-button\"\n (click)=\"mainLayoutService.onMenuButtonClick($event)\"\n *ngIf=\"(mngCommons.menuModeIsOverlay$ | async) || (mainLayoutService.isMobile$ | async)\">\n <i class=\"pi pi-bars\"></i>\n </a>\n\n <ng-container [mngComponent]=\"breadcrumbComponent\"></ng-container>\n </div>\n\n <ng-container [mngComponent]=\"menuComponent\"></ng-container>\n\n <div class=\"layout-topbar-right\">\n <ul class=\"layout-topbar-right-items\">\n <li #profile class=\"profile-item\" [ngClass]=\"{'active-topmenuitem': (mainLayoutService.activeTopbarItem$ | async) === profile}\">\n <a href=\"#\" (click)=\"mainLayoutService.onTopbarItemClick($event, profile)\">\n <i class=\"pi pi-fw pi-user\"></i>\n </a>\n <ul class=\"fadeInDown\" *ngIf=\"user\">\n <li role=\"menuitem\">\n <a>\n {{ user?.displayName ?? user?.username }}\n </a>\n </li>\n <li role=\"menuitem\" *ngIf=\"user?.logout || user?.logoutUrl\">\n <a [href]=\"user?.logoutUrl\" (click)=\"logout(user, $event)\">\n <i class=\"pi pi-fw pi-sign-out\"></i>\n <span>{{ 'mngTopbar.logout' | translate }}</span>\n </a>\n </li>\n </ul>\n </li>\n <li *ngIf=\"languages.length > 1\" class=\"profile-item\" [ngClass]=\"{'active-topmenuitem': (mainLayoutService.activeTopbarItem$ | async) === profile}\">\n <i class=\"pi pi-fw pi-globe\"></i>\n <p-dropdown [ngModel]=\"selectedLanguage\" [options]=\"languages\" (onChange)=\"switchLanguage($event.value)\"></p-dropdown>\n </li>\n </ul>\n </div>\n</div>\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "component", type: i5$2.Dropdown, selector: "p-dropdown", inputs: ["scrollHeight", "filter", "name", "style", "panelStyle", "styleClass", "panelStyleClass", "readonly", "required", "editable", "appendTo", "tabindex", "placeholder", "filterPlaceholder", "filterLocale", "inputId", "selectId", "dataKey", "filterBy", "autofocus", "resetFilterOnHide", "dropdownIcon", "optionLabel", "optionValue", "optionDisabled", "optionGroupLabel", "optionGroupChildren", "autoDisplayFirst", "group", "showClear", "emptyFilterMessage", "emptyMessage", "lazy", "virtualScroll", "virtualScrollItemSize", "virtualScrollOptions", "autoZIndex", "baseZIndex", "showTransitionOptions", "hideTransitionOptions", "ariaFilterLabel", "ariaLabel", "ariaLabelledBy", "filterMatchMode", "maxlength", "tooltip", "tooltipPosition", "tooltipPositionStyle", "tooltipStyleClass", "autofocusFilter", "disabled", "itemSize", "options", "filterValue"], outputs: ["onChange", "onFilter", "onFocus", "onBlur", "onClick", "onShow", "onHide", "onClear", "onLazyLoad"] }, { kind: "directive", type: i2$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: MngComponentDirective, selector: "[mngComponent]", inputs: ["mngComponent", "inputs"], outputs: ["instanceCreated"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i1$2.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
11101
11133
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: MngTopbarComponent, decorators: [{
|
|
11102
11134
|
type: Component,
|
|
11103
11135
|
args: [{ selector: 'mng-topbar', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"layout-topbar\">\n <div class=\"layout-topbar-left\">\n <a\n href=\"#\"\n class=\"topbar-menu-button\"\n (click)=\"mainLayoutService.onMenuButtonClick($event)\"\n *ngIf=\"(mngCommons.menuModeIsOverlay$ | async) || (mainLayoutService.isMobile$ | async)\">\n <i class=\"pi pi-bars\"></i>\n </a>\n\n <ng-container [mngComponent]=\"breadcrumbComponent\"></ng-container>\n </div>\n\n <ng-container [mngComponent]=\"menuComponent\"></ng-container>\n\n <div class=\"layout-topbar-right\">\n <ul class=\"layout-topbar-right-items\">\n <li #profile class=\"profile-item\" [ngClass]=\"{'active-topmenuitem': (mainLayoutService.activeTopbarItem$ | async) === profile}\">\n <a href=\"#\" (click)=\"mainLayoutService.onTopbarItemClick($event, profile)\">\n <i class=\"pi pi-fw pi-user\"></i>\n </a>\n <ul class=\"fadeInDown\" *ngIf=\"user\">\n <li role=\"menuitem\">\n <a>\n {{ user?.displayName ?? user?.username }}\n </a>\n </li>\n <li role=\"menuitem\" *ngIf=\"user?.logout || user?.logoutUrl\">\n <a [href]=\"user?.logoutUrl\" (click)=\"logout(user, $event)\">\n <i class=\"pi pi-fw pi-sign-out\"></i>\n <span>{{ 'mngTopbar.logout' | translate }}</span>\n </a>\n </li>\n </ul>\n </li>\n <li *ngIf=\"languages.length > 1\" class=\"profile-item\" [ngClass]=\"{'active-topmenuitem': (mainLayoutService.activeTopbarItem$ | async) === profile}\">\n <i class=\"pi pi-fw pi-globe\"></i>\n <p-dropdown [ngModel]=\"selectedLanguage\" [options]=\"languages\" (onChange)=\"switchLanguage($event.value)\"></p-dropdown>\n </li>\n </ul>\n </div>\n</div>\n" }]
|
|
@@ -12506,7 +12538,7 @@ class TableviewRouteBuilder {
|
|
|
12506
12538
|
}
|
|
12507
12539
|
return this;
|
|
12508
12540
|
}
|
|
12509
|
-
|
|
12541
|
+
withPermissionByCategory(key, permissions) {
|
|
12510
12542
|
if (!this.permissions) {
|
|
12511
12543
|
this.permissions = {};
|
|
12512
12544
|
}
|
|
@@ -12589,5 +12621,5 @@ class TableviewRouteBuilder {
|
|
|
12589
12621
|
* Generated bundle index. Do not edit.
|
|
12590
12622
|
*/
|
|
12591
12623
|
|
|
12592
|
-
export { ACTION_EDITOR_DIALOG_COMPONENT_SETTING, AFieldDescriptor, AFieldGroupDescriptor, AGenericFieldDescriptor, AMngApiService, AMngBaseApiService, AMngCrudApiService, AMngGetAllApiService, AMngTableviewRouteComponent, APermissions, ActionActivationTriggerEnum, ActionButtonDescriptor, ActionConfirmationDialogDescriptor, ActionContext, ActionContextValidation, ActionDataProviderUtil, ActionDeleteDescriptor, ActionDescriptor, ActionEditorAddDescriptor, ActionEditorDescriptor, ActionEditorDetailsDescriptor, ActionEditorEditDescriptor, ActionEditorSubmitDescriptor, ActionEditorSubmitTypeEnum, ActionError, ActionInstance, ActionInstanceStateEnum, ActionLinkDescriptor, ActionParameters, ActionPositionEnum, ActionSimpleDescriptor, ActionTypeEnum, AuthorizationTypeEnum, AuthorizationUtil, ButtonStyleBuilder, ButtonStyleRoundedEnum, ColumnDescriptor, ColumnDynamicDescriptor, ColumnTypeEnum, DataProvider, DateUtil, DefaultMngErrorMapperService, DynamicTableviewDataProvider, EditorDataProvider, EditorDescriptor, EditorFormlyUtil, EnumName, EnumUtil, FieldGroupDescriptor, FieldGroupTypeEnum, FieldInputDescriptor, FieldInputTypeEnum, FieldLookupDescriptor, FieldLookupEnumDescriptor, FieldLookupTypeEnum, FieldManyEditorActionEnum, FieldManyEditorDescriptor, FieldManyEditorTypeEnum, FieldManyToManyEditorActionEnum, FieldManyToManyEditorDescriptor, FieldManyToManyEditorTypeEnum, FieldSizeEnum, FieldTabGroupDescriptor, FieldValidationDescriptor, FilterDescriptor, FilterLookupDescriptor, FilterLookupEnumDescriptor, FilterLookupTypeEnum, FilterMatchModeEnum, FilterTypeEnum, I18nUtils, JsonPathPipe, LookupDataProvider, MNG_AUTOCOMPLETE_VALUE_ACCESSOR, MNG_BROWSER_STORAGE_IT, MNG_COMMONS_INITIALIZER_IT, MNG_DATE_RANGE_VALUE_ACCESSOR, MNG_DROPDOWN_VALUE_ACCESSOR, MNG_MODULE_CONFIG_IT, MediusFilterMatchType, MediusFilterParam, MediusQueryMode, MediusQueryParam, MediusQueryParamBuilder, MediusQueryResult, MediusRestUtil, MngActionComponent, MngActionEditorComponent, MngActionExecutorService, MngActionRouteComponent, MngAuthorizationGuard, MngAuthorizationService, MngAutocompleteComponent, MngBooleanPipe, MngBreadcrumbComponent, MngClassMapPipe, MngCommonsModule, MngCommonsService, MngComponentDirective, MngConfigurationService, MngDateRangeComponent, MngDropdownComponent, MngEnumPipe, MngErrorMapperService, MngFooterComponent, MngFormEditorComponent, MngFormEditorSubmitEvent, MngFormFieldEvent, MngFormFieldEventComponentSubtype, MngFormFieldEventDialogSubtype, MngFormFieldEventTypeEnum, MngFormlyFieldAutocompleteComponent, MngFormlyFieldDropdownComponent, MngFormlyFieldFieldsetComponent, MngFormlyFieldInputComponent, MngFormlyFieldLabelComponent, MngFormlyFieldLookupDialogComponent, MngFormlyFieldTableDialogFormComponent, MngFormlyFieldTableDialogMultiselectComponent, MngFormlyFieldTabsComponent, MngFormlyFieldWrapperComponent, MngFormlyTableWrapperComponent, MngGetterPipe, MngI18nPropertyPipe, MngMainLayoutComponent, MngMainLayoutComponentService, MngMenuComponent, MngMenuItemComponent, MngNavigationService, MngParametrizePipe, MngTableCellClickEvent, MngTableColumnFilterComponent, MngTableColumnValueComponent, MngTableComponent, MngTableLoadEvent, MngTableReloadEvent, MngTableviewComponent, MngTableviewRouteComponent, MngTemplateDirective, MngTemplatePipe, MngTopbarComponent, MngVersionComponent, MngViewContainerComponentService, ModelDescriptor, ModelUtil, NotificationUtil, ObjectSerializer, Permissions, RouteBuilder, RoutesBuilder, StringUtil, StyleLevelEnum, StyleSizeEnum, StylesUtil, TableDataProvider, TableDescriptor, TableDynamicColumnsModeEnum, TableDynamicDescriptor, TableFilterDisplayEnum, TablePaginationModeEnum, TableSizeEnum, TableviewActionDefaultCategories, TableviewCrudDataProvider, TableviewDataProvider, TableviewDescriptor, TableviewDynamicDescriptor,
|
|
12624
|
+
export { ACTION_EDITOR_DIALOG_COMPONENT_SETTING, AFieldDescriptor, AFieldGroupDescriptor, AGenericFieldDescriptor, AMngApiService, AMngBaseApiService, AMngCrudApiService, AMngGetAllApiService, AMngTableviewRouteComponent, APermissions, ActionActivationTriggerEnum, ActionButtonDescriptor, ActionConfirmationDialogDescriptor, ActionContext, ActionContextValidation, ActionDataProviderUtil, ActionDeleteDescriptor, ActionDescriptor, ActionEditorAddDescriptor, ActionEditorDescriptor, ActionEditorDetailsDescriptor, ActionEditorEditDescriptor, ActionEditorSubmitDescriptor, ActionEditorSubmitTypeEnum, ActionError, ActionInstance, ActionInstanceStateEnum, ActionLinkDescriptor, ActionParameters, ActionPositionEnum, ActionSimpleDescriptor, ActionTypeEnum, AuthorizationTypeEnum, AuthorizationUtil, ButtonStyleBuilder, ButtonStyleRoundedEnum, ColumnDescriptor, ColumnDynamicDescriptor, ColumnTypeEnum, DataProvider, DateUtil, DefaultMngErrorMapperService, DynamicTableviewDataProvider, EditorDataProvider, EditorDescriptor, EditorFormlyUtil, EnumName, EnumUtil, FieldGroupDescriptor, FieldGroupTypeEnum, FieldInputDescriptor, FieldInputTypeEnum, FieldLookupDescriptor, FieldLookupEnumDescriptor, FieldLookupTypeEnum, FieldManyEditorActionEnum, FieldManyEditorDescriptor, FieldManyEditorTypeEnum, FieldManyToManyEditorActionEnum, FieldManyToManyEditorDescriptor, FieldManyToManyEditorTypeEnum, FieldSizeEnum, FieldTabGroupDescriptor, FieldValidationDescriptor, FilterDescriptor, FilterLookupDescriptor, FilterLookupEnumDescriptor, FilterLookupTypeEnum, FilterMatchModeEnum, FilterTypeEnum, I18nUtils, JsonPathPipe, LookupDataProvider, MNG_AUTOCOMPLETE_VALUE_ACCESSOR, MNG_BROWSER_STORAGE_IT, MNG_COMMONS_INITIALIZER_IT, MNG_DATE_RANGE_VALUE_ACCESSOR, MNG_DROPDOWN_VALUE_ACCESSOR, MNG_MODULE_CONFIG_IT, MediusFilterMatchType, MediusFilterParam, MediusQueryMode, MediusQueryParam, MediusQueryParamBuilder, MediusQueryResult, MediusRestUtil, MngActionComponent, MngActionEditorComponent, MngActionExecutorService, MngActionRouteComponent, MngAuthorizationGuard, MngAuthorizationService, MngAutocompleteComponent, MngBooleanPipe, MngBreadcrumbComponent, MngClassMapPipe, MngCommonsModule, MngCommonsService, MngComponentDirective, MngConfigurationService, MngDateRangeComponent, MngDropdownComponent, MngEnumPipe, MngErrorMapperService, MngFooterComponent, MngFormEditorComponent, MngFormEditorSubmitEvent, MngFormFieldEvent, MngFormFieldEventComponentSubtype, MngFormFieldEventDialogSubtype, MngFormFieldEventTypeEnum, MngFormlyFieldAutocompleteComponent, MngFormlyFieldDropdownComponent, MngFormlyFieldFieldsetComponent, MngFormlyFieldInputComponent, MngFormlyFieldLabelComponent, MngFormlyFieldLookupDialogComponent, MngFormlyFieldTableDialogFormComponent, MngFormlyFieldTableDialogMultiselectComponent, MngFormlyFieldTabsComponent, MngFormlyFieldWrapperComponent, MngFormlyTableWrapperComponent, MngGetterPipe, MngI18nPropertyPipe, MngMainLayoutComponent, MngMainLayoutComponentService, MngMenuComponent, MngMenuItemComponent, MngNavigationService, MngParametrizePipe, MngTableCellClickEvent, MngTableColumnFilterComponent, MngTableColumnValueComponent, MngTableComponent, MngTableLoadEvent, MngTableReloadEvent, MngTableviewComponent, MngTableviewRouteComponent, MngTemplateDirective, MngTemplatePipe, MngTopbarComponent, MngVersionComponent, MngViewContainerComponentService, ModelDescriptor, ModelUtil, NotificationUtil, ObjectSerializer, Permissions, RouteBuilder, RoutesBuilder, StringUtil, StyleLevelEnum, StyleSizeEnum, StylesUtil, TableDataProvider, TableDescriptor, TableDynamicColumnsModeEnum, TableDynamicDescriptor, TableFilterDisplayEnum, TablePaginationModeEnum, TableSizeEnum, TableviewActionDefaultCategories, TableviewCrudDataProvider, TableviewDataProvider, TableviewDescriptor, TableviewDynamicDescriptor, TableviewEditorTypeEnum, TableviewRouteBuilder, TypeName, TypeUtil, enumNameDecoratorPropertyName, enumsMapBase, formlyTypesConfig, formlyWrappersConfig, getEmailValidationMessage, getFormlyValidationMessages, getMaxLengthValidationMessage, getMinLengthValidationMessage, getRequiredValidationMessage, getTextPatternValidationMessage, mngConfigJsonAppInitializerProvider, mngConfigurationServiceProvider, mngFormlyConfigProvider, primeNgModules, typeMapBase, typeNameDecoratorPropertyName };
|
|
12593
12625
|
//# sourceMappingURL=mediusinc-mng-commons.mjs.map
|