@mediusinc/mng-commons 3.0.0 → 3.1.0
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/esm2022/lib/components/form/formly/fields/formly-field-action/formly-field-action.component.mjs +3 -3
- package/esm2022/lib/descriptors/action/action.descriptor.mjs +1 -1
- package/esm2022/lib/services/action-executor.service.mjs +5 -3
- package/fesm2022/mediusinc-mng-commons.mjs +6 -4
- package/fesm2022/mediusinc-mng-commons.mjs.map +1 -1
- package/lib/descriptors/action/action.descriptor.d.ts +6 -6
- package/package.json +1 -1
|
@@ -37,8 +37,8 @@ export declare class ActionDescriptor<T> {
|
|
|
37
37
|
protected _hasRunNotificationError: boolean;
|
|
38
38
|
protected _runNotificationErrorTitle?: string;
|
|
39
39
|
protected _runNotificationErrorMessage?: string;
|
|
40
|
-
protected _afterRunAction?: ActionDescriptor<unknown
|
|
41
|
-
protected _onRunErrorAction?: ActionDescriptor<T
|
|
40
|
+
protected _afterRunAction?: ActionDescriptor<unknown> | ((ctx: ActionContext<T, any>) => ActionDescriptor<unknown>);
|
|
41
|
+
protected _onRunErrorAction?: ActionDescriptor<T> | ((ctx: ActionContext<T, any>) => ActionDescriptor<T>);
|
|
42
42
|
protected _permissions?: APermissions;
|
|
43
43
|
protected _button: ActionButtonDescriptor;
|
|
44
44
|
protected _hasItemsSelection: boolean;
|
|
@@ -71,8 +71,8 @@ export declare class ActionDescriptor<T> {
|
|
|
71
71
|
get hasRunNotificationError(): boolean;
|
|
72
72
|
get runNotificationErrorTitle(): string | undefined;
|
|
73
73
|
get runNotificationErrorMessage(): string | undefined;
|
|
74
|
-
get afterRunAction(): ActionDescriptor<unknown> | undefined;
|
|
75
|
-
get onRunErrorAction(): ActionDescriptor<T> | undefined;
|
|
74
|
+
get afterRunAction(): ActionDescriptor<unknown> | ((ctx: ActionContext<T, any>) => ActionDescriptor<unknown>) | undefined;
|
|
75
|
+
get onRunErrorAction(): ActionDescriptor<T> | ((ctx: ActionContext<T, any>) => ActionDescriptor<T>) | undefined;
|
|
76
76
|
get permissions(): APermissions | undefined;
|
|
77
77
|
get tableviewCategory(): string | undefined;
|
|
78
78
|
get hasItemsSelection(): boolean;
|
|
@@ -100,8 +100,8 @@ export declare class ActionDescriptor<T> {
|
|
|
100
100
|
withRunConfirmationDescriptor(runConfirmationDialogDescriptor: ActionConfirmationDialogDescriptor<T>): this;
|
|
101
101
|
withRunNotificationSuccess(title?: string, message?: string, hasNotification?: boolean): this;
|
|
102
102
|
withRunNotificationError(title?: string, message?: string, hasNotification?: boolean): this;
|
|
103
|
-
withAfterRunAction<RT>(action: ActionDescriptor<RT>): this;
|
|
104
|
-
withOnRunErrorAction(action: ActionDescriptor<T>): this;
|
|
103
|
+
withAfterRunAction<RT, S = any>(action: ActionDescriptor<RT> | ((ctx: ActionContext<T, S>) => ActionDescriptor<RT>)): this;
|
|
104
|
+
withOnRunErrorAction<S = any>(action: ActionDescriptor<T> | ((ctx: ActionContext<T, S>) => ActionDescriptor<T>)): this;
|
|
105
105
|
withPermissions(permissions: APermissions): this;
|
|
106
106
|
withTableviewCategory(permissionsRouteType: string): this;
|
|
107
107
|
withButtonDescriptor(button: ActionButtonDescriptor): this;
|