diff --git a/WebBuilder.py b/WebBuilder.py index fa7180b..6af5cd0 100644 --- a/WebBuilder.py +++ b/WebBuilder.py @@ -41,6 +41,9 @@ class WebBuilder: self.dest_path, "components/tabs" ) + if not os.path.exists(self.tabs_path): + os.mkdir(self.tabs_path) + WebBuilder.exit_handler_done = False self.userRequestedStopFile = os.path.join( self.dest_path, @@ -81,10 +84,6 @@ class WebBuilder: f.write(s) def make_tab_list(self): - tabs_path = os.path.join( - self.dest_path, - "components/tabs" - ) workflows_list_path = os.path.join( self.tabs_path, "WorkflowsList.js" @@ -99,7 +98,7 @@ class WebBuilder: with open(tab_list_path) as main: tab_list_orig = main.read() - files = os.listdir(tabs_path) + files = os.listdir(self.tabs_path) tab_classes = [] tab_classes_html = [] workflows_js = [] diff --git a/__init__.py b/__init__.py index ba5c3e3..154053f 100644 --- a/__init__.py +++ b/__init__.py @@ -46,6 +46,7 @@ NODE_DISPLAY_NAME_MAPPINGS = { "PresentationComponent": "Presentation Component", "PresentationDropDown": "Presentation DropDown", "PresentationAdvancedSection": "Presentation Advanced Section", + "PresentationHistory": "Presentation History", } WebServer.WebServer().start() diff --git a/presentation-site/server/api/files.js b/presentation-site/server/api/files.js index 6dc3ebb..7c93868 100644 --- a/presentation-site/server/api/files.js +++ b/presentation-site/server/api/files.js @@ -8,7 +8,7 @@ export default defineEventHandler(async (event) => { q.set('email', userFolder); } let path = q.get('path'); - const pathM = /^([^/]+)\/(.*)$/.exec(path); + const pathM = /^([^/\\]+)[\/\\](.*)$/.exec(path); if (pathM) { q.set('path', pathM[1]); q.set('subfolder', pathM[2]); diff --git a/presentation-site/server/nodes/lib/linkTarget.js b/presentation-site/server/nodes/lib/linkTarget.js index 0313d02..b1c218d 100644 --- a/presentation-site/server/nodes/lib/linkTarget.js +++ b/presentation-site/server/nodes/lib/linkTarget.js @@ -16,7 +16,7 @@ export function linkTarget(node, id, inputName, workflowData, opts) { // link input, output val = join('..', inputPath, val); } else { - const pathM = /^([^\/]+)\/(.*)$/.exec(inputPath); + const pathM = /^([^\/\\]+)[\/\\](.*)$/.exec(inputPath); if (pathM) { // link model. First path is the type val = join(pathM[2], val);