@mediusinc/mng-commons 4.0.0-rc.1 → 4.0.0-rc.3

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.
Files changed (184) hide show
  1. package/esm2022/index.mjs +12 -2
  2. package/esm2022/lib/api/utils/medius-rest.util.mjs +15 -7
  3. package/esm2022/lib/api/utils/object-serializer.util.mjs +8 -4
  4. package/esm2022/lib/components/action/action.component.mjs +16 -45
  5. package/esm2022/lib/components/action/editor/action-editor.component.mjs +60 -434
  6. package/esm2022/lib/components/action/editor/injector-context/action-editor-injector-context.component.mjs +394 -0
  7. package/esm2022/lib/components/action/index.mjs +2 -1
  8. package/esm2022/lib/components/action/localization/data-language-dropdown.component.mjs +6 -7
  9. package/esm2022/lib/components/action/models/action-component.model.mjs +1 -1
  10. package/esm2022/lib/components/action/models/action-execution.model.mjs +3 -6
  11. package/esm2022/lib/components/action/models/index.mjs +1 -2
  12. package/esm2022/lib/components/action/route/action-route.component.mjs +14 -30
  13. package/esm2022/lib/components/action/table/action-table.component.mjs +154 -0
  14. package/esm2022/lib/components/form/editor/form-editor.component.mjs +5 -11
  15. package/esm2022/lib/components/form/formly/fields/formly-field-custom/formly-field-custom.component.mjs +1 -1
  16. package/esm2022/lib/components/form/formly/fields/formly-field-lookup-dialog/formly-field-lookup-dialog.component.mjs +5 -5
  17. package/esm2022/lib/components/form/formly/fields/formly-field-table-dialog-form/formly-field-table-dialog-form.component.mjs +6 -7
  18. package/esm2022/lib/components/form/formly/fields/formly-field-table-dialog-multiselect/formly-field-table-dialog-multiselect.component.mjs +5 -5
  19. package/esm2022/lib/components/form/formly/wrappers/formly-field-wrapper/formly-field-wrapper.component.mjs +1 -1
  20. package/esm2022/lib/components/layout/main-layout.component.mjs +21 -25
  21. package/esm2022/lib/components/layout/topbar.component.mjs +8 -8
  22. package/esm2022/lib/components/layoutV2/main-layout.component.mjs +13 -10
  23. package/esm2022/lib/components/layoutV2/menu-item.component.mjs +48 -5
  24. package/esm2022/lib/components/layoutV2/menu.component.mjs +13 -4
  25. package/esm2022/lib/components/layoutV2/services/main-layout.component.service.mjs +11 -2
  26. package/esm2022/lib/components/layoutV2/sidebar.component.mjs +5 -5
  27. package/esm2022/lib/components/layoutV2/topbar.component.mjs +7 -12
  28. package/esm2022/lib/components/notification/notification-wrapper.component.mjs +50 -0
  29. package/esm2022/lib/components/table/column-filter-full/column-filter-full.component.mjs +466 -0
  30. package/esm2022/lib/components/table/column-value/column-value.component.mjs +87 -0
  31. package/esm2022/lib/components/table/models/table.event.mjs +16 -0
  32. package/esm2022/lib/components/table/models/table.interface.mjs +2 -0
  33. package/esm2022/lib/components/table/table-column-filter-class/table-column-filter-class.pipe.mjs +25 -0
  34. package/esm2022/lib/components/table/table.component.mjs +717 -0
  35. package/esm2022/lib/components/tableview/index.mjs +1 -4
  36. package/esm2022/lib/components/tableview/route/tableview-route.abstract.component.mjs +5 -5
  37. package/esm2022/lib/components/tableview/route/tableview-route.component.mjs +3 -9
  38. package/esm2022/lib/components/tableview/tableview.component.mjs +18 -78
  39. package/esm2022/lib/descriptors/editor/editor.descriptor.mjs +1 -1
  40. package/esm2022/lib/descriptors/editor/field-lookup.descriptor.mjs +1 -2
  41. package/esm2022/lib/descriptors/filter/filter.descriptor.mjs +20 -20
  42. package/esm2022/lib/descriptors/table/table.descriptor.mjs +16 -17
  43. package/esm2022/lib/descriptors/tableview/tableview.descriptor.mjs +1 -1
  44. package/esm2022/lib/directives/component.directive.mjs +8 -4
  45. package/esm2022/lib/helpers/coercion.mjs +8 -1
  46. package/esm2022/lib/models/action-editor.model.mjs +1 -1
  47. package/esm2022/lib/models/config.model.mjs +1 -1
  48. package/esm2022/lib/models/index.mjs +2 -2
  49. package/esm2022/lib/models/layout-config.model.mjs +2 -0
  50. package/esm2022/lib/models/view-container.model.mjs +1 -1
  51. package/esm2022/lib/provide-commons.mjs +7 -1
  52. package/esm2022/lib/registry/type.registry.mjs +2 -3
  53. package/esm2022/lib/router/route-builder.mjs +1 -1
  54. package/esm2022/lib/services/action/action-executor.service.mjs +725 -0
  55. package/esm2022/lib/services/action/component-action-executor.service.mjs +19 -0
  56. package/esm2022/lib/services/action/index.mjs +5 -0
  57. package/esm2022/lib/services/action/provide-action-executor.mjs +9 -0
  58. package/esm2022/lib/services/action/root-action-executor.service.mjs +18 -0
  59. package/esm2022/lib/services/commons.service.mjs +5 -5
  60. package/esm2022/lib/services/index.mjs +1 -3
  61. package/esm2022/lib/services/logger.service.mjs +2 -2
  62. package/esm2022/lib/services/view/index.mjs +3 -0
  63. package/esm2022/lib/services/view/provide-view-container.mjs +17 -0
  64. package/esm2022/lib/services/view/view-container.service.mjs +59 -0
  65. package/esm2022/lib/utils/date.util.mjs +33 -23
  66. package/esm2022/lib/utils/notification.util.mjs +9 -16
  67. package/esm2022/lib/utils/string.util.mjs +2 -2
  68. package/esm2022/lib/utils/tableview.util.mjs +2 -2
  69. package/fesm2022/mediusinc-mng-commons.mjs +4305 -4121
  70. package/fesm2022/mediusinc-mng-commons.mjs.map +1 -1
  71. package/index.d.ts +10 -1
  72. package/lib/components/action/action.component.d.ts +11 -17
  73. package/lib/components/action/editor/action-editor.component.d.ts +20 -80
  74. package/lib/components/action/editor/injector-context/action-editor-injector-context.component.d.ts +80 -0
  75. package/lib/components/action/index.d.ts +1 -0
  76. package/lib/components/action/localization/data-language-dropdown.component.d.ts +2 -3
  77. package/lib/components/action/models/action-component.model.d.ts +0 -2
  78. package/lib/components/action/models/action-execution.model.d.ts +6 -6
  79. package/lib/components/action/models/index.d.ts +0 -1
  80. package/lib/components/action/route/action-route.component.d.ts +6 -12
  81. package/lib/components/action/table/action-table.component.d.ts +50 -0
  82. package/lib/components/form/editor/form-editor.component.d.ts +4 -7
  83. package/lib/components/form/formly/fields/formly-field-lookup-dialog/formly-field-lookup-dialog.component.d.ts +2 -4
  84. package/lib/components/form/formly/fields/formly-field-table-dialog-form/formly-field-table-dialog-form.component.d.ts +0 -2
  85. package/lib/components/form/formly/fields/formly-field-table-dialog-multiselect/formly-field-table-dialog-multiselect.component.d.ts +1 -3
  86. package/lib/components/layout/main-layout.component.d.ts +4 -7
  87. package/lib/components/layoutV2/main-layout.component.d.ts +4 -3
  88. package/lib/components/layoutV2/menu-item.component.d.ts +7 -3
  89. package/lib/components/layoutV2/menu.component.d.ts +2 -0
  90. package/lib/components/layoutV2/services/main-layout.component.service.d.ts +3 -0
  91. package/lib/components/layoutV2/sidebar.component.d.ts +1 -1
  92. package/lib/components/layoutV2/topbar.component.d.ts +2 -3
  93. package/lib/components/notification/notification-wrapper.component.d.ts +12 -0
  94. package/lib/components/{tableview/table → table}/column-filter-full/column-filter-full.component.d.ts +2 -2
  95. package/lib/components/{tableview/table → table}/column-value/column-value.component.d.ts +3 -3
  96. package/lib/components/{tableview/table → table}/models/table.interface.d.ts +3 -1
  97. package/lib/components/table/table-column-filter-class/table-column-filter-class.pipe.d.ts +8 -0
  98. package/lib/components/table/table.component.d.ts +122 -0
  99. package/lib/components/tableview/index.d.ts +0 -3
  100. package/lib/components/tableview/route/tableview-route.abstract.component.d.ts +2 -3
  101. package/lib/components/tableview/route/tableview-route.component.d.ts +0 -3
  102. package/lib/components/tableview/tableview.component.d.ts +4 -20
  103. package/lib/descriptors/editor/editor.descriptor.d.ts +1 -1
  104. package/lib/descriptors/filter/filter.descriptor.d.ts +7 -7
  105. package/lib/descriptors/table/table.descriptor.d.ts +15 -12
  106. package/lib/descriptors/tableview/tableview.descriptor.d.ts +1 -1
  107. package/lib/directives/component.directive.d.ts +3 -2
  108. package/lib/models/action-editor.model.d.ts +11 -0
  109. package/lib/models/config.model.d.ts +3 -13
  110. package/lib/models/index.d.ts +1 -1
  111. package/lib/models/layout-config.model.d.ts +33 -0
  112. package/lib/models/view-container.model.d.ts +0 -25
  113. package/lib/router/route-builder.d.ts +1 -1
  114. package/lib/services/{action-executor.service.d.ts → action/action-executor.service.d.ts} +32 -31
  115. package/lib/services/action/component-action-executor.service.d.ts +9 -0
  116. package/lib/services/action/index.d.ts +4 -0
  117. package/lib/services/action/provide-action-executor.d.ts +2 -0
  118. package/lib/services/action/root-action-executor.service.d.ts +9 -0
  119. package/lib/services/index.d.ts +0 -2
  120. package/lib/services/view/index.d.ts +2 -0
  121. package/lib/services/view/provide-view-container.d.ts +2 -0
  122. package/lib/services/view/view-container.service.d.ts +32 -0
  123. package/lib/utils/date.util.d.ts +12 -2
  124. package/lib/utils/notification.util.d.ts +6 -6
  125. package/openapi/angular/README.mustache +226 -0
  126. package/openapi/angular/api.module.mustache +39 -0
  127. package/openapi/angular/api.service.mustache +253 -0
  128. package/openapi/angular/apiInterface.mustache +47 -0
  129. package/openapi/angular/apis.mustache +12 -0
  130. package/openapi/angular/configuration.mustache +128 -0
  131. package/openapi/angular/custom/base-api.service.mustache +14 -0
  132. package/openapi/angular/custom/helpers.mustache +71 -0
  133. package/openapi/angular/custom/modelSchema.mustache +46 -0
  134. package/openapi/angular/custom/schema.mustache +18 -0
  135. package/openapi/angular/encoder.mustache +20 -0
  136. package/openapi/angular/git_push.sh.mustache +57 -0
  137. package/openapi/angular/index.mustache +0 -0
  138. package/openapi/angular/licenseInfo.mustache +11 -0
  139. package/openapi/angular/model.mustache +16 -0
  140. package/openapi/angular/modelAlias.mustache +1 -0
  141. package/openapi/angular/modelEnum.mustache +24 -0
  142. package/openapi/angular/modelGeneric.mustache +14 -0
  143. package/openapi/angular/modelGenericAdditionalProperties.mustache +5 -0
  144. package/openapi/angular/modelGenericEnums.mustache +30 -0
  145. package/openapi/angular/modelOneOf.mustache +14 -0
  146. package/openapi/angular/modelTaggedUnion.mustache +21 -0
  147. package/openapi/angular/models.mustache +5 -0
  148. package/openapi/angular/ng-package.mustache +6 -0
  149. package/openapi/angular/package.mustache +39 -0
  150. package/openapi/angular/param.mustache +69 -0
  151. package/openapi/angular/tsconfig.mustache +28 -0
  152. package/openapi/angular/variables.mustache +9 -0
  153. package/openapi/{templates → node}/model.mustache +3 -17
  154. package/package.json +2 -2
  155. package/scss/mng-commons-dark-v2.scss +1 -1
  156. package/scss/mng-commons-light-v2.scss +1 -1
  157. package/scss/mng-overrides/_theme_datatable.scss +24 -10
  158. package/scss/v2/layout/layout.scss +2 -2
  159. package/scss/v2/layout/mng/_mng_layout_topbar.scss +2 -0
  160. package/scss/v2/layout/preloading.scss +8 -8
  161. package/scss/v2/theme/theme-base/mng/_mng_theme_datatable.scss +24 -9
  162. package/scss/v2/theme/theme-dark/_variables.scss +24 -12
  163. package/scss/v2/theme/theme-dark/blue/theme.scss +4 -4
  164. package/scss/v2/theme/theme-light/_variables.scss +23 -11
  165. package/scss/v2/theme/theme-light/blue/theme.scss +2 -2
  166. package/esm2022/lib/components/action/models/action-confirmation-service.model.mjs +0 -2
  167. package/esm2022/lib/components/tableview/models/index.mjs +0 -2
  168. package/esm2022/lib/components/tableview/models/table.event.mjs +0 -16
  169. package/esm2022/lib/components/tableview/table/column-filter-full/column-filter-full.component.mjs +0 -467
  170. package/esm2022/lib/components/tableview/table/column-value/column-value.component.mjs +0 -87
  171. package/esm2022/lib/components/tableview/table/models/index.mjs +0 -2
  172. package/esm2022/lib/components/tableview/table/models/table.interface.mjs +0 -2
  173. package/esm2022/lib/components/tableview/table/table.component.mjs +0 -752
  174. package/esm2022/lib/models/menu-config.model.mjs +0 -2
  175. package/esm2022/lib/services/action-executor.service.mjs +0 -747
  176. package/esm2022/lib/services/view-container.component.service.mjs +0 -65
  177. package/lib/components/action/models/action-confirmation-service.model.d.ts +0 -6
  178. package/lib/components/tableview/models/index.d.ts +0 -1
  179. package/lib/components/tableview/table/models/index.d.ts +0 -1
  180. package/lib/components/tableview/table/table.component.d.ts +0 -147
  181. package/lib/models/menu-config.model.d.ts +0 -15
  182. package/lib/services/view-container.component.service.d.ts +0 -36
  183. /package/lib/components/{tableview → table}/models/table.event.d.ts +0 -0
  184. /package/openapi/{templates → node}/models.mustache +0 -0
@@ -1,65 +0,0 @@
1
- import { Injectable } from '@angular/core';
2
- import { MessageService } from 'primeng/api';
3
- import { Subject } from 'rxjs';
4
- import * as i0 from "@angular/core";
5
- import * as i1 from "primeng/api";
6
- /**
7
- * Should be used with providers defined within component.
8
- */
9
- export class MngViewContainerComponentService {
10
- constructor(messageService) {
11
- this.messageService = messageService;
12
- this.actions = [];
13
- this._tableReloadSubject = new Subject();
14
- this._editorResetSubject = new Subject();
15
- this._editorCloseSubject = new Subject();
16
- }
17
- set dataProvider(dataProvider) {
18
- this._dataProvider = dataProvider;
19
- }
20
- getMessageService() {
21
- return this.messageService;
22
- }
23
- getDataProvider() {
24
- return this._dataProvider;
25
- }
26
- getActions() {
27
- return this.actions;
28
- }
29
- setActions(actions) {
30
- this.actions = actions;
31
- }
32
- getTableReload$() {
33
- return this._tableReloadSubject.asObservable();
34
- }
35
- reloadTable(event) {
36
- this._tableReloadSubject.next(event ?? {});
37
- }
38
- getEditorReset$() {
39
- return this._editorResetSubject.asObservable();
40
- }
41
- resetEditor(event) {
42
- this._editorResetSubject.next(event ?? {});
43
- }
44
- getEditorClose$() {
45
- return this._editorCloseSubject.asObservable();
46
- }
47
- closeEditor(event) {
48
- this._editorCloseSubject.next(event ?? {});
49
- }
50
- getActionRouteTriggeredInstance() {
51
- return this._routeTriggeredActionInstance;
52
- }
53
- setActionRouteTriggeredInstance(instance) {
54
- this._routeTriggeredActionInstance = instance;
55
- }
56
- unsetActionRouteTriggeredInstance() {
57
- this._routeTriggeredActionInstance = undefined;
58
- }
59
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.0.8", ngImport: i0, type: MngViewContainerComponentService, deps: [{ token: i1.MessageService }], target: i0.ɵɵFactoryTarget.Injectable }); }
60
- static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "17.0.8", ngImport: i0, type: MngViewContainerComponentService }); }
61
- }
62
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.8", ngImport: i0, type: MngViewContainerComponentService, decorators: [{
63
- type: Injectable
64
- }], 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mlld0NvbnRhaW5lckVkaXRvckNsb3NlRXZlbnQ8VD4+IHtcbiAgICAgICAgcmV0dXJuIHRoaXMuX2VkaXRvckNsb3NlU3ViamVjdC5hc09ic2VydmFibGUoKTtcbiAgICB9XG5cbiAgICBjbG9zZUVkaXRvcihldmVudD86IFZpZXdDb250YWluZXJFZGl0b3JDbG9zZUV2ZW50PFQ+KTogdm9pZCB7XG4gICAgICAgIHRoaXMuX2VkaXRvckNsb3NlU3ViamVjdC5uZXh0KGV2ZW50ID8/IHt9KTtcbiAgICB9XG5cbiAgICBnZXRBY3Rpb25Sb3V0ZVRyaWdnZXJlZEluc3RhbmNlKCk6IEFjdGlvbkluc3RhbmNlPFQsIFM+IHwgdW5kZWZpbmVkIHtcbiAgICAgICAgcmV0dXJuIHRoaXMuX3JvdXRlVHJpZ2dlcmVkQWN0aW9uSW5zdGFuY2U7XG4gICAgfVxuXG4gICAgc2V0QWN0aW9uUm91dGVUcmlnZ2VyZWRJbnN0YW5jZShpbnN0YW5jZTogQWN0aW9uSW5zdGFuY2U8VCwgUz4pOiB2b2lkIHtcbiAgICAgICAgdGhpcy5fcm91dGVUcmlnZ2VyZWRBY3Rpb25JbnN0YW5jZSA9IGluc3RhbmNlO1xuICAgIH1cblxuICAgIHVuc2V0QWN0aW9uUm91dGVUcmlnZ2VyZWRJbnN0YW5jZSgpOiB2b2lkIHtcbiAgICAgICAgdGhpcy5fcm91dGVUcmlnZ2VyZWRBY3Rpb25JbnN0YW5jZSA9IHVuZGVmaW5lZDtcbiAgICB9XG59XG4iXX0=
@@ -1,6 +0,0 @@
1
- import { ConfirmationService } from 'primeng/api';
2
- import { ActionDescriptorInst } from '../../../descriptors/action';
3
- export interface IActionConfirmationService {
4
- getConfirmationService(): ConfirmationService;
5
- getConfirmationServiceInstanceKey(action: ActionDescriptorInst<any>): string;
6
- }
@@ -1 +0,0 @@
1
- export * from './table.event';
@@ -1 +0,0 @@
1
- export * from './table.interface';
@@ -1,147 +0,0 @@
1
- import { AfterContentInit, EventEmitter, Injector, OnChanges, OnDestroy, OnInit, QueryList, SimpleChanges, TemplateRef, Type } from '@angular/core';
2
- import { ActivatedRoute, Router } from '@angular/router';
3
- import { TranslateService } from '@ngx-translate/core';
4
- import { FilterMetadata, SortMeta } from 'primeng/api';
5
- import { Table, TableLazyLoadEvent } from 'primeng/table';
6
- import { Observable } from 'rxjs';
7
- import { MediusQueryResult } from '../../../api/models';
8
- import { ITableDataProvider } from '../../../data-providers';
9
- import { ActionDescriptorInst } from '../../../descriptors/action';
10
- import { ColumnDescriptor, TableDescriptorInst } from '../../../descriptors/table';
11
- import { MngComponentDirective, MngTemplateDirective } from '../../../directives';
12
- import { IViewContainer } from '../../../models';
13
- import { MngActionExecutorService, MngCommonsService, MngLocalStorageService, MngViewContainerComponentService } from '../../../services';
14
- import { ActionInstance } from '../../action/models';
15
- import { MngTableCellClickEvent, MngTableLoadEvent } from '../models';
16
- import { ColumnWithPreferences } from './models';
17
- import * as i0 from "@angular/core";
18
- export declare class MngTableComponent<T = any, S = any> implements OnInit, OnChanges, AfterContentInit, OnDestroy {
19
- private injector;
20
- private router;
21
- private route;
22
- private translate;
23
- private mngCommonsService;
24
- private actionExecutor;
25
- private viewContainerService;
26
- private localStorageService;
27
- readonly cmpTypeName = "MngTableComponent";
28
- private readonly logger;
29
- initialDescriptor: TableDescriptorInst<T>;
30
- descriptor?: TableDescriptorInst<T>;
31
- items?: Observable<Array<T>> | Array<T>;
32
- queryResult?: Observable<MediusQueryResult<T>> | MediusQueryResult<T>;
33
- loading?: Observable<boolean> | boolean;
34
- dataProvider?: ITableDataProvider;
35
- useQueryParams: boolean;
36
- selectionMode: 'single' | 'multiple';
37
- selectionEnabled: boolean;
38
- actions: Array<ActionDescriptorInst<any>>;
39
- isColumnClickable?: boolean;
40
- viewContainerInit?: IViewContainer<T, S>;
41
- captionComponent?: Type<any>;
42
- columnActionComponent?: Type<any>;
43
- columnActionMinWidth: number | null;
44
- globalFilterFieldsInit?: string[];
45
- loadEventEmitter: EventEmitter<MngTableLoadEvent>;
46
- cellClickEventEmitter: EventEmitter<MngTableCellClickEvent<T>>;
47
- selectionChangeEventEmitter: EventEmitter<T[]>;
48
- captionCmpInstEventEmitter: EventEmitter<any>;
49
- columnActionCmpInstEventEmitter: EventEmitter<any>;
50
- templates: QueryList<MngTemplateDirective>;
51
- components: QueryList<MngComponentDirective<any>>;
52
- primeTable: Table;
53
- captionTemplate?: TemplateRef<any>;
54
- columnActionTemplate?: TemplateRef<any>;
55
- footerTemplate?: TemplateRef<any>;
56
- isLazy: boolean;
57
- isPagination: boolean;
58
- private useDataProvider;
59
- private useQueryParamsInitializedSubject;
60
- useQueryParamsInitialized$: Observable<boolean>;
61
- queryResult$?: Observable<MediusQueryResult<T>>;
62
- loading$?: Observable<boolean>;
63
- dataProviderInfiniteScrollItems: Array<T>;
64
- private itemsSubject;
65
- private queryResultSubscription?;
66
- rowsPerPageOptions: Array<number>;
67
- rows: number;
68
- offset: number;
69
- multiSortMeta: SortMeta[] | null;
70
- private filterMetadataSubject;
71
- globalFilterFields: string[];
72
- get filterMetadata(): {
73
- [p: string]: FilterMetadata;
74
- };
75
- get filterMetadata$(): Observable<{
76
- [p: string]: FilterMetadata;
77
- }>;
78
- infiniteScroll: boolean;
79
- className: string;
80
- tableFullHeightOffset: number | null;
81
- rowHeight?: number;
82
- selection: Array<T>;
83
- private dataProviderService;
84
- private dataProviderQueryResultSubject;
85
- private dataProviderLoadingSubject;
86
- private dataProviderLatestLazyLoadEvent?;
87
- private dataProviderLatestLazyLoadEventVersion;
88
- private dataProviderLatestQueryParam?;
89
- private dataProviderLatestQueryParamVersion;
90
- private dataProviderSubscription?;
91
- hasColumnFilters: boolean;
92
- private isFilterChanged;
93
- private isSortChanged;
94
- private filterDescriptors;
95
- showInlineActionsColumn: boolean;
96
- rowClickActions: ActionDescriptorInst<T>[];
97
- rowInlineActions: ActionDescriptorInst<T>[];
98
- private routerIsNavigationOutsideInProgress;
99
- viewContainer?: IViewContainer<T, S>;
100
- private subscriptions;
101
- areColumnsReorderable: boolean;
102
- areColumnsToggleable: boolean;
103
- columns: ColumnWithPreferences[];
104
- visibleColumns: ColumnWithPreferences[];
105
- private layoutPreferences;
106
- private localstorageKey;
107
- constructor(injector: Injector, router: Router, route: ActivatedRoute, translate: TranslateService, mngCommonsService: MngCommonsService, actionExecutor: MngActionExecutorService, viewContainerService: MngViewContainerComponentService<T, S> | null, localStorageService: MngLocalStorageService);
108
- ngOnInit(): void;
109
- ngAfterContentInit(): void;
110
- ngOnChanges(changes: SimpleChanges): void;
111
- ngOnDestroy(): void;
112
- reload(emitEvent?: boolean, resetParams?: boolean): void;
113
- onTableLazyLoad(event: TableLazyLoadEvent): void;
114
- onTableSort(event: any): void;
115
- onTableFilter(event: any): void;
116
- onCellClick(event: Event, col: ColumnDescriptor<any, T>, item: T, idx: number): void;
117
- onSelectionChange(event: Array<T>): void;
118
- onCaptionCmpInst<C>(instance: C): void;
119
- onColumnActionCmpInst<C>(instance: C): void;
120
- onActionFinish(runResult: ActionInstance<T, S>): void;
121
- /**
122
- * Method is called on column resize
123
- * @param element event's element
124
- */
125
- onTableColumnResize({ element }: any): void;
126
- private loadTableWithDataProvider;
127
- private loadTableFromRouteUpdate;
128
- private setMainAndRelatedDescriptors;
129
- private updatePrimeSortAndFilter;
130
- private createFilterMeta;
131
- private createSortMeta;
132
- private initializeDataLoadingTriggers;
133
- private initializeViewContainer;
134
- onColumnToggle(event: any): void;
135
- /**
136
- * Propagates the column move from the this.visibleColumns array to this.columns array
137
- * @param event: MultiSelectChangeEvent
138
- */
139
- onColumnReorder(event: any): void;
140
- private saveLayoutPreferences;
141
- /**
142
- * Reset column order and column visibility to default settings
143
- */
144
- resetDefaultLayout(): void;
145
- static ɵfac: i0.ɵɵFactoryDeclaration<MngTableComponent<any, any>, [null, null, null, null, null, null, { optional: true; }, null]>;
146
- static ɵcmp: i0.ɵɵComponentDeclaration<MngTableComponent<any, any>, "mng-table", never, { "initialDescriptor": { "alias": "descriptor"; "required": true; }; "items": { "alias": "items"; "required": false; }; "queryResult": { "alias": "queryResult"; "required": false; }; "loading": { "alias": "loading"; "required": false; }; "dataProvider": { "alias": "dataProvider"; "required": false; }; "useQueryParams": { "alias": "useQueryParams"; "required": false; }; "selectionMode": { "alias": "selectionMode"; "required": false; }; "selectionEnabled": { "alias": "selectionEnabled"; "required": false; }; "actions": { "alias": "actions"; "required": false; }; "isColumnClickable": { "alias": "isColumnClickable"; "required": false; }; "viewContainerInit": { "alias": "viewContainer"; "required": false; }; "captionComponent": { "alias": "captionComponent"; "required": false; }; "columnActionComponent": { "alias": "columnActionComponent"; "required": false; }; "columnActionMinWidth": { "alias": "columnActionMinWidth"; "required": false; }; "globalFilterFieldsInit": { "alias": "globalFilterFields"; "required": false; }; }, { "loadEventEmitter": "tableLoad"; "cellClickEventEmitter": "cellClick"; "selectionChangeEventEmitter": "selectionChange"; "captionCmpInstEventEmitter": "captionComponentInstance"; "columnActionCmpInstEventEmitter": "columnActionComponentInstance"; }, ["templates"], never, true, never>;
147
- }
@@ -1,15 +0,0 @@
1
- import { MenuItem } from 'primeng/api';
2
- export type MngMenuMode = 'static' | 'overlay' | 'reveal' | 'drawer';
3
- /**
4
- * @deprecated use MngMenuConfigV2 instead
5
- */
6
- export interface MngMenuConfig {
7
- mode: 'static' | 'sidebar' | 'slim' | 'overlay';
8
- menuItems?: MenuItem[];
9
- pinEnabled?: boolean;
10
- sidebarSlim?: boolean;
11
- }
12
- export interface MngMenuConfigV2 {
13
- mode: MngMenuMode;
14
- ripple?: boolean;
15
- }
@@ -1,36 +0,0 @@
1
- import { MessageService } from 'primeng/api';
2
- import { Observable } from 'rxjs';
3
- import { ActionInstance } from '../components/action/models';
4
- import { IDataProvider } from '../data-providers';
5
- import { ActionDescriptorInst } from '../descriptors/action';
6
- import { IViewActionRouteTriggeredContainer, IViewContainerEditor, IViewContainerTable, ViewContainerEditorCloseEvent, ViewContainerEditorResetEvent, ViewContainerTableReloadEvent } from '../models';
7
- import * as i0 from "@angular/core";
8
- /**
9
- * Should be used with providers defined within component.
10
- */
11
- export declare class MngViewContainerComponentService<T, S> implements IViewContainerTable<T, S>, IViewContainerEditor<T, S>, IViewActionRouteTriggeredContainer<T, S> {
12
- private messageService;
13
- private _dataProvider?;
14
- private _routeTriggeredActionInstance?;
15
- private actions;
16
- private _tableReloadSubject;
17
- private _editorResetSubject;
18
- private _editorCloseSubject;
19
- constructor(messageService: MessageService);
20
- set dataProvider(dataProvider: IDataProvider<T, S>);
21
- getMessageService(): MessageService;
22
- getDataProvider(): IDataProvider<T, S> | undefined;
23
- getActions(): Array<ActionDescriptorInst<T>>;
24
- setActions(actions: Array<ActionDescriptorInst<T>>): void;
25
- getTableReload$(): Observable<ViewContainerTableReloadEvent>;
26
- reloadTable(event?: ViewContainerTableReloadEvent): void;
27
- getEditorReset$(): Observable<ViewContainerEditorResetEvent<T>>;
28
- resetEditor(event?: ViewContainerEditorResetEvent<T> | undefined): void;
29
- getEditorClose$(): Observable<ViewContainerEditorCloseEvent<T>>;
30
- closeEditor(event?: ViewContainerEditorCloseEvent<T>): void;
31
- getActionRouteTriggeredInstance(): ActionInstance<T, S> | undefined;
32
- setActionRouteTriggeredInstance(instance: ActionInstance<T, S>): void;
33
- unsetActionRouteTriggeredInstance(): void;
34
- static ɵfac: i0.ɵɵFactoryDeclaration<MngViewContainerComponentService<any, any>, never>;
35
- static ɵprov: i0.ɵɵInjectableDeclaration<MngViewContainerComponentService<any, any>>;
36
- }
File without changes