@acorex/platform 20.9.27 → 20.9.29
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/fesm2022/acorex-platform-layout-entity-contracts.mjs +35 -15
- package/fesm2022/acorex-platform-layout-entity-contracts.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-entity.mjs +59 -15
- package/fesm2022/acorex-platform-layout-entity.mjs.map +1 -1
- package/fesm2022/acorex-platform-layout-widgets.mjs +188 -170
- package/fesm2022/acorex-platform-layout-widgets.mjs.map +1 -1
- package/package.json +1 -1
- package/types/acorex-platform-layout-entity-contracts.d.ts +25 -9
- package/types/acorex-platform-layout-entity.d.ts +4 -0
package/package.json
CHANGED
|
@@ -772,18 +772,25 @@ interface AXPLookupWidgetOptions {
|
|
|
772
772
|
rowActions?: AXPLookupSelectorRowActionsConfig;
|
|
773
773
|
}
|
|
774
774
|
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
775
|
+
/** Optional permission keys applied to CRUD actions created by the helpers below. */
|
|
776
|
+
interface AXPEntityCrudActionPermissions {
|
|
777
|
+
create?: string[];
|
|
778
|
+
delete?: string[];
|
|
779
|
+
view?: string[];
|
|
780
|
+
edit?: string[];
|
|
781
|
+
}
|
|
782
|
+
declare function entityMasterCreateAction(permissions?: string[]): AXPEntityAction;
|
|
783
|
+
declare function entityMasterEditAction(permissions?: string[]): AXPEntityAction;
|
|
784
|
+
declare function entityMasterBulkDeleteAction(permissions?: string[]): AXPEntityAction;
|
|
785
|
+
declare function entityMasterViewAction(permissions?: string[]): AXPEntityAction;
|
|
786
|
+
declare function entityMasterDeleteAction(permissions?: string[]): AXPEntityAction;
|
|
780
787
|
declare function entityMasterCrudActions(options?: {
|
|
781
788
|
create?: boolean;
|
|
782
789
|
delete?: boolean;
|
|
783
790
|
view?: boolean;
|
|
784
791
|
edit?: boolean;
|
|
785
|
-
}): AXPEntityAction[];
|
|
786
|
-
declare function entityMasterRecordActions(): AXPEntityAction[];
|
|
792
|
+
}, permissions?: AXPEntityCrudActionPermissions): AXPEntityAction[];
|
|
793
|
+
declare function entityMasterRecordActions(permissions?: string[]): AXPEntityAction[];
|
|
787
794
|
declare function entityDetailsCreateActions(parentId: string): AXPEntityAction;
|
|
788
795
|
declare function entityDetailsCreateActionsDeferredParent(): AXPEntityAction;
|
|
789
796
|
declare function mergeForeignKeyFieldIntoCreateActions(foreignKeyField: string | undefined, actions: AXPEntityAction[] | undefined): AXPEntityAction[];
|
|
@@ -801,6 +808,15 @@ declare function entityDetailsCrudActions(parentId?: string, options?: {
|
|
|
801
808
|
}): AXPEntityAction[];
|
|
802
809
|
declare function entityDetailsReferenceCreateActions(type: string): AXPEntityAction[];
|
|
803
810
|
|
|
811
|
+
/**
|
|
812
|
+
* Returns whether an entity action is permitted for the current session.
|
|
813
|
+
* Empty / missing `permissions` keeps the action visible (migration-safe).
|
|
814
|
+
* When keys are present, all must pass (AND), matching {@link AXPSessionService.authorize}.
|
|
815
|
+
*/
|
|
816
|
+
declare function isEntityActionPermitted(action: {
|
|
817
|
+
permissions?: string[] | null;
|
|
818
|
+
}, authorize: (...keys: string[]) => boolean): boolean;
|
|
819
|
+
|
|
804
820
|
/**
|
|
805
821
|
* Normalizes display templates before expression evaluation.
|
|
806
822
|
* Converts simple dot paths (e.g. `{{ position.title }}`) to `context.eval("position.title")`.
|
|
@@ -987,5 +1003,5 @@ declare const AXPEntityEventsKeys: {
|
|
|
987
1003
|
readonly REFRESH_DATA: "entity:refresh-data";
|
|
988
1004
|
};
|
|
989
1005
|
|
|
990
|
-
export { AXPEntityCommandScope, AXPEntityDataSourceKeys, AXPEntityEventsKeys, AXPEntityQueryType, AXPEntityType, AXPRelationshipCardinality, AXPRelationshipKind, AXP_RECORD_WORKFLOW_INFO_CORRELATION_ID_FIELD, AXP_RECORD_WORKFLOW_INFO_DEFINITION_ID_FIELD, AXP_RECORD_WORKFLOW_INFO_INSTANCE_ID_FIELD, ENTITY_LAYOUT_SINGLE_TITLE_PATH, ENTITY_ROW_POPUP_TITLE_OPTION, ENTITY_ROW_TITLE_TEMPLATE_OPTION, PAGE_LIST_WIDGET_NAME_PREFIX, buildAXPRecordWorkflowInfo, buildEntitySearchTitleContext, buildPageListTableWidgetId, buildPageListWidgetName, collectEntityListFilterDefinitions, collectEntityListSortableFields, collectEntityQuickSearchFieldPaths, collectMergeDetailListPropertyNames, collectNestedCreateHiddenProperties, collectNestedFieldPathsFromEntityColumns, collectPropertyExposeTargetPaths, collectQuickSearchPathsFromSingleEntityDefinition, createAllQueryView, createQueryView, encodeEntityListFilterContextField, entityDetailsCreateActions, entityDetailsCreateActionsDeferredParent, entityDetailsCrudActions, entityDetailsEditAction, entityDetailsNewEditAction, entityDetailsReferenceCondition, entityDetailsReferenceCreateActions, entityDetailsSimpleCondition, entityMasterBulkDeleteAction, entityMasterCreateAction, entityMasterCrudActions, entityMasterDeleteAction, entityMasterEditAction, entityMasterRecordActions, entityMasterViewAction, entityOverrideDetailsViewAction, getEntityInfo, getRecordWorkflowCorrelationId, getRecordWorkflowInstanceId, isCardFieldBadgeDisplay, isEntityPropertySortEnabled, isMeaningfulEntityDisplayTitle, isPageListWidgetName, isRowBoundEntityDisplayTemplate, isUnresolvedEntityDisplayTemplate, mergeForeignKeyFieldIntoCreateActions, normalizeEntityDisplayTemplate, normalizeExpressionTemplate, parseDottedFieldPath, parsePropertyExposeEntries, parseRelatedEntityFullName, resolveCardFieldBadgeColor, resolveDefaultMasterListLayout, resolveEnabledMasterListLayouts, resolveEntityColumnDataPath, resolveEntityListFilterContextField, resolveEntityListFilterQueryField, resolveEntityModifyRecordTitleTemplate, resolveEntityPropertyInlineFilterField, resolveEntityRowTitleTemplate, resolveLookupWidgetCreateOptions, resolvePropertyExposeDisplayTarget, sanitizeResolvedEntityDisplayTitle };
|
|
991
|
-
export type { AXEntityPropertyWidget, AXPAggregate, AXPApplication, AXPAuditEvent, AXPBuildEntityListFilterDefinitionsDeps, AXPCardBadgeColor, AXPCardBadgeDisplay, AXPCardBadgeDisplayOptions, AXPCardField, AXPCardFieldDisplay, AXPCardFieldDisplayConfig, AXPCollectEntityQuickSearchPathsResolver, AXPColumnAlign, AXPColumnContentAlign, AXPCommandActionCallback, AXPCommandActionDisplay, AXPCommandActionLook, AXPCommandActionPriority, AXPCommandActionType, AXPEntity, AXPEntityAction, AXPEntityAggregateMeasure, AXPEntityAggregateOptions, AXPEntityAggregateReducerType, AXPEntityAggregateRequest, AXPEntityAggregateResult, AXPEntityCategoryPlugin, AXPEntityCommand, AXPEntityCreateDto, AXPEntityDetailDto, AXPEntityDetailListView, AXPEntityDisplayField, AXPEntityFormats, AXPEntityListFilterDefinition, AXPEntityListItemDto, AXPEntityListSortableField, AXPEntityMasterCreateLayoutView, AXPEntityMasterLayoutView, AXPEntityMasterListDisplayMode, AXPEntityMasterListLayoutOption, AXPEntityMasterListLayoutType, AXPEntityMasterListView, AXPEntityMasterSingleLayoutView, AXPEntityMasterUpdateLayoutView, AXPEntityModel, AXPEntityOutputDto, AXPEntityPage, AXPEntityProperty, AXPEntityPropertyCreateView, AXPEntityPropertyExposeEntry, AXPEntityPropertyFilterOptions, AXPEntityPropertyGroup, AXPEntityPropertyLayoutConfig, AXPEntityPropertyLike, AXPEntityPropertyListOptions, AXPEntityPropertySortOptions, AXPEntityPropertyUpdateView, AXPEntityPropertyView, AXPEntityQuery, AXPEntityQueryAllOptions, AXPEntityQueryAllResult, AXPEntityQuickCreate, AXPEntitySearchResultFormat, AXPEntitySearchTitleContext, AXPEntitySectionView, AXPEntityTableColumn, AXPEntityUpdateDto, AXPEntityV2, AXPEntityVersionHistory, AXPLookupColumnResolveOptions, AXPLookupColumnResolveStrategy, AXPLookupDisplayOptions, AXPLookupPopoverOptions, AXPLookupSelectorRowActionsConfig, AXPLookupWidgetCreateOptions, AXPLookupWidgetLookType, AXPLookupWidgetOptions, AXPMockDto, AXPModule, AXPQueryFilter, AXPQuerySort, AXPQueryView, AXPRecordAuditInfo, AXPRecordOwnershipInfo, AXPRecordStateInfo, AXPRecordWorkflowInfo, AXPRelatedEntity, AXPRelatedEntityLayout, AXPRelatedEntityPersistence, AXPRelationship, ResolvedLookupCreateOptions };
|
|
1006
|
+
export { AXPEntityCommandScope, AXPEntityDataSourceKeys, AXPEntityEventsKeys, AXPEntityQueryType, AXPEntityType, AXPRelationshipCardinality, AXPRelationshipKind, AXP_RECORD_WORKFLOW_INFO_CORRELATION_ID_FIELD, AXP_RECORD_WORKFLOW_INFO_DEFINITION_ID_FIELD, AXP_RECORD_WORKFLOW_INFO_INSTANCE_ID_FIELD, ENTITY_LAYOUT_SINGLE_TITLE_PATH, ENTITY_ROW_POPUP_TITLE_OPTION, ENTITY_ROW_TITLE_TEMPLATE_OPTION, PAGE_LIST_WIDGET_NAME_PREFIX, buildAXPRecordWorkflowInfo, buildEntitySearchTitleContext, buildPageListTableWidgetId, buildPageListWidgetName, collectEntityListFilterDefinitions, collectEntityListSortableFields, collectEntityQuickSearchFieldPaths, collectMergeDetailListPropertyNames, collectNestedCreateHiddenProperties, collectNestedFieldPathsFromEntityColumns, collectPropertyExposeTargetPaths, collectQuickSearchPathsFromSingleEntityDefinition, createAllQueryView, createQueryView, encodeEntityListFilterContextField, entityDetailsCreateActions, entityDetailsCreateActionsDeferredParent, entityDetailsCrudActions, entityDetailsEditAction, entityDetailsNewEditAction, entityDetailsReferenceCondition, entityDetailsReferenceCreateActions, entityDetailsSimpleCondition, entityMasterBulkDeleteAction, entityMasterCreateAction, entityMasterCrudActions, entityMasterDeleteAction, entityMasterEditAction, entityMasterRecordActions, entityMasterViewAction, entityOverrideDetailsViewAction, getEntityInfo, getRecordWorkflowCorrelationId, getRecordWorkflowInstanceId, isCardFieldBadgeDisplay, isEntityActionPermitted, isEntityPropertySortEnabled, isMeaningfulEntityDisplayTitle, isPageListWidgetName, isRowBoundEntityDisplayTemplate, isUnresolvedEntityDisplayTemplate, mergeForeignKeyFieldIntoCreateActions, normalizeEntityDisplayTemplate, normalizeExpressionTemplate, parseDottedFieldPath, parsePropertyExposeEntries, parseRelatedEntityFullName, resolveCardFieldBadgeColor, resolveDefaultMasterListLayout, resolveEnabledMasterListLayouts, resolveEntityColumnDataPath, resolveEntityListFilterContextField, resolveEntityListFilterQueryField, resolveEntityModifyRecordTitleTemplate, resolveEntityPropertyInlineFilterField, resolveEntityRowTitleTemplate, resolveLookupWidgetCreateOptions, resolvePropertyExposeDisplayTarget, sanitizeResolvedEntityDisplayTitle };
|
|
1007
|
+
export type { AXEntityPropertyWidget, AXPAggregate, AXPApplication, AXPAuditEvent, AXPBuildEntityListFilterDefinitionsDeps, AXPCardBadgeColor, AXPCardBadgeDisplay, AXPCardBadgeDisplayOptions, AXPCardField, AXPCardFieldDisplay, AXPCardFieldDisplayConfig, AXPCollectEntityQuickSearchPathsResolver, AXPColumnAlign, AXPColumnContentAlign, AXPCommandActionCallback, AXPCommandActionDisplay, AXPCommandActionLook, AXPCommandActionPriority, AXPCommandActionType, AXPEntity, AXPEntityAction, AXPEntityAggregateMeasure, AXPEntityAggregateOptions, AXPEntityAggregateReducerType, AXPEntityAggregateRequest, AXPEntityAggregateResult, AXPEntityCategoryPlugin, AXPEntityCommand, AXPEntityCreateDto, AXPEntityCrudActionPermissions, AXPEntityDetailDto, AXPEntityDetailListView, AXPEntityDisplayField, AXPEntityFormats, AXPEntityListFilterDefinition, AXPEntityListItemDto, AXPEntityListSortableField, AXPEntityMasterCreateLayoutView, AXPEntityMasterLayoutView, AXPEntityMasterListDisplayMode, AXPEntityMasterListLayoutOption, AXPEntityMasterListLayoutType, AXPEntityMasterListView, AXPEntityMasterSingleLayoutView, AXPEntityMasterUpdateLayoutView, AXPEntityModel, AXPEntityOutputDto, AXPEntityPage, AXPEntityProperty, AXPEntityPropertyCreateView, AXPEntityPropertyExposeEntry, AXPEntityPropertyFilterOptions, AXPEntityPropertyGroup, AXPEntityPropertyLayoutConfig, AXPEntityPropertyLike, AXPEntityPropertyListOptions, AXPEntityPropertySortOptions, AXPEntityPropertyUpdateView, AXPEntityPropertyView, AXPEntityQuery, AXPEntityQueryAllOptions, AXPEntityQueryAllResult, AXPEntityQuickCreate, AXPEntitySearchResultFormat, AXPEntitySearchTitleContext, AXPEntitySectionView, AXPEntityTableColumn, AXPEntityUpdateDto, AXPEntityV2, AXPEntityVersionHistory, AXPLookupColumnResolveOptions, AXPLookupColumnResolveStrategy, AXPLookupDisplayOptions, AXPLookupPopoverOptions, AXPLookupSelectorRowActionsConfig, AXPLookupWidgetCreateOptions, AXPLookupWidgetLookType, AXPLookupWidgetOptions, AXPMockDto, AXPModule, AXPQueryFilter, AXPQuerySort, AXPQueryView, AXPRecordAuditInfo, AXPRecordOwnershipInfo, AXPRecordStateInfo, AXPRecordWorkflowInfo, AXPRelatedEntity, AXPRelatedEntityLayout, AXPRelatedEntityPersistence, AXPRelationship, ResolvedLookupCreateOptions };
|
|
@@ -372,6 +372,7 @@ declare class AXPEntityCommandTriggerViewModel {
|
|
|
372
372
|
metadata?: AXPMetaData;
|
|
373
373
|
default?: boolean;
|
|
374
374
|
shortcuts?: string[];
|
|
375
|
+
permissions?: string[];
|
|
375
376
|
items?: AXPEntityCommandTriggerViewModel[];
|
|
376
377
|
isChild?: boolean;
|
|
377
378
|
constructor(entity: AXPEntity, action: AXPEntityAction, isChild?: boolean);
|
|
@@ -417,6 +418,7 @@ declare class AXPEntityDetailListViewModel {
|
|
|
417
418
|
private expressionEvaluator;
|
|
418
419
|
private queryExecutor;
|
|
419
420
|
private readonly settingsService;
|
|
421
|
+
private readonly session;
|
|
420
422
|
private readonly destroyed;
|
|
421
423
|
private readonly showRowIndexColumnEnabled;
|
|
422
424
|
private lastAppliedFilterKey;
|
|
@@ -2632,6 +2634,7 @@ declare class AXPEntityListTableService {
|
|
|
2632
2634
|
private readonly expressionEvaluator;
|
|
2633
2635
|
private readonly settings;
|
|
2634
2636
|
private readonly columnWidthService;
|
|
2637
|
+
private readonly session;
|
|
2635
2638
|
/**
|
|
2636
2639
|
* Convert Entity to List Widget Options
|
|
2637
2640
|
*/
|
|
@@ -2736,6 +2739,7 @@ declare class AXPEntityListWidgetViewComponent extends AXPValueWidgetComponent {
|
|
|
2736
2739
|
private readonly expressionEvaluator;
|
|
2737
2740
|
private readonly columnWidthService;
|
|
2738
2741
|
private readonly route;
|
|
2742
|
+
private readonly session;
|
|
2739
2743
|
protected isMounted: _angular_core.WritableSignal<boolean>;
|
|
2740
2744
|
readonly entity: _angular_core.WritableSignal<AXPEntity | null>;
|
|
2741
2745
|
protected listNode: _angular_core.WritableSignal<AXPWidgetNode | null>;
|