From 051f3bbb35fe942d30b14acf38d66b6397478546 Mon Sep 17 00:00:00 2001 From: Mads Rasmussen Date: Sat, 2 Mar 2024 21:13:38 +0100 Subject: [PATCH 1/3] await following modal submit before execute is done --- .../packages/data-type/entity-actions/create/create.action.ts | 4 +++- .../document-types/entity-actions/create/create.action.ts | 4 +++- .../documents/entity-actions/create/create.action.ts | 4 +++- .../media/media-types/entity-actions/create/create.action.ts | 4 +++- .../media/media/entity-actions/create/create.action.ts | 4 +++- .../templating/scripts/entity-actions/create/create.action.ts | 4 +++- .../stylesheets/entity-actions/create/create.action.ts | 4 +++- 7 files changed, 21 insertions(+), 7 deletions(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/data-type/entity-actions/create/create.action.ts b/src/Umbraco.Web.UI.Client/src/packages/data-type/entity-actions/create/create.action.ts index f29a4c65f1..3afb85b047 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/data-type/entity-actions/create/create.action.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/data-type/entity-actions/create/create.action.ts @@ -8,10 +8,12 @@ export class UmbCreateDataTypeEntityAction extends UmbEntityActionBase Date: Sat, 2 Mar 2024 21:13:49 +0100 Subject: [PATCH 2/3] submit when navigating --- .../create/modal/document-type-create-options-modal.element.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/documents/document-types/entity-actions/create/modal/document-type-create-options-modal.element.ts b/src/Umbraco.Web.UI.Client/src/packages/documents/document-types/entity-actions/create/modal/document-type-create-options-modal.element.ts index 328e1faf6e..e96478525c 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/documents/document-types/entity-actions/create/modal/document-type-create-options-modal.element.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/documents/document-types/entity-actions/create/modal/document-type-create-options-modal.element.ts @@ -37,7 +37,7 @@ export class UmbDataTypeCreateOptionsModalElement extends UmbModalBaseElement Date: Sat, 2 Mar 2024 21:28:02 +0100 Subject: [PATCH 3/3] Update create.action.ts --- .../partial-views/entity-actions/create/create.action.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Umbraco.Web.UI.Client/src/packages/templating/partial-views/entity-actions/create/create.action.ts b/src/Umbraco.Web.UI.Client/src/packages/templating/partial-views/entity-actions/create/create.action.ts index 136a4241c5..b48b39fe05 100644 --- a/src/Umbraco.Web.UI.Client/src/packages/templating/partial-views/entity-actions/create/create.action.ts +++ b/src/Umbraco.Web.UI.Client/src/packages/templating/partial-views/entity-actions/create/create.action.ts @@ -7,11 +7,13 @@ export class UmbPartialViewCreateOptionsEntityAction extends UmbEntityActionBase if (!this.repository) throw new Error('Repository is not available'); const modalManager = await this.getContext(UMB_MODAL_MANAGER_CONTEXT); - modalManager.open(this, UMB_PARTIAL_VIEW_CREATE_OPTIONS_MODAL, { + const modalContext = modalManager.open(this, UMB_PARTIAL_VIEW_CREATE_OPTIONS_MODAL, { data: { parentUnique: this.unique, entityType: this.entityType, }, }); + + await modalContext.onSubmit(); } }