From b370ab841a76d6f64b0d973c271cf096f6d8fa56 Mon Sep 17 00:00:00 2001 From: AnuragVanam Date: Thu, 25 Mar 2021 12:28:49 -0400 Subject: [PATCH 1/2] Update GeoweaverApplication.java --- .../java/com/gw/GeoweaverApplication.java | 48 ++++++++++++------- 1 file changed, 31 insertions(+), 17 deletions(-) diff --git a/src/main/java/com/gw/GeoweaverApplication.java b/src/main/java/com/gw/GeoweaverApplication.java index 03df93a57..0f45c0d7b 100644 --- a/src/main/java/com/gw/GeoweaverApplication.java +++ b/src/main/java/com/gw/GeoweaverApplication.java @@ -4,6 +4,11 @@ import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.web.servlet.ServletComponentScan; + import java.awt.*; +import java.io.IOException; +import java.net.URI; +import java.net.URISyntaxException; + @SpringBootApplication @ServletComponentScan public class GeoweaverApplication { @@ -13,22 +18,31 @@ public static void main(String[] args) { // BasicConfigurator.configure(); SpringApplication.run(GeoweaverApplication.class, args); - - } - -// @Bean -// public ServletContextAware endpointExporterInitializer(final ApplicationContext applicationContext) { -// -// return new ServletContextAware() { -// -// @Override -// public void setServletContext(ServletContext servletContext) { -// ServerEndpointExporter exporter = new ServerEndpointExporter(); -// exporter.setApplicationContext(applicationContext); -// exporter.afterPropertiesSet(); -// } -// -// }; -// } + browse("http://localhost:8070/Geoweaver/"); +// openHomePage(); + + + } + public static void browse(String url) { + if(Desktop.isDesktopSupported()){ + Desktop desktop = Desktop.getDesktop(); + try { + desktop.browse(new URI(url)); + } catch (IOException | URISyntaxException e) { + e.printStackTrace(); + } + }else{ + Runtime runtime = Runtime.getRuntime(); + try { + runtime.exec("rundll32 url.dll,FileProtocolHandler " + url); + } catch (IOException e) { + e.printStackTrace(); + } + } + } + + } + + From 693800eb1c3baac14a65360cb47a99b66afa88eb Mon Sep 17 00:00:00 2001 From: AnuragVanam Date: Thu, 25 Mar 2021 12:45:55 -0400 Subject: [PATCH 2/2] Update issue#132 --- src/main/resources/static/js/gw.process.js | 11 +++++++++++ src/main/resources/static/js/gw.workflow.js | 9 +++++++++ 2 files changed, 20 insertions(+) diff --git a/src/main/resources/static/js/gw.process.js b/src/main/resources/static/js/gw.process.js index fae3b6c04..c777db4ae 100644 --- a/src/main/resources/static/js/gw.process.js +++ b/src/main/resources/static/js/gw.process.js @@ -1363,6 +1363,15 @@ GW.process = { var instanceid = GW.workspace.theGraph.addProcess(one.id, one.name); }, + + expand: function(folder){ + + console.log("EXPAND Process type") + + $("#process_folder_"+folder+"_target").collapse("show"); + // $("#"+GW.menu.getPanelIdByType("process")).collapse("show"); + + }, list: function(msg){ @@ -1513,6 +1522,8 @@ GW.process = { msg.desc = req.desc; GW.process.addMenuItem(msg, req.desc); + + GW.process.expand(req.desc); if(run) diff --git a/src/main/resources/static/js/gw.workflow.js b/src/main/resources/static/js/gw.workflow.js index 46ea1b515..b2fee3254 100644 --- a/src/main/resources/static/js/gw.workflow.js +++ b/src/main/resources/static/js/gw.workflow.js @@ -233,6 +233,8 @@ GW.workflow = { GW.workflow.addMenuItem(msg); console.log("the workflow is added"); + + GW.workflow.expand(msg); GW.workflow.loaded_workflow = msg.id; @@ -1423,6 +1425,13 @@ GW.workflow = { ""); }, + expand: function(one){ + + console.log("EXPAND Workflow") + + $("#"+GW.menu.getPanelIdByType("workflow")).collapse("show"); + }, + list: function(msg){