diff --git a/client/galaxy/scripts/mvc/workflow/workflow-view.js b/client/galaxy/scripts/mvc/workflow/workflow-view.js index 7c166b83eae..ff77da391e4 100644 --- a/client/galaxy/scripts/mvc/workflow/workflow-view.js +++ b/client/galaxy/scripts/mvc/workflow/workflow-view.js @@ -378,12 +378,10 @@ export default Backbone.View.extend({ // Load workflow definition this.load_workflow(self.options.id, self.options.version); if (make_popupmenu) { + $("#workflow-run-button").click(() => window.location = `${getAppRoot()}workflows/run?id=${self.options.id}`); + $("#workflow-save-button").click(() => save_current_workflow()); make_popupmenu($("#workflow-options-button"), { - Save: save_current_workflow, "Save As": workflow_save_as, - Run: function() { - window.location = `${getAppRoot()}workflows/run?id=${self.options.id}`; - }, "Edit Attributes": function() { self.workflow.clear_active_node(); }, diff --git a/client/galaxy/scripts/ui/popupmenu.js b/client/galaxy/scripts/ui/popupmenu.js index 68b68d51c29..4b03bef1d67 100644 --- a/client/galaxy/scripts/ui/popupmenu.js +++ b/client/galaxy/scripts/ui/popupmenu.js @@ -37,11 +37,12 @@ export function make_popupmenu(button_element, initial_options) { $.each(options, (k, v) => { if (v) { // Action can be either an anonymous function and a mapped dict. - var action = v.action || v; + let action = v.action || v; + let url = v.url || "javascript:void(0);"; menu_element.append( $("
  • ").append( $("") - .attr("href", v.url) + .attr("href", url) .html(k) .click(action) ) diff --git a/templates/webapps/galaxy/workflow/editor.mako b/templates/webapps/galaxy/workflow/editor.mako index aa55bfbd47b..9a2f1b0cda5 100644 --- a/templates/webapps/galaxy/workflow/editor.mako +++ b/templates/webapps/galaxy/workflow/editor.mako @@ -225,10 +225,18 @@ <%def name="center_panel()">
    -
    - -
    + ${h.to_unicode( stored.name ) | h}
    diff --git a/test/galaxy_selenium/navigates_galaxy.py b/test/galaxy_selenium/navigates_galaxy.py index 10ab5a61429..b2c7bbcbbaf 100644 --- a/test/galaxy_selenium/navigates_galaxy.py +++ b/test/galaxy_selenium/navigates_galaxy.py @@ -800,6 +800,12 @@ class NavigatesGalaxy(HasDriver): def workflow_editor_options_menu_element(self): return self.wait_for_selector_visible("#workflow-options-button-menu") + def workflow_editor_click_run(self): + return self.wait_for_and_click_selector("#workflow-run-button") + + def workflow_editor_click_save(self): + return self.wait_for_and_click_selector("#workflow-save-button") + def admin_open(self): self.components.masthead.admin.wait_for_and_click() diff --git a/test/selenium_tests/test_workflow_editor.py b/test/selenium_tests/test_workflow_editor.py index 0b124e696e5..8dd51dda85b 100644 --- a/test/selenium_tests/test_workflow_editor.py +++ b/test/selenium_tests/test_workflow_editor.py @@ -335,7 +335,7 @@ steps: self.screenshot("workflow_editor_missing_tool") def workflow_editor_save_and_close(self): - self.workflow_editor_click_option("Save") + self.workflow_editor_click_save() self.workflow_editor_click_option("Close") def workflow_editor_maximize_center_pane(self, collapse_left=True, collapse_right=True):