From 23c0d7e2ac91f865a8a7c258decd050ca3b987ae Mon Sep 17 00:00:00 2001 From: frikky Date: Tue, 6 Dec 2022 14:52:13 +0000 Subject: [PATCH] Fixed import/export issues with subflows and parent workflows --- frontend/src/views/AngularWorkflow.jsx | 21 +++++----- frontend/src/views/Welcome.jsx | 30 +++++++------- frontend/src/views/Workflows.jsx | 56 +++++++++++++------------- 3 files changed, 54 insertions(+), 53 deletions(-) diff --git a/frontend/src/views/AngularWorkflow.jsx b/frontend/src/views/AngularWorkflow.jsx index 6d482c01..638234d5 100644 --- a/frontend/src/views/AngularWorkflow.jsx +++ b/frontend/src/views/AngularWorkflow.jsx @@ -6532,15 +6532,15 @@ const AngularWorkflow = (defaultprops) => { return (
{ - if (!isCloud) { - alert.info("Since this is an on-prem instance. You will need to activate the app yourself. Opening link to download it in a new window.") - setTimeout(() => { - event.preventDefault() - window.open(parsedUrl, '_blank') - }, 2000) - } else { - alert.info(`Activating ${name}`) - } + //if (!isCloud) { + // alert.info("Since this is an on-prem instance. You will need to activate the app yourself. Opening link to download it in a new window.") + // setTimeout(() => { + // event.preventDefault() + // window.open(parsedUrl, '_blank') + // }, 2000) + //} else { + alert.info(`Activating ${name}`) + //} console.log("CLICK: ", hit) @@ -6679,7 +6679,7 @@ const AngularWorkflow = (defaultprops) => { }} > - Couldn't find an Activated app with that name. Searching unactivated apps. Click one to Activate it for your organization. + Couldn't find the app you're looking for? Searching unactivated apps. Click one of the below apps to Activate it for your organization. { console.log("CLICKED") @@ -14837,6 +14837,7 @@ const AngularWorkflow = (defaultprops) => { {
diff --git a/frontend/src/views/Workflows.jsx b/frontend/src/views/Workflows.jsx index efd44fb6..df9ffad4 100644 --- a/frontend/src/views/Workflows.jsx +++ b/frontend/src/views/Workflows.jsx @@ -2271,35 +2271,35 @@ const Workflows = (props) => { "", data.status, ) - .then((response) => { - if (response !== undefined) { - // SET THE FULL THING - data.id = response.id; - data.first_save = false; - data.previously_saved = false; - data.is_valid = false; + .then((response) => { + if (response !== undefined) { + // SET THE FULL THING + data.id = response.id; + data.first_save = false; + data.previously_saved = false; + data.is_valid = false; - // Actually create it - setNewWorkflow( - data.name, - data.description, - data.tags, - data.default_return_value, - data, - false, - [], - "", - data.status, - ).then((response) => { - if (response !== undefined) { - alert.success("Successfully imported " + data.name); - } - }); - } - }) - .catch((error) => { - alert.error("Import error: " + error.toString()); - }); + // Actually create it + setNewWorkflow( + data.name, + data.description, + data.tags, + data.default_return_value, + data, + false, + [], + "", + data.status, + ).then((response) => { + if (response !== undefined) { + alert.success("Successfully imported " + data.name); + } + }); + } + }) + .catch((error) => { + alert.error("Import error: " + error.toString()); + }); }); // Actually reads