From 8aaa0d3c572fb125f6dcc4d291a8b0473ec683e1 Mon Sep 17 00:00:00 2001 From: Michael Kret Date: Wed, 27 Nov 2024 14:11:53 +0200 Subject: [PATCH] fix double popup --- packages/editor-ui/src/stores/workflows.store.ts | 1 + packages/editor-ui/src/utils/executionUtils.ts | 4 +++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/packages/editor-ui/src/stores/workflows.store.ts b/packages/editor-ui/src/stores/workflows.store.ts index f49beaed84781..e22a0724f71ff 100644 --- a/packages/editor-ui/src/stores/workflows.store.ts +++ b/packages/editor-ui/src/stores/workflows.store.ts @@ -1726,5 +1726,6 @@ export const useWorkflowsStore = defineStore(STORES.WORKFLOWS, () => { setNodes, setConnections, markExecutionAsStopped, + formPopupWindow, }; }); diff --git a/packages/editor-ui/src/utils/executionUtils.ts b/packages/editor-ui/src/utils/executionUtils.ts index 014f3492b638d..71adcc880b759 100644 --- a/packages/editor-ui/src/utils/executionUtils.ts +++ b/packages/editor-ui/src/utils/executionUtils.ts @@ -131,7 +131,9 @@ export function displayForm({ if (node.name === destinationNode || !node.disabled) { let testUrl = ''; if (node.type === FORM_TRIGGER_NODE_TYPE) testUrl = getTestUrl(node); - if (testUrl && source !== 'RunData.ManualChatMessage') openPopUpWindow(testUrl); + if (testUrl && source !== 'RunData.ManualChatMessage') { + useWorkflowsStore().formPopupWindow = openPopUpWindow(testUrl); + } } } }