diff --git a/client/src/components/Workflow/Run/WorkflowRunFormSimple.vue b/client/src/components/Workflow/Run/WorkflowRunFormSimple.vue index 0f0a5e4f2722..74e942f49de0 100644 --- a/client/src/components/Workflow/Run/WorkflowRunFormSimple.vue +++ b/client/src/components/Workflow/Run/WorkflowRunFormSimple.vue @@ -55,6 +55,9 @@ + + + - + + + + +
+
+ + About This Workflow + + + + +
+
+ + + + + {{ model.runData.annotation.annotation }} +
+ +
+
+ + + + + diff --git a/client/src/components/Workflow/Run/WorkflowRunName.vue b/client/src/components/Workflow/Run/WorkflowRunName.vue deleted file mode 100644 index 43c20b311343..000000000000 --- a/client/src/components/Workflow/Run/WorkflowRunName.vue +++ /dev/null @@ -1,56 +0,0 @@ - - - diff --git a/client/src/components/WorkflowInvocationState/WorkflowInvocationHeader.test.ts b/client/src/components/WorkflowInvocationState/WorkflowInvocationHeader.test.ts index 6964145c03b6..fc3ec8c3ef71 100644 --- a/client/src/components/WorkflowInvocationState/WorkflowInvocationHeader.test.ts +++ b/client/src/components/WorkflowInvocationState/WorkflowInvocationHeader.test.ts @@ -7,7 +7,7 @@ import { getLocalVue } from "tests/jest/helpers"; import sampleInvocation from "@/components/Workflow/test/json/invocation.json"; import { useUserStore } from "@/stores/userStore"; -import WorkflowInvocationHeader from "./WorkflowInvocationHeader.vue"; +import WorkflowNavigationTitle from "../Workflow/WorkflowNavigationTitle.vue"; // Constants const WORKFLOW_OWNER = "test-user"; @@ -62,14 +62,14 @@ jest.mock("@/stores/workflowStore", () => { const localVue = getLocalVue(); /** - * Mounts the WorkflowInvocationHeader component with props/stores adjusted given the parameters + * Mounts the WorkflowNavigationTitle component with props/stores adjusted given the parameters * @param ownsWorkflow Whether the user owns the workflow associated with the invocation * @param hasReturnBtn Whether the component should have a return to invocations list button * @param unimportableWorkflow Whether the workflow import should fail * @returns The wrapper object */ -async function mountWorkflowInvocationHeader(ownsWorkflow = true, hasReturnBtn = false, unimportableWorkflow = false) { - const wrapper = shallowMount(WorkflowInvocationHeader as object, { +async function mountWorkflowNavigationTitle(ownsWorkflow = true, hasReturnBtn = false, unimportableWorkflow = false) { + const wrapper = shallowMount(WorkflowNavigationTitle as object, { propsData: { invocation: { ...sampleInvocation, @@ -89,10 +89,10 @@ async function mountWorkflowInvocationHeader(ownsWorkflow = true, hasReturnBtn = return { wrapper }; } -describe("WorkflowInvocationHeader renders", () => { +describe("WorkflowNavigationTitle renders", () => { // Included both cases in one test because these are always constant it("(always) the workflow name in header and run button in actions", async () => { - const { wrapper } = await mountWorkflowInvocationHeader(); + const { wrapper } = await mountWorkflowNavigationTitle(); const heading = wrapper.find(SELECTORS.INVOKED_WORKFLOW_HEADING); expect(heading.text()).toBe(`Invoked Workflow: "${SAMPLE_WORKFLOW.name}"`); @@ -103,13 +103,13 @@ describe("WorkflowInvocationHeader renders", () => { }); it("return to invocations list button if not from panel", async () => { - const { wrapper } = await mountWorkflowInvocationHeader(false, true); + const { wrapper } = await mountWorkflowNavigationTitle(false, true); const returnButton = wrapper.find(SELECTORS.RETURN_TO_INVOCATIONS_LIST_BUTTON); expect(returnButton.text()).toBe("Invocations List"); }); it("edit button if user owns the workflow", async () => { - const { wrapper } = await mountWorkflowInvocationHeader(); + const { wrapper } = await mountWorkflowNavigationTitle(); const actionsGroup = wrapper.find(SELECTORS.ACTIONS_BUTTON_GROUP); const editButton = actionsGroup.find(SELECTORS.EDIT_WORKFLOW_BUTTON); expect(editButton.attributes("to")).toBe( @@ -118,16 +118,16 @@ describe("WorkflowInvocationHeader renders", () => { }); it("import button instead if user does not own the workflow", async () => { - const { wrapper } = await mountWorkflowInvocationHeader(false); + const { wrapper } = await mountWorkflowNavigationTitle(false); const actionsGroup = wrapper.find(SELECTORS.ACTIONS_BUTTON_GROUP); const importButton = actionsGroup.find(SELECTORS.IMPORT_WORKFLOW_BUTTON); expect(importButton.exists()).toBe(true); }); }); -describe("Importing a workflow in WorkflowInvocationHeader", () => { +describe("Importing a workflow in WorkflowNavigationTitle", () => { it("should show a confirmation dialog when the import is successful", async () => { - const { wrapper } = await mountWorkflowInvocationHeader(false); + const { wrapper } = await mountWorkflowNavigationTitle(false); const actionsGroup = wrapper.find(SELECTORS.ACTIONS_BUTTON_GROUP); const importButton = actionsGroup.find(SELECTORS.IMPORT_WORKFLOW_BUTTON); @@ -141,7 +141,7 @@ describe("Importing a workflow in WorkflowInvocationHeader", () => { }); it("should show an error dialog when the import fails", async () => { - const { wrapper } = await mountWorkflowInvocationHeader(false, false, true); + const { wrapper } = await mountWorkflowNavigationTitle(false, false, true); const actionsGroup = wrapper.find(SELECTORS.ACTIONS_BUTTON_GROUP); const importButton = actionsGroup.find(SELECTORS.IMPORT_WORKFLOW_BUTTON); diff --git a/client/src/components/WorkflowInvocationState/WorkflowInvocationHeader.vue b/client/src/components/WorkflowInvocationState/WorkflowInvocationHeader.vue deleted file mode 100644 index 93b47c32b4f5..000000000000 --- a/client/src/components/WorkflowInvocationState/WorkflowInvocationHeader.vue +++ /dev/null @@ -1,155 +0,0 @@ - - - diff --git a/client/src/components/WorkflowInvocationState/WorkflowInvocationState.vue b/client/src/components/WorkflowInvocationState/WorkflowInvocationState.vue index e035bc9b7dbe..808aa454428c 100644 --- a/client/src/components/WorkflowInvocationState/WorkflowInvocationState.vue +++ b/client/src/components/WorkflowInvocationState/WorkflowInvocationState.vue @@ -12,8 +12,9 @@ import { cancelWorkflowScheduling } from "./services"; import { isTerminal, jobCount, runningCount } from "./util"; import InvocationReport from "../Workflow/InvocationReport.vue"; +import WorkflowAnnotation from "../Workflow/WorkflowAnnotation.vue"; +import WorkflowNavigationTitle from "../Workflow/WorkflowNavigationTitle.vue"; import WorkflowInvocationExportOptions from "./WorkflowInvocationExportOptions.vue"; -import WorkflowInvocationHeader from "./WorkflowInvocationHeader.vue"; import WorkflowInvocationInputOutputTabs from "./WorkflowInvocationInputOutputTabs.vue"; import WorkflowInvocationOverview from "./WorkflowInvocationOverview.vue"; import LoadingSpan from "@/components/LoadingSpan.vue"; @@ -24,11 +25,13 @@ interface Props { isSubworkflow?: boolean; isFullPage?: boolean; fromPanel?: boolean; + targetHistory: string; } const props = withDefaults(defineProps(), { index: undefined, isSubworkflow: false, + targetHistory: "current", }); const emit = defineEmits<{ @@ -145,7 +148,18 @@ function cancelWorkflowSchedulingLocal() {