@mediusinc/mng-commons 5.0.0-rc.2 → 5.0.0-rc.4
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/core/data-providers/base-data-provider.factory.d.ts +13 -0
- package/core/data-providers/base.data-provider.d.ts +2 -14
- package/core/descriptors/editor.descriptor.d.ts +1 -1
- package/core/descriptors/tableview.descriptor.d.ts +5 -5
- package/core/directives/component.directive.d.ts +2 -2
- package/core/index.d.ts +1 -0
- package/core/security/permission.service.d.ts +1 -0
- package/core/services/commons-router.service.d.ts +3 -3
- package/core/services/commons.service.d.ts +31 -42
- package/core/services/tokens/module-config.token.d.ts +2 -2
- package/esm2022/core/components/notification/notification-wrapper.component.mjs +3 -3
- package/esm2022/core/components/pages/error/error.page.component.mjs +3 -3
- package/esm2022/core/components/pages/not-found/not-found.page.component.mjs +3 -3
- package/esm2022/core/data-providers/base-data-provider.factory.mjs +28 -0
- package/esm2022/core/data-providers/base.data-provider.mjs +1 -31
- package/esm2022/core/descriptors/editor.descriptor.mjs +1 -1
- package/esm2022/core/descriptors/tableview.descriptor.mjs +1 -1
- package/esm2022/core/directives/component.directive.mjs +10 -7
- package/esm2022/core/index.mjs +2 -1
- package/esm2022/core/security/permission.service.mjs +4 -2
- package/esm2022/core/services/commons-init.service.mjs +2 -2
- package/esm2022/core/services/commons-router.service.mjs +16 -15
- package/esm2022/core/services/commons.service.mjs +109 -166
- package/esm2022/core/services/tokens/module-config.token.mjs +1 -1
- package/esm2022/filter/descriptors/filter-lookup.descriptor.mjs +4 -4
- package/esm2022/form/api/data-providers/lookup-data-provider.factory.mjs +31 -0
- package/esm2022/form/api/data-providers/lookup.data-provider.mjs +1 -31
- package/esm2022/form/api/index.mjs +2 -1
- package/esm2022/form/components/autocomplete/autocomplete.component.mjs +92 -83
- package/esm2022/form/components/dropdown/dropdown.component.mjs +145 -87
- package/esm2022/model/data-providers/base-from-type-data-provider.factory.mjs +8 -0
- package/esm2022/model/descriptors/enum.descriptor.mjs +3 -6
- package/esm2022/model/descriptors/model.descriptor.mjs +22 -9
- package/esm2022/model/descriptors/type.descriptor.mjs +3 -9
- package/esm2022/model/index.mjs +3 -1
- package/esm2022/table/api/data-providers/table-data-provider.factory.mjs +33 -0
- package/esm2022/table/api/data-providers/table.data-provider.mjs +1 -31
- package/esm2022/table/api/descriptors/sort.descriptor.mjs +2 -2
- package/esm2022/table/api/descriptors/table-descriptor.factory.mjs +89 -0
- package/esm2022/table/api/descriptors/table.descriptor.mjs +4 -139
- package/esm2022/table/api/helpers/table-descriptor-helpers.mjs +97 -0
- package/esm2022/table/api/index.mjs +4 -1
- package/esm2022/table/components/column-filter-full/column-filter-full.component.mjs +6 -7
- package/esm2022/table/components/column-value/column-value.component.mjs +2 -2
- package/esm2022/table/components/table/table.component.mjs +5 -5
- package/esm2022/table/pipes/locale-default-row-class.pipe.mjs +2 -2
- package/esm2022/table/services/data-list.service.mjs +1 -1
- package/esm2022/tableview/action/components/action/action.component.mjs +140 -188
- package/esm2022/tableview/action/components/editor/action-editor.component.mjs +56 -66
- package/esm2022/tableview/action/components/editor/injector-context/action-editor-injector-context.component.mjs +119 -141
- package/esm2022/tableview/action/components/localization/data-language-dropdown.component.mjs +21 -39
- package/esm2022/tableview/action/components/route/action-route.component.mjs +17 -23
- package/esm2022/tableview/action/components/table/action-table.component.mjs +1 -1
- package/esm2022/tableview/action/services/action-executor.service.mjs +9 -9
- package/esm2022/tableview/action/services/navigation.service.mjs +3 -2
- package/esm2022/tableview/action/services/view-container.service.mjs +5 -21
- package/esm2022/tableview/api/action/descriptors/action-descriptor.factory.mjs +119 -0
- package/esm2022/tableview/api/action/descriptors/action-editor-descriptor.factory.mjs +77 -0
- package/esm2022/tableview/api/action/descriptors/action-editor.descriptor.mjs +20 -80
- package/esm2022/tableview/api/action/descriptors/action-link-descriptor.factory.mjs +45 -0
- package/esm2022/tableview/api/action/descriptors/action-link.descriptor.mjs +1 -32
- package/esm2022/tableview/api/action/descriptors/action.descriptor.mjs +3 -69
- package/esm2022/tableview/api/action/models/action-component.model.mjs +1 -1
- package/esm2022/tableview/api/action/models/execution/view-container.model.mjs +1 -1
- package/esm2022/tableview/api/editor/data-providers/editor-data-provider.factory.mjs +33 -0
- package/esm2022/tableview/api/editor/data-providers/editor.data-provider.mjs +1 -31
- package/esm2022/tableview/api/editor/descriptors/editor-descriptor.factory.mjs +81 -0
- package/esm2022/tableview/api/editor/descriptors/editor.descriptor.mjs +7 -133
- package/esm2022/tableview/api/editor/descriptors/field-action.descriptor.mjs +1 -1
- package/esm2022/tableview/api/editor/descriptors/field-base.descriptor.mjs +13 -5
- package/esm2022/tableview/api/editor/descriptors/field-group.descriptor.mjs +1 -1
- package/esm2022/tableview/api/editor/descriptors/field-lookup.descriptor.mjs +4 -4
- package/esm2022/tableview/api/editor/descriptors/field-many.descriptor.mjs +3 -3
- package/esm2022/tableview/api/editor/descriptors/field-validation.descriptor.mjs +1 -1
- package/esm2022/tableview/api/editor/descriptors/field.descriptor.mjs +1 -1
- package/esm2022/tableview/api/editor/helpers/editor-descriptor-helpers.mjs +95 -0
- package/esm2022/tableview/api/editor/helpers/field-validators.mjs +7 -7
- package/esm2022/tableview/api/editor/models/editor-fields.model.mjs +1 -1
- package/esm2022/tableview/api/editor/models/field-action-context.model.mjs +1 -1
- package/esm2022/tableview/api/editor/models/field-validation.model.mjs +2 -0
- package/esm2022/tableview/api/editor/models/field.model.mjs +1 -1
- package/esm2022/tableview/api/editor/models/form-editor.event.mjs +1 -1
- package/esm2022/tableview/api/editor/models/form-editor.interface.mjs +1 -1
- package/esm2022/tableview/api/editor/models/formly-field.model.mjs +1 -1
- package/esm2022/tableview/api/index.mjs +11 -1
- package/esm2022/tableview/api/tableview/data-providers/tableview-data-provider.factory.mjs +47 -0
- package/esm2022/tableview/api/tableview/data-providers/tableview.data-provider.mjs +5 -46
- package/esm2022/tableview/api/tableview/descriptors/tableview-descriptor.factory.mjs +111 -0
- package/esm2022/tableview/api/tableview/descriptors/tableview.descriptor.mjs +15 -168
- package/esm2022/tableview/api/tableview/helpers/files-export.mjs +2 -2
- package/esm2022/tableview/api/tableview/helpers/tableview-create.mjs +5 -5
- package/esm2022/tableview/api/tableview/helpers/tableview-default-actions.mjs +53 -18
- package/esm2022/tableview/api/tableview/helpers/tableview-descriptor-helpers.mjs +110 -0
- package/esm2022/tableview/api/tableview/helpers/tableview-input-builder.mjs +2 -2
- package/esm2022/tableview/editor/components/editor/form-editor.component.mjs +16 -11
- package/esm2022/tableview/editor/components/formly/fields/formly-field-action/formly-field-action.component.mjs +6 -2
- package/esm2022/tableview/editor/components/formly/fields/formly-field-autocomplete/formly-field-autocomplete.component.mjs +10 -11
- package/esm2022/tableview/editor/components/formly/fields/formly-field-custom/formly-field-custom.component.mjs +1 -1
- package/esm2022/tableview/editor/components/formly/fields/formly-field-datepicker/formly-field-datepicker.component.mjs +4 -4
- package/esm2022/tableview/editor/components/formly/fields/formly-field-dropdown/formly-field-dropdown.component.mjs +9 -11
- package/esm2022/tableview/editor/components/formly/fields/formly-field-input/formly-field-input.component.mjs +4 -4
- package/esm2022/tableview/editor/components/formly/fields/formly-field-lookup-dialog/formly-field-lookup-dialog.component.mjs +16 -18
- package/esm2022/tableview/editor/components/formly/fields/formly-field-table-dialog-form/formly-field-table-dialog-form.component.mjs +20 -22
- package/esm2022/tableview/editor/components/formly/fields/formly-field-table-dialog-multiselect/formly-field-table-dialog-multiselect.component.mjs +18 -20
- package/esm2022/tableview/editor/helpers/editor-formly.mjs +27 -6
- package/esm2022/tableview/editor/services/form-editor.service.mjs +96 -0
- package/esm2022/tableview/index.mjs +2 -1
- package/esm2022/tableview/tableview/components/tableview/tableview.component.mjs +3 -3
- package/fesm2022/mediusinc-mng-commons-core.mjs +155 -210
- package/fesm2022/mediusinc-mng-commons-core.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-filter.mjs +3 -3
- package/fesm2022/mediusinc-mng-commons-filter.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-form-api.mjs +18 -18
- package/fesm2022/mediusinc-mng-commons-form-api.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-form.mjs +236 -169
- package/fesm2022/mediusinc-mng-commons-form.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-model.mjs +43 -33
- package/fesm2022/mediusinc-mng-commons-model.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-table-api.mjs +192 -146
- package/fesm2022/mediusinc-mng-commons-table-api.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-table.mjs +11 -12
- package/fesm2022/mediusinc-mng-commons-table.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-tableview-api.mjs +822 -590
- package/fesm2022/mediusinc-mng-commons-tableview-api.mjs.map +1 -1
- package/fesm2022/mediusinc-mng-commons-tableview.mjs +564 -571
- package/fesm2022/mediusinc-mng-commons-tableview.mjs.map +1 -1
- package/form/api/data-providers/lookup-data-provider.factory.d.ts +18 -0
- package/form/api/data-providers/lookup.data-provider.d.ts +2 -14
- package/form/api/index.d.ts +1 -0
- package/form/components/autocomplete/autocomplete.component.d.ts +31 -23
- package/form/components/dropdown/dropdown.component.d.ts +38 -25
- package/model/data-providers/base-from-type-data-provider.factory.d.ts +8 -0
- package/model/descriptors/enum.descriptor.d.ts +1 -2
- package/model/descriptors/model.descriptor.d.ts +11 -4
- package/model/descriptors/type.descriptor.d.ts +2 -4
- package/model/index.d.ts +1 -0
- package/package.json +7 -7
- package/table/api/data-providers/table-data-provider.factory.d.ts +18 -0
- package/table/api/data-providers/table.data-provider.d.ts +2 -14
- package/table/api/descriptors/table-descriptor.factory.d.ts +44 -0
- package/table/api/descriptors/table.descriptor.d.ts +4 -65
- package/table/api/helpers/table-descriptor-helpers.d.ts +44 -0
- package/table/api/index.d.ts +3 -0
- package/table/components/column-filter-full/column-filter-full.component.d.ts +5 -4
- package/table/components/table/table.component.d.ts +11 -11
- package/table/services/data-list.service.d.ts +9 -10
- package/tableview/action/components/action/action.component.d.ts +37 -44
- package/tableview/action/components/editor/action-editor.component.d.ts +20 -18
- package/tableview/action/components/editor/injector-context/action-editor-injector-context.component.d.ts +23 -23
- package/tableview/action/components/localization/data-language-dropdown.component.d.ts +11 -14
- package/tableview/action/components/route/action-route.component.d.ts +6 -11
- package/tableview/action/components/table/action-table.component.d.ts +3 -3
- package/tableview/action/services/view-container.service.d.ts +3 -9
- package/tableview/api/action/descriptors/action-descriptor.factory.d.ts +36 -0
- package/tableview/api/action/descriptors/action-editor-descriptor.factory.d.ts +31 -0
- package/tableview/api/action/descriptors/action-editor.descriptor.d.ts +17 -37
- package/tableview/api/action/descriptors/action-link-descriptor.factory.d.ts +15 -0
- package/tableview/api/action/descriptors/action-link.descriptor.d.ts +1 -9
- package/tableview/api/action/descriptors/action.descriptor.d.ts +4 -27
- package/tableview/api/action/models/action-component.model.d.ts +8 -8
- package/tableview/api/action/models/execution/view-container.model.d.ts +4 -3
- package/tableview/api/editor/data-providers/editor-data-provider.factory.d.ts +18 -0
- package/tableview/api/editor/data-providers/editor.data-provider.d.ts +2 -14
- package/tableview/api/editor/descriptors/editor-descriptor.factory.d.ts +44 -0
- package/tableview/api/editor/descriptors/editor.descriptor.d.ts +34 -90
- package/tableview/api/editor/descriptors/field-action.descriptor.d.ts +3 -3
- package/tableview/api/editor/descriptors/field-base.descriptor.d.ts +15 -13
- package/tableview/api/editor/descriptors/field-group.descriptor.d.ts +7 -6
- package/tableview/api/editor/descriptors/field-lookup.descriptor.d.ts +2 -2
- package/tableview/api/editor/descriptors/field-many.descriptor.d.ts +8 -8
- package/tableview/api/editor/descriptors/field-validation.descriptor.d.ts +6 -6
- package/tableview/api/editor/descriptors/field.descriptor.d.ts +1 -1
- package/tableview/api/editor/helpers/editor-descriptor-helpers.d.ts +43 -0
- package/tableview/api/editor/helpers/field-validators.d.ts +1 -1
- package/tableview/api/editor/models/editor-fields.model.d.ts +24 -22
- package/tableview/api/editor/models/field-action-context.model.d.ts +10 -8
- package/tableview/api/editor/models/field-validation.model.d.ts +26 -0
- package/tableview/api/editor/models/field.model.d.ts +0 -19
- package/tableview/api/editor/models/form-editor.event.d.ts +24 -16
- package/tableview/api/editor/models/form-editor.interface.d.ts +2 -1
- package/tableview/api/editor/models/formly-custom-field.model.d.ts +1 -1
- package/tableview/api/editor/models/formly-field.model.d.ts +4 -4
- package/tableview/api/index.d.ts +10 -0
- package/tableview/api/tableview/data-providers/tableview-data-provider.factory.d.ts +25 -0
- package/tableview/api/tableview/data-providers/tableview.data-provider.d.ts +3 -20
- package/tableview/api/tableview/descriptors/tableview-descriptor.factory.d.ts +49 -0
- package/tableview/api/tableview/descriptors/tableview.descriptor.d.ts +40 -100
- package/tableview/api/tableview/helpers/tableview-create.d.ts +2 -2
- package/tableview/api/tableview/helpers/tableview-default-actions.d.ts +4 -2
- package/tableview/api/tableview/helpers/tableview-descriptor-helpers.d.ts +42 -0
- package/tableview/api/tableview/helpers/tableview-input-builder.d.ts +1 -1
- package/tableview/editor/components/editor/form-editor.component.d.ts +6 -4
- package/tableview/editor/components/formly/fields/formly-field-action/formly-field-action.component.d.ts +5 -3
- package/tableview/editor/components/formly/fields/formly-field-autocomplete/formly-field-autocomplete.component.d.ts +1 -0
- package/tableview/editor/components/formly/fields/formly-field-dropdown/formly-field-dropdown.component.d.ts +1 -1
- package/tableview/editor/components/formly/fields/formly-field-lookup-dialog/formly-field-lookup-dialog.component.d.ts +1 -1
- package/tableview/editor/components/formly/fields/formly-field-table-dialog-form/formly-field-table-dialog-form.component.d.ts +3 -4
- package/tableview/editor/components/formly/fields/formly-field-table-dialog-multiselect/formly-field-table-dialog-multiselect.component.d.ts +3 -4
- package/tableview/editor/helpers/editor-formly.d.ts +1 -1
- package/tableview/editor/services/form-editor.service.d.ts +39 -0
- package/tableview/index.d.ts +1 -0
- package/tableview/tableview/components/route/tableview-route.component.d.ts +1 -1
- package/tableview/tableview/components/tableview/tableview.component.d.ts +1 -1
- package/version-info.json +7 -7
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { ILookupDataProvider } from '@mediusinc/mng-commons/core';
|
|
2
|
+
import { FilterLookupDescriptor } from '@mediusinc/mng-commons/filter';
|
|
3
|
+
import { EnumDescriptor } from '@mediusinc/mng-commons/model';
|
|
4
|
+
import { ColumnDescriptor } from '../descriptors/column.descriptor';
|
|
5
|
+
import { TableDescriptorInst } from '../descriptors/table.descriptor';
|
|
6
|
+
import { TableClassAttributeDef } from '../models/class-table-attribute.model';
|
|
7
|
+
import { ColumnDisplayTypeEnum, ColumnTypeEnum } from '../models/column.model';
|
|
8
|
+
/**
|
|
9
|
+
* generates column based on attributes
|
|
10
|
+
* @param desc Table descriptor
|
|
11
|
+
* @param attribute attribute map
|
|
12
|
+
* @param column if provided, replaced by new, otherwise new is created
|
|
13
|
+
* @param args additional parameters
|
|
14
|
+
*/
|
|
15
|
+
export declare function upsertTableColumnFromAttributeDef<ColumnModel, TableModel>(desc: TableDescriptorInst<TableModel, any, any>, attribute: TableClassAttributeDef, column?: ColumnDescriptor<ColumnModel, TableModel>, ...args: any[]): ColumnDescriptor<ColumnModel, TableModel>;
|
|
16
|
+
/**
|
|
17
|
+
* defines modified type of column
|
|
18
|
+
* DO NOT USE with enum (use withCustomEnumType)
|
|
19
|
+
* @param descriptor table descriptor
|
|
20
|
+
* @param property column name
|
|
21
|
+
* @param columnType modified type
|
|
22
|
+
* @param args additional attributes
|
|
23
|
+
* @param columnDisplayType
|
|
24
|
+
*/
|
|
25
|
+
export declare function modifyTableClassAttributeColumnType<TableModel, Property extends keyof TableModel, ColumnModel = NonNullable<TableModel[Property]>, ColumnValue = TableModel[Property]>(descriptor: TableDescriptorInst<TableModel, any, any>, property: Property, columnType?: ColumnTypeEnum, columnDisplayType?: ColumnDisplayTypeEnum, ...args: any[]): ColumnDescriptor<ColumnModel, TableModel, ColumnValue> | null;
|
|
26
|
+
export declare function modifyTableClassAttributeColumnTypeUnsafe<TableModel, ColumnModel = any, ColumnValue = ColumnModel>(descriptor: TableDescriptorInst<TableModel, any, any>, property: string, columnType?: ColumnTypeEnum, columnDisplayType?: ColumnDisplayTypeEnum, ...args: any[]): ColumnDescriptor<ColumnModel, TableModel, ColumnValue> | null;
|
|
27
|
+
/**
|
|
28
|
+
* defines custom enum type for column
|
|
29
|
+
* @param descriptor table descriptor
|
|
30
|
+
* @param property column name
|
|
31
|
+
* @param enumDesc Enum descriptor.
|
|
32
|
+
*/
|
|
33
|
+
export declare function modifyTableClassAttributeColumnEnum<TableModel, Property extends keyof TableModel, Enum extends NonNullable<TableModel[Property]>, ColumnModel = NonNullable<TableModel[Property]>, ColumnValue = TableModel[Property]>(descriptor: TableDescriptorInst<TableModel, any, any>, property: Property, enumDesc?: EnumDescriptor<Enum>): ColumnDescriptor<ColumnModel, TableModel, ColumnValue> | null;
|
|
34
|
+
export declare function tableDescriptorModifyEnumColumnUnsafe<TableModel, Enum = any, ColumnModel = any, ColumnValue = ColumnModel>(descriptor: TableDescriptorInst<TableModel, any, any>, property: string, enumDesc?: EnumDescriptor<Enum>): ColumnDescriptor<ColumnModel, TableModel, ColumnValue> | null;
|
|
35
|
+
/**
|
|
36
|
+
* modifies column with class and lookup provider
|
|
37
|
+
* @param descriptor table descriptor
|
|
38
|
+
* @param property column name
|
|
39
|
+
* @param lookupProvider lookupProvider for class
|
|
40
|
+
* @param optionsLabelProperty
|
|
41
|
+
* @param filterProperty
|
|
42
|
+
*/
|
|
43
|
+
export declare function modifyTableColumnFilterLookup<TableModel, Property extends keyof TableModel, Service, ColumnModel = NonNullable<TableModel[Property]>>(descriptor: TableDescriptorInst<TableModel, any, any>, property: Property, lookupProvider?: ILookupDataProvider<ColumnModel, any>, optionsLabelProperty?: keyof ColumnModel, filterProperty?: keyof ColumnModel): FilterLookupDescriptor<ColumnModel, TableModel, Service> | null;
|
|
44
|
+
export declare function modifyTableColumnFilterLookupUnsafe<TableModel, Service, ColumnModel>(descriptor: TableDescriptorInst<TableModel, any, any>, property: string, lookupProvider?: ILookupDataProvider<ColumnModel, Service>, optionsLabelProperty?: string, filterProperty?: string): FilterLookupDescriptor<ColumnModel, TableModel, Service> | null;
|
package/table/api/index.d.ts
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
export * from './data-providers/table.data-provider';
|
|
2
|
+
export * from './data-providers/table-data-provider.factory';
|
|
2
3
|
export * from './descriptors/column.descriptor';
|
|
3
4
|
export * from './descriptors/sort.descriptor';
|
|
4
5
|
export * from './descriptors/table.descriptor';
|
|
6
|
+
export * from './descriptors/table-descriptor.factory';
|
|
5
7
|
export * from './helpers/class-attribute-converter';
|
|
8
|
+
export * from './helpers/table-descriptor-helpers';
|
|
6
9
|
export * from './models/class-table-attribute.model';
|
|
7
10
|
export * from './models/column.model';
|
|
8
11
|
export * from './models/column-value.model';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ElementRef, OnDestroy, OnInit
|
|
1
|
+
import { ElementRef, OnDestroy, OnInit } from '@angular/core';
|
|
2
2
|
import { FilterMetadata as PrimeFilterMetadata, SelectItem } from 'primeng/api';
|
|
3
3
|
import { Nullable } from 'primeng/ts-helpers';
|
|
4
4
|
import { FilterDescriptor, FilterLookupDescriptor, FilterLookupTypeEnum } from '@mediusinc/mng-commons/filter';
|
|
@@ -18,17 +18,18 @@ export declare class TableColumnFilterFullComponent implements OnInit, OnDestroy
|
|
|
18
18
|
private readonly primeConfig;
|
|
19
19
|
private readonly overlayService;
|
|
20
20
|
private readonly cd;
|
|
21
|
+
private readonly destroyRef;
|
|
21
22
|
private readonly document;
|
|
22
23
|
descriptor: FilterDescriptor<any, any>;
|
|
23
24
|
icon: Nullable<ElementRef>;
|
|
24
25
|
primeField: string;
|
|
25
26
|
primeType: string;
|
|
26
27
|
lookupDescriptor?: FilterLookupDescriptor<any, any>;
|
|
27
|
-
matchModes: WritableSignal<SelectItem[]>;
|
|
28
|
-
filterConstraint: WritableSignal<FilterMetadata | undefined>;
|
|
28
|
+
matchModes: import("@angular/core").WritableSignal<SelectItem<any>[]>;
|
|
29
|
+
filterConstraint: import("@angular/core").WritableSignal<FilterMetadata | undefined>;
|
|
29
30
|
isFilterSet: import("@angular/core").Signal<boolean>;
|
|
30
31
|
isInputDisabled: import("@angular/core").Signal<boolean>;
|
|
31
|
-
overlayVisible: WritableSignal<boolean>;
|
|
32
|
+
overlayVisible: import("@angular/core").WritableSignal<boolean>;
|
|
32
33
|
private overlaySubscription?;
|
|
33
34
|
private overlay;
|
|
34
35
|
private scrollHandler?;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EventEmitter, OnChanges, OnDestroy, OnInit, QueryList, Signal, SimpleChanges, TemplateRef, Type
|
|
1
|
+
import { EventEmitter, OnChanges, OnDestroy, OnInit, QueryList, Signal, SimpleChanges, TemplateRef, Type } from '@angular/core';
|
|
2
2
|
import { MultiSelectChangeEvent } from 'primeng/multiselect';
|
|
3
3
|
import { Table, TableColumnReorderEvent, TableLazyLoadEvent } from 'primeng/table';
|
|
4
4
|
import { Observable } from 'rxjs';
|
|
@@ -44,13 +44,13 @@ export declare class TableComponent<Item = any, Service = undefined, Sorts = any
|
|
|
44
44
|
footerTemplate: Signal<TemplateRef<any> | null>;
|
|
45
45
|
rowExpandTemplate: Signal<TemplateRef<any> | null>;
|
|
46
46
|
private useDataProvider;
|
|
47
|
-
isLazy: WritableSignal<boolean>;
|
|
48
|
-
isPagination: WritableSignal<boolean>;
|
|
49
|
-
useQueryParamsInitialized: WritableSignal<boolean>;
|
|
50
|
-
infiniteScroll: WritableSignal<boolean>;
|
|
51
|
-
className: WritableSignal<string>;
|
|
52
|
-
tableFullHeightOffset: WritableSignal<number | undefined>;
|
|
53
|
-
rowHeight: WritableSignal<number | undefined>;
|
|
47
|
+
isLazy: import("@angular/core").WritableSignal<boolean>;
|
|
48
|
+
isPagination: import("@angular/core").WritableSignal<boolean>;
|
|
49
|
+
useQueryParamsInitialized: import("@angular/core").WritableSignal<boolean>;
|
|
50
|
+
infiniteScroll: import("@angular/core").WritableSignal<boolean>;
|
|
51
|
+
className: import("@angular/core").WritableSignal<string>;
|
|
52
|
+
tableFullHeightOffset: import("@angular/core").WritableSignal<number | undefined>;
|
|
53
|
+
rowHeight: import("@angular/core").WritableSignal<number | undefined>;
|
|
54
54
|
private dataProviderService;
|
|
55
55
|
private dataProviderLatestLazyLoadEvent?;
|
|
56
56
|
private latestLazyLoadEventVersion;
|
|
@@ -59,8 +59,8 @@ export declare class TableComponent<Item = any, Service = undefined, Sorts = any
|
|
|
59
59
|
private dataProviderSubscription?;
|
|
60
60
|
private resultSubscription?;
|
|
61
61
|
private itemsSubscription?;
|
|
62
|
-
descriptor: WritableSignal<TableDescriptorInst<any, any, any>>;
|
|
63
|
-
columns: WritableSignal<ColumnWithPreferences[]>;
|
|
62
|
+
descriptor: import("@angular/core").WritableSignal<TableDescriptorInst<any, any, any>>;
|
|
63
|
+
columns: import("@angular/core").WritableSignal<ColumnWithPreferences[]>;
|
|
64
64
|
visibleColumns: Signal<ColumnWithPreferences[]>;
|
|
65
65
|
hasColumnFilters: Signal<boolean>;
|
|
66
66
|
private filterDescriptors;
|
|
@@ -68,7 +68,7 @@ export declare class TableComponent<Item = any, Service = undefined, Sorts = any
|
|
|
68
68
|
private isFilterChanged;
|
|
69
69
|
private isSortChanged;
|
|
70
70
|
anyColumnVisible: Signal<boolean>;
|
|
71
|
-
hasCustomLastColumn: WritableSignal<boolean>;
|
|
71
|
+
hasCustomLastColumn: import("@angular/core").WritableSignal<boolean>;
|
|
72
72
|
hasLastColumn: Signal<boolean>;
|
|
73
73
|
areColumnsReorderable: Signal<boolean>;
|
|
74
74
|
areColumnsToggleable: Signal<boolean>;
|
|
@@ -1,16 +1,15 @@
|
|
|
1
|
-
import { WritableSignal } from '@angular/core';
|
|
2
1
|
import { FilterMetadata, SortMeta } from 'primeng/api';
|
|
3
2
|
import * as i0 from "@angular/core";
|
|
4
3
|
export declare class DataListService<Item> {
|
|
5
|
-
sortMeta: WritableSignal<SortMeta[] | null>;
|
|
6
|
-
filterMeta: WritableSignal<Record<string, FilterMetadata>>;
|
|
7
|
-
rowsPerPageOptions: WritableSignal<number[]>;
|
|
8
|
-
rows: WritableSignal<number>;
|
|
9
|
-
offset: WritableSignal<number>;
|
|
10
|
-
globalFilterFields: WritableSignal<string[]>;
|
|
11
|
-
data: WritableSignal<Item[]>;
|
|
12
|
-
count: WritableSignal<number>;
|
|
13
|
-
loading: WritableSignal<boolean>;
|
|
4
|
+
sortMeta: import("@angular/core").WritableSignal<SortMeta[] | null>;
|
|
5
|
+
filterMeta: import("@angular/core").WritableSignal<Record<string, FilterMetadata>>;
|
|
6
|
+
rowsPerPageOptions: import("@angular/core").WritableSignal<number[]>;
|
|
7
|
+
rows: import("@angular/core").WritableSignal<number>;
|
|
8
|
+
offset: import("@angular/core").WritableSignal<number>;
|
|
9
|
+
globalFilterFields: import("@angular/core").WritableSignal<string[]>;
|
|
10
|
+
data: import("@angular/core").WritableSignal<Item[]>;
|
|
11
|
+
count: import("@angular/core").WritableSignal<number>;
|
|
12
|
+
loading: import("@angular/core").WritableSignal<boolean>;
|
|
14
13
|
static ɵfac: i0.ɵɵFactoryDeclaration<DataListService<any>, never>;
|
|
15
14
|
static ɵprov: i0.ɵɵInjectableDeclaration<DataListService<any>>;
|
|
16
15
|
}
|
|
@@ -1,73 +1,66 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { OnDestroy } from '@angular/core';
|
|
2
2
|
import { ActivatedRoute } from '@angular/router';
|
|
3
3
|
import { TranslateService } from '@ngx-translate/core';
|
|
4
4
|
import { MenuItem } from 'primeng/api';
|
|
5
5
|
import { Menu } from 'primeng/menu';
|
|
6
|
-
import { Observable } from 'rxjs';
|
|
7
6
|
import { ActionData, ActionParameters, DataListParams, IDataProvider, IdType, PermissionService } from '@mediusinc/mng-commons/core';
|
|
8
7
|
import { ActionDescriptorInst, ActionLinkDescriptorInst, IActionComponent } from '@mediusinc/mng-commons/tableview/api';
|
|
9
8
|
import { ActionInstance } from '../../models/execution/action-instance.model';
|
|
10
9
|
import { ActionExecutorService } from '../../services/action-executor.service';
|
|
11
10
|
import { ViewContainer } from '../../services/view-container.service';
|
|
12
11
|
import * as i0 from "@angular/core";
|
|
13
|
-
export declare class ActionComponent<Item = any, Service = undefined> implements
|
|
12
|
+
export declare class ActionComponent<Item = any, Service = undefined> implements OnDestroy {
|
|
14
13
|
private routeService;
|
|
15
14
|
private translate;
|
|
16
15
|
private authorization;
|
|
17
16
|
private actionExecutor;
|
|
18
17
|
private viewContainer;
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
private isVisibleSubject;
|
|
18
|
+
private readonly destroyRef;
|
|
19
|
+
action: import("@angular/core").InputSignal<ActionDescriptorInst<Item, Service>>;
|
|
20
|
+
item: import("@angular/core").InputSignal<Item | undefined>;
|
|
21
|
+
itemId: import("@angular/core").InputSignal<IdType | undefined>;
|
|
22
|
+
actionData: import("@angular/core").InputSignal<ActionData | undefined>;
|
|
23
|
+
dataListParams: import("@angular/core").InputSignal<DataListParams<string, string> | undefined>;
|
|
24
|
+
dataProvider: import("@angular/core").InputSignal<IDataProvider<Item, Service> | undefined>;
|
|
25
|
+
hostComponent: import("@angular/core").InputSignal<any>;
|
|
26
|
+
routeInit: import("@angular/core").InputSignal<ActivatedRoute | undefined>;
|
|
27
|
+
inputDisabled: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
28
|
+
inputLoading: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
29
|
+
selectedItems: import("@angular/core").InputSignal<Item[]>;
|
|
30
|
+
finish: import("@angular/core").OutputEmitterRef<ActionInstance<Item, Service>>;
|
|
31
|
+
subactionsMenu: import("@angular/core").Signal<Menu | undefined>;
|
|
32
|
+
hostClass: import("@angular/core").Signal<string>;
|
|
33
|
+
isHostHidden: import("@angular/core").Signal<boolean>;
|
|
34
|
+
loading: import("@angular/core").WritableSignal<boolean>;
|
|
37
35
|
private isVisibleSubscription?;
|
|
38
|
-
|
|
39
|
-
private isPermittedSubject;
|
|
36
|
+
isVisible: import("@angular/core").WritableSignal<boolean>;
|
|
40
37
|
private isPermittedSubscription?;
|
|
41
|
-
|
|
42
|
-
private isEnabledSubject;
|
|
38
|
+
isPermitted: import("@angular/core").WritableSignal<boolean>;
|
|
43
39
|
private isEnabledSubscription?;
|
|
44
|
-
|
|
45
|
-
private labelSubject;
|
|
40
|
+
isEnabled: import("@angular/core").WritableSignal<boolean>;
|
|
46
41
|
private labelSubscription?;
|
|
47
|
-
|
|
48
|
-
private tooltipSubject;
|
|
42
|
+
label: import("@angular/core").WritableSignal<string>;
|
|
49
43
|
private tooltipSubscription?;
|
|
50
|
-
|
|
51
|
-
actionLink
|
|
52
|
-
hasNoTitle: boolean
|
|
53
|
-
private
|
|
54
|
-
|
|
55
|
-
private
|
|
56
|
-
|
|
57
|
-
|
|
44
|
+
tooltip: import("@angular/core").WritableSignal<string>;
|
|
45
|
+
actionLink: import("@angular/core").Signal<ActionLinkDescriptorInst<Item> | undefined>;
|
|
46
|
+
hasNoTitle: import("@angular/core").Signal<boolean>;
|
|
47
|
+
private resultSubscription?;
|
|
48
|
+
private errorSubscription?;
|
|
49
|
+
private stateSubscription?;
|
|
50
|
+
private cmpInstSubscription?;
|
|
51
|
+
route: import("@angular/core").Signal<ActivatedRoute>;
|
|
52
|
+
routeData: import("@angular/core").Signal<import("@angular/router").Data | undefined>;
|
|
53
|
+
private routePermissions;
|
|
54
|
+
buttonClass: import("@angular/core").Signal<string>;
|
|
55
|
+
subactions: import("@angular/core").WritableSignal<MenuItem[]>;
|
|
58
56
|
private subactionSubscriptions;
|
|
59
|
-
actionOrSubactionHasRunConfirmation: boolean;
|
|
60
57
|
private instance?;
|
|
61
58
|
constructor(routeService: ActivatedRoute, translate: TranslateService, authorization: PermissionService, actionExecutor: ActionExecutorService, viewContainer: ViewContainer<Item, Service> | null);
|
|
62
|
-
ngOnInit(): void;
|
|
63
|
-
ngOnChanges(changes: SimpleChanges): void;
|
|
64
59
|
ngOnDestroy(): void;
|
|
65
60
|
triggerAction(action: ActionDescriptorInst<Item, Service>, parameters?: ActionParameters<Item>, event?: Event): void;
|
|
66
61
|
onCustomActionCmpInst(instance: IActionComponent<Item>): void;
|
|
67
|
-
private processSubactions;
|
|
68
62
|
private processSubscriptions;
|
|
63
|
+
private processSubactions;
|
|
69
64
|
static ɵfac: i0.ɵɵFactoryDeclaration<ActionComponent<any, any>, [null, null, null, null, { optional: true; }]>;
|
|
70
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ActionComponent<any, any>, "mng-action", never, { "action": { "alias": "action"; "required": true; }; "item": { "alias": "item"; "required": false; }; "itemId": { "alias": "itemId"; "required": false; }; "actionData": { "alias": "actionData"; "required": false; }; "dataListParams": { "alias": "dataListParams"; "required": false; }; "dataProvider": { "alias": "dataProvider"; "required": false; }; "hostComponent": { "alias": "hostComponent"; "required": false; }; "routeInit": { "alias": "route"; "required": false; }; "inputDisabled": { "alias": "disabled"; "required": false; }; "inputLoading": { "alias": "loading"; "required": false; }; "selectedItems": { "alias": "selectedItems"; "required": false; }; }, { "
|
|
71
|
-
static ngAcceptInputType_inputDisabled: unknown;
|
|
72
|
-
static ngAcceptInputType_inputLoading: unknown;
|
|
65
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ActionComponent<any, any>, "mng-action", never, { "action": { "alias": "action"; "required": true; "isSignal": true; }; "item": { "alias": "item"; "required": false; "isSignal": true; }; "itemId": { "alias": "itemId"; "required": false; "isSignal": true; }; "actionData": { "alias": "actionData"; "required": false; "isSignal": true; }; "dataListParams": { "alias": "dataListParams"; "required": false; "isSignal": true; }; "dataProvider": { "alias": "dataProvider"; "required": false; "isSignal": true; }; "hostComponent": { "alias": "hostComponent"; "required": false; "isSignal": true; }; "routeInit": { "alias": "route"; "required": false; "isSignal": true; }; "inputDisabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "inputLoading": { "alias": "loading"; "required": false; "isSignal": true; }; "selectedItems": { "alias": "selectedItems"; "required": false; "isSignal": true; }; }, { "finish": "finish"; }, never, never, true, never>;
|
|
73
66
|
}
|
|
@@ -1,31 +1,33 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Type } from '@angular/core';
|
|
2
|
+
import { DynamicDialogConfig } from 'primeng/dynamicdialog';
|
|
2
3
|
import { ActionData, IDataProvider, IdType } from '@mediusinc/mng-commons/core';
|
|
3
4
|
import { ActionEditorDescriptorInst } from '@mediusinc/mng-commons/tableview/api';
|
|
4
5
|
import { ActionEditorInjectorContextComponent, ActionEditorInjectorContextInputData } from './injector-context/action-editor-injector-context.component';
|
|
5
6
|
import * as i0 from "@angular/core";
|
|
6
7
|
import * as i1 from "@mediusinc/mng-commons/core";
|
|
7
|
-
export declare class ActionEditorComponent<T = any, S = any>
|
|
8
|
+
export declare class ActionEditorComponent<T = any, S = any> {
|
|
8
9
|
readonly injContextCmpType: Type<any>;
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
private readonly
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
10
|
+
readonly dialogConfig: DynamicDialogConfig<any> | null;
|
|
11
|
+
action: import("@angular/core").InputSignal<ActionEditorDescriptorInst<T, S>>;
|
|
12
|
+
private readonly dialogData;
|
|
13
|
+
private readonly isDialog;
|
|
14
|
+
readonly parentInjector: import("@angular/core").Injector | undefined;
|
|
15
|
+
itemId: import("@angular/core").InputSignal<IdType | undefined>;
|
|
16
|
+
item: import("@angular/core").InputSignal<T | undefined>;
|
|
17
|
+
actionData: import("@angular/core").InputSignal<ActionData | undefined>;
|
|
18
|
+
dataProvider: import("@angular/core").InputSignal<IDataProvider<T, S> | undefined>;
|
|
19
|
+
actionRun: import("@angular/core").OutputEmitterRef<T | null | undefined>;
|
|
20
|
+
actionCancel: import("@angular/core").OutputEmitterRef<T | null | undefined>;
|
|
19
21
|
private actionEditorWInjContextCmp?;
|
|
20
|
-
actionEditorWInjContextInputData
|
|
21
|
-
private
|
|
22
|
+
actionEditorWInjContextInputData: import("@angular/core").Signal<ActionEditorInjectorContextInputData<T, S>>;
|
|
23
|
+
private itemIdFirstUpdate;
|
|
24
|
+
private itemFirstUpdate;
|
|
22
25
|
get actionEditor(): ActionEditorInjectorContextComponent<T, S> | undefined;
|
|
23
|
-
get formEditorCmp(): import("@mediusinc/mng-commons/tableview").FormEditorComponent<any> | undefined;
|
|
24
|
-
|
|
25
|
-
ngOnChanges(changes: SimpleChanges): void;
|
|
26
|
+
get formEditorCmp(): import("@angular/core").Signal<import("@mediusinc/mng-commons/tableview").FormEditorComponent<any, any> | undefined> | undefined;
|
|
27
|
+
constructor();
|
|
26
28
|
onActionEditorWInjContextCmp(cmp: ActionEditorInjectorContextComponent<T, S>): void;
|
|
27
29
|
cancel(): void;
|
|
28
30
|
triggerSubmit(): void;
|
|
29
31
|
static ɵfac: i0.ɵɵFactoryDeclaration<ActionEditorComponent<any, any>, never>;
|
|
30
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ActionEditorComponent<any, any>, "mng-action-editor", never, { "action": { "alias": "action"; "required": true; }; "
|
|
32
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ActionEditorComponent<any, any>, "mng-action-editor", never, { "action": { "alias": "action"; "required": true; "isSignal": true; }; "itemId": { "alias": "itemId"; "required": false; "isSignal": true; }; "item": { "alias": "item"; "required": false; "isSignal": true; }; "actionData": { "alias": "actionData"; "required": false; "isSignal": true; }; "dataProvider": { "alias": "dataProvider"; "required": false; "isSignal": true; }; }, { "actionRun": "actionRun"; "actionCancel": "actionCancel"; }, never, never, true, [{ directive: typeof i1.DialogKeydownHandlerDirective; inputs: {}; outputs: {}; }]>;
|
|
31
33
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { OnDestroy, OnInit } from '@angular/core';
|
|
2
2
|
import { DynamicDialogConfig } from 'primeng/dynamicdialog';
|
|
3
3
|
import { Observable } from 'rxjs';
|
|
4
4
|
import { ActionData, IDataProvider, IdType } from '@mediusinc/mng-commons/core';
|
|
@@ -9,8 +9,6 @@ import * as i0 from "@angular/core";
|
|
|
9
9
|
export declare class ActionEditorInjectorContextComponent<Item = any, Service = any> implements OnInit, OnDestroy, IActionEditorComponent {
|
|
10
10
|
protected readonly ActionActivationTriggerEnum: typeof ActionActivationTriggerEnum;
|
|
11
11
|
readonly actionEditorSubmitTypeSubmit = ActionEditorSubmitTypeEnum.Submit;
|
|
12
|
-
private readonly destroyRef;
|
|
13
|
-
private readonly route;
|
|
14
12
|
private readonly translate;
|
|
15
13
|
private readonly confirmationService;
|
|
16
14
|
private readonly dialogService;
|
|
@@ -18,27 +16,32 @@ export declare class ActionEditorInjectorContextComponent<Item = any, Service =
|
|
|
18
16
|
private readonly commonsService;
|
|
19
17
|
private readonly actionExecutor;
|
|
20
18
|
private readonly viewContainer;
|
|
21
|
-
data: ActionEditorInjectorContextInputData<Item, Service
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
title: WritableSignal<string | undefined>;
|
|
27
|
-
isFormDisabled: WritableSignal<boolean>;
|
|
28
|
-
item: WritableSignal<Item | undefined>;
|
|
29
|
-
itemId: WritableSignal<IdType | undefined>;
|
|
30
|
-
actionData: WritableSignal<ActionData | undefined>;
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
19
|
+
data: import("@angular/core").InputSignal<ActionEditorInjectorContextInputData<Item, Service>>;
|
|
20
|
+
actionRun: import("@angular/core").OutputEmitterRef<Item | null | undefined>;
|
|
21
|
+
actionCancel: import("@angular/core").OutputEmitterRef<Item | null | undefined>;
|
|
22
|
+
formEditorCmp: import("@angular/core").Signal<FormEditorComponent<any, any> | undefined>;
|
|
23
|
+
private hasTitle;
|
|
24
|
+
title: import("@angular/core").WritableSignal<string | undefined>;
|
|
25
|
+
isFormDisabled: import("@angular/core").WritableSignal<boolean>;
|
|
26
|
+
item: import("@angular/core").WritableSignal<Item | undefined>;
|
|
27
|
+
itemId: import("@angular/core").WritableSignal<IdType | undefined>;
|
|
28
|
+
actionData: import("@angular/core").WritableSignal<ActionData | undefined>;
|
|
29
|
+
editorAction: import("@angular/core").WritableSignal<ActionEditorDescriptorInst<Item, Service>>;
|
|
30
|
+
private actions;
|
|
31
|
+
toolbarLeftActions: import("@angular/core").Signal<ActionDescriptorInst<Item, any>[]>;
|
|
32
|
+
toolbarRightActions: import("@angular/core").Signal<ActionDescriptorInst<Item, any>[]>;
|
|
33
|
+
footerLeftActions: import("@angular/core").Signal<ActionDescriptorInst<Item, any>[]>;
|
|
34
|
+
footerRightActions: import("@angular/core").Signal<ActionDescriptorInst<Item, any>[]>;
|
|
35
35
|
private instance?;
|
|
36
36
|
private instanceStateSubscription?;
|
|
37
37
|
private instanceReactivationSubscription?;
|
|
38
|
-
|
|
38
|
+
private dataProvider;
|
|
39
|
+
loading: import("@angular/core").WritableSignal<boolean>;
|
|
39
40
|
private fetchExecutionSubscription?;
|
|
40
|
-
submitLoading: WritableSignal<boolean>;
|
|
41
|
+
submitLoading: import("@angular/core").WritableSignal<boolean>;
|
|
41
42
|
private submitExecutionSubscription?;
|
|
43
|
+
private lastSubmitItem?;
|
|
44
|
+
private titleSubscription?;
|
|
42
45
|
constructor();
|
|
43
46
|
ngOnInit(): void;
|
|
44
47
|
ngOnDestroy(): void;
|
|
@@ -47,10 +50,7 @@ export declare class ActionEditorInjectorContextComponent<Item = any, Service =
|
|
|
47
50
|
updateItemId(itemId: IdType | undefined): void;
|
|
48
51
|
updateItem(item: Item | undefined): void;
|
|
49
52
|
triggerSubmit(): void;
|
|
50
|
-
private initializeSubActions;
|
|
51
53
|
private fetchItem;
|
|
52
|
-
private updateTitle;
|
|
53
|
-
private placeActionsOnPositions;
|
|
54
54
|
private setEditorEnabled;
|
|
55
55
|
private processActionInstance;
|
|
56
56
|
private unsetInstance;
|
|
@@ -59,7 +59,7 @@ export declare class ActionEditorInjectorContextComponent<Item = any, Service =
|
|
|
59
59
|
closeWithUnsavedChangesConfirmation(callFromGuard?: boolean): Observable<boolean>;
|
|
60
60
|
private showUnsavedChangesConfirmationDialog;
|
|
61
61
|
static ɵfac: i0.ɵɵFactoryDeclaration<ActionEditorInjectorContextComponent<any, any>, never>;
|
|
62
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<ActionEditorInjectorContextComponent<any, any>, "mng-action-editor-injector-context", never, { "data": { "alias": "data"; "required": true; }; }, { "
|
|
62
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ActionEditorInjectorContextComponent<any, any>, "mng-action-editor-injector-context", never, { "data": { "alias": "data"; "required": true; "isSignal": true; }; }, { "actionRun": "actionRun"; "actionCancel": "actionCancel"; }, never, never, true, never>;
|
|
63
63
|
}
|
|
64
64
|
export interface ActionEditorInjectorContextInputData<Item, Service> {
|
|
65
65
|
descriptor: ActionEditorDescriptorInst<Item, Service>;
|
|
@@ -1,22 +1,19 @@
|
|
|
1
|
-
import { EventEmitter } from '@angular/core';
|
|
2
1
|
import { ActionData, ActionParameters, CommonsService, IdType } from '@mediusinc/mng-commons/core';
|
|
3
2
|
import { LookupDataProviderInst } from '@mediusinc/mng-commons/form/api';
|
|
4
3
|
import { ActionDescriptorInst, IActionComponent } from '@mediusinc/mng-commons/tableview/api';
|
|
5
4
|
import * as i0 from "@angular/core";
|
|
6
5
|
export declare class DataLanguageDropdownComponent<T = any> implements IActionComponent<T> {
|
|
7
|
-
commons: CommonsService;
|
|
8
6
|
private readonly viewContainer;
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
selectionItemsDataProvider: LookupDataProviderInst<string
|
|
18
|
-
|
|
19
|
-
updateDataLanguage(dataLang: string): void;
|
|
7
|
+
readonly commons: CommonsService;
|
|
8
|
+
action: import("@angular/core").InputSignal<ActionDescriptorInst<T, any>>;
|
|
9
|
+
actionData: import("@angular/core").InputSignal<ActionData>;
|
|
10
|
+
item: import("@angular/core").InputSignal<T>;
|
|
11
|
+
itemId: import("@angular/core").InputSignal<IdType>;
|
|
12
|
+
enabled: import("@angular/core").InputSignal<boolean>;
|
|
13
|
+
loading: import("@angular/core").InputSignal<boolean>;
|
|
14
|
+
trigger: import("@angular/core").OutputEmitterRef<ActionParameters<T>>;
|
|
15
|
+
selectionItemsDataProvider: import("@angular/core").Signal<LookupDataProviderInst<string, any, import("@mediusinc/mng-commons/core").ClassOptType<string>, import("@mediusinc/mng-commons/core").ServiceClassOptType<any>>>;
|
|
16
|
+
updateDataLocale(dataLang: string): void;
|
|
20
17
|
static ɵfac: i0.ɵɵFactoryDeclaration<DataLanguageDropdownComponent<any>, never>;
|
|
21
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<DataLanguageDropdownComponent<any>, "mng-data-language-dropdown", never, { "action": { "alias": "action"; "required": true; }; "actionData": { "alias": "actionData"; "required": true; }; "item": { "alias": "item"; "required": true; }; "itemId": { "alias": "itemId"; "required": true; }; "enabled": { "alias": "enabled"; "required": true; }; "loading": { "alias": "loading"; "required": true; }; }, { "
|
|
18
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<DataLanguageDropdownComponent<any>, "mng-data-language-dropdown", never, { "action": { "alias": "action"; "required": true; "isSignal": true; }; "actionData": { "alias": "actionData"; "required": true; "isSignal": true; }; "item": { "alias": "item"; "required": true; "isSignal": true; }; "itemId": { "alias": "itemId"; "required": true; "isSignal": true; }; "enabled": { "alias": "enabled"; "required": true; "isSignal": true; }; "loading": { "alias": "loading"; "required": true; "isSignal": true; }; }, { "trigger": "trigger"; }, never, never, true, never>;
|
|
22
19
|
}
|
|
@@ -1,23 +1,18 @@
|
|
|
1
1
|
import { OnDestroy, OnInit } from '@angular/core';
|
|
2
|
-
import { ActivatedRoute, Router } from '@angular/router';
|
|
3
2
|
import { Observable } from 'rxjs';
|
|
4
3
|
import { CanComponentDeactivate } from '../../models/can-component-deactivate.model';
|
|
5
|
-
import { ActionExecutorService } from '../../services/action-executor.service';
|
|
6
|
-
import { ViewContainer } from '../../services/view-container.service';
|
|
7
4
|
import * as i0 from "@angular/core";
|
|
8
5
|
export default class ActionRouteComponent<Item, Service> implements OnInit, OnDestroy, CanComponentDeactivate {
|
|
9
|
-
private router;
|
|
10
|
-
private route;
|
|
11
|
-
private actionExecutor;
|
|
12
|
-
private viewContainer
|
|
13
|
-
|
|
6
|
+
private readonly router;
|
|
7
|
+
private readonly route;
|
|
8
|
+
private readonly actionExecutor;
|
|
9
|
+
private readonly viewContainer?;
|
|
10
|
+
private readonly destroyRef;
|
|
14
11
|
private actions;
|
|
15
12
|
private instance?;
|
|
16
13
|
private instanceStateSubscription?;
|
|
17
14
|
private instanceReactivationSubscription?;
|
|
18
|
-
private subscriptions;
|
|
19
15
|
private isRouterNavigationInProgress;
|
|
20
|
-
constructor(router: Router, route: ActivatedRoute, actionExecutor: ActionExecutorService, viewContainer: ViewContainer<Item, Service> | null);
|
|
21
16
|
ngOnInit(): void;
|
|
22
17
|
ngOnDestroy(): void;
|
|
23
18
|
private activateAction;
|
|
@@ -26,6 +21,6 @@ export default class ActionRouteComponent<Item, Service> implements OnInit, OnDe
|
|
|
26
21
|
private processActionInstance;
|
|
27
22
|
canDeactivate(): Observable<boolean>;
|
|
28
23
|
private unsetInstance;
|
|
29
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<ActionRouteComponent<any, any>,
|
|
24
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ActionRouteComponent<any, any>, never>;
|
|
30
25
|
static ɵcmp: i0.ɵɵComponentDeclaration<ActionRouteComponent<any, any>, "mng-action-route", never, {}, {}, never, never, true, never>;
|
|
31
26
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EventEmitter, OnInit, QueryList, Signal, TemplateRef, Type
|
|
1
|
+
import { EventEmitter, OnInit, QueryList, Signal, TemplateRef, Type } from '@angular/core';
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
3
|
import { ComponentDirective, DataListResult, TemplateDirective } from '@mediusinc/mng-commons/core';
|
|
4
4
|
import { TableComponent } from '@mediusinc/mng-commons/table';
|
|
@@ -33,8 +33,8 @@ export declare class ActionTableComponent<Item = any, Service = undefined, Sorts
|
|
|
33
33
|
captionTemplate: Signal<TemplateRef<any> | null>;
|
|
34
34
|
footerTemplate: Signal<TemplateRef<any> | null>;
|
|
35
35
|
rowExpandTemplate: Signal<TemplateRef<any> | null>;
|
|
36
|
-
rowClickActions: WritableSignal<ActionDescriptorInst<Item>[]>;
|
|
37
|
-
rowInlineActions: WritableSignal<ActionDescriptorInst<Item>[]>;
|
|
36
|
+
rowClickActions: import("@angular/core").WritableSignal<ActionDescriptorInst<Item, any>[]>;
|
|
37
|
+
rowInlineActions: import("@angular/core").WritableSignal<ActionDescriptorInst<Item, any>[]>;
|
|
38
38
|
constructor();
|
|
39
39
|
ngOnInit(): void;
|
|
40
40
|
reload(emitEvent?: boolean, resetParams?: boolean): void;
|
|
@@ -7,24 +7,18 @@ import * as i0 from "@angular/core";
|
|
|
7
7
|
* Should be used with providers defined within component.
|
|
8
8
|
*/
|
|
9
9
|
export declare class ViewContainer<Item, Service = undefined> implements IViewContainer<Item, Service, ActionInstance<Item, Service>> {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
10
|
+
dataProvider: import("@angular/core").WritableSignal<IDataProvider<Item, Service> | undefined>;
|
|
11
|
+
routeTriggeredActionInstance: import("@angular/core").WritableSignal<ActionInstance<Item, Service> | undefined>;
|
|
12
|
+
actions: import("@angular/core").WritableSignal<ActionDescriptorInst<Item, any>[]>;
|
|
13
13
|
private _tableReloadSubject;
|
|
14
14
|
private _editorResetSubject;
|
|
15
15
|
private _editorCloseSubject;
|
|
16
|
-
set dataProvider(dataProvider: IDataProvider<Item, Service>);
|
|
17
|
-
get dataProvider(): IDataProvider<Item, Service> | undefined;
|
|
18
|
-
get actions(): Array<ActionDescriptorInst<Item>>;
|
|
19
|
-
set actions(actions: Array<ActionDescriptorInst<Item>>);
|
|
20
16
|
get tableReload$(): Observable<ViewContainerTableReloadEvent>;
|
|
21
17
|
reloadTable(event?: ViewContainerTableReloadEvent): void;
|
|
22
18
|
get editorReset$(): Observable<ViewContainerEditorResetEvent<Item>>;
|
|
23
19
|
resetEditor(event?: ViewContainerEditorResetEvent<Item> | undefined): void;
|
|
24
20
|
get editorClose$(): Observable<ViewContainerEditorCloseEvent<Item>>;
|
|
25
21
|
closeEditor(event?: ViewContainerEditorCloseEvent<Item>): void;
|
|
26
|
-
get routeTriggeredActionInstance(): ActionInstance<Item, Service> | undefined;
|
|
27
|
-
set routeTriggeredActionInstance(instance: ActionInstance<Item, Service> | undefined);
|
|
28
22
|
static ɵfac: i0.ɵɵFactoryDeclaration<ViewContainer<any, any>, never>;
|
|
29
23
|
static ɵprov: i0.ɵɵInjectableDeclaration<ViewContainer<any, any>>;
|
|
30
24
|
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { ClassType, IDataProvider, ServiceClassType } from '@mediusinc/mng-commons/core';
|
|
2
|
+
import { ModelDescriptor, TypeDescriptor } from '@mediusinc/mng-commons/model';
|
|
3
|
+
import { ActionDeleteDescriptorInst, ActionDescriptorCreateOptsParentType, ActionDescriptorCreateOptsProviderType, ActionDescriptorInst } from './action.descriptor';
|
|
4
|
+
export type ActionDescriptorCreateFromClassOpts<Model> = ActionDescriptorCreateOptsModel<Model> & ActionDescriptorCreateOptsI18nType & ActionDescriptorCreateOptsParentType;
|
|
5
|
+
export type ActionDescriptorCreateOptsI18nType = {
|
|
6
|
+
i18nBaseKey?: string | ClassType<any>;
|
|
7
|
+
};
|
|
8
|
+
export type ActionDescriptorCreateOptsModel<Model> = {
|
|
9
|
+
idProperty?: keyof Model;
|
|
10
|
+
titleProperty?: keyof Model;
|
|
11
|
+
};
|
|
12
|
+
export type ActionProviderType<Model, Service> = ServiceClassType<Service> | IDataProvider<Model, Service>;
|
|
13
|
+
export declare const actionGetProviderCfgObj: <Model, Service>(serviceOrDataProvider?: ActionProviderType<Model, Service>) => ActionDescriptorCreateOptsProviderType<Model, Service>;
|
|
14
|
+
export declare class ActionDescriptor extends ActionDescriptorInst<any> {
|
|
15
|
+
protected constructor();
|
|
16
|
+
static create<Model>(actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, undefined>;
|
|
17
|
+
static createWithProvider<Model, Service>(serviceProvider: ActionProviderType<Model, Service>, actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, Service>;
|
|
18
|
+
static fromModel<Model>(model: ModelDescriptor<Model>, actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, undefined>;
|
|
19
|
+
static fromModelWithProvider<Model, Service>(model: ModelDescriptor<Model>, serviceProvider: ActionProviderType<Model, Service>, actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, Service>;
|
|
20
|
+
static fromClass<Model>(type: ClassType<Model>, actionName: string, cfg?: ActionDescriptorCreateFromClassOpts<Model>): ActionDescriptorInst<Model, undefined>;
|
|
21
|
+
static fromClassWithProvider<Model, Service>(type: ClassType<Model>, serviceProvider: ActionProviderType<Model, Service>, actionName: string, cfg?: ActionDescriptorCreateFromClassOpts<Model>): ActionDescriptorInst<Model, Service>;
|
|
22
|
+
}
|
|
23
|
+
export declare function action<Model>(actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, undefined>;
|
|
24
|
+
export declare function action<Model>(type: TypeDescriptor<Model>, actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, undefined>;
|
|
25
|
+
export declare function actionWithProvider<Model, Service>(serviceProvider: ActionProviderType<Model, Service>, actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, Service>;
|
|
26
|
+
export declare function actionWithProvider<Model, Service>(type: TypeDescriptor<Model>, serviceProvider: ActionProviderType<Model, Service>, actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, Service>;
|
|
27
|
+
export declare function actionFromModel<Model>(model: ModelDescriptor<Model>, actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, undefined>;
|
|
28
|
+
export declare function actionFromModel<Model, Service>(model: ModelDescriptor<Model>, serviceProvider: ActionProviderType<Model, Service>, actionName: string, cfg?: ActionDescriptorCreateOptsParentType): ActionDescriptorInst<Model, Service>;
|
|
29
|
+
export declare function actionFromClass<Model>(type: ClassType<Model>, actionName: string, cfg?: ActionDescriptorCreateFromClassOpts<Model>): ActionDescriptorInst<Model, undefined>;
|
|
30
|
+
export declare function actionFromClass<Model, Service>(type: ClassType<Model>, serviceProvider: ActionProviderType<Model, Service>, actionName: string, cfg?: ActionDescriptorCreateFromClassOpts<Model>): ActionDescriptorInst<Model, Service>;
|
|
31
|
+
export declare class ActionDeleteDescriptor {
|
|
32
|
+
static create<Model>(model: ModelDescriptor<Model>): ActionDeleteDescriptorInst<Model, undefined>;
|
|
33
|
+
static createWithProvider<Model, Service>(model: ModelDescriptor<Model>, serviceProvider: ActionProviderType<Model, Service>): ActionDeleteDescriptorInst<Model, Service>;
|
|
34
|
+
}
|
|
35
|
+
export declare function actionDelete<Model>(model: ModelDescriptor<Model>): ActionDeleteDescriptorInst<Model, undefined>;
|
|
36
|
+
export declare function actionDelete<Model, Service>(model: ModelDescriptor<Model>, serviceProvider: ActionProviderType<Model, Service>): ActionDeleteDescriptorInst<Model, Service>;
|