Skip to content

Commit

Permalink
Merge pull request galaxyproject#16760 from assuntad23/16556/include-…
Browse files Browse the repository at this point in the history
…wf-version

WF Report Enhancement: Exposing Workflow Version as Workflow Checkpoint
  • Loading branch information
dannon authored Nov 7, 2023
2 parents ea0fe80 + ae40fae commit b7fc2e3
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions client/src/components/Markdown/Markdown.vue
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@
<h1 class="text-break align-middle">
Title: {{ markdownConfig.title || markdownConfig.model_class }}
</h1>
<h2 v-if="workflowVersions" class="text-break align-middle">
Workflow Checkpoint: {{ workflowVersions.version }}
</h2>
</span>
</div>
<b-badge variant="info" class="w-100 rounded mb-3 white-space-normal">
Expand Down Expand Up @@ -67,9 +70,12 @@ import { FontAwesomeIcon } from "@fortawesome/vue-fontawesome";
import BootstrapVue from "bootstrap-vue";
import MarkdownIt from "markdown-it";
import markdownItRegexp from "markdown-it-regexp";
import { mapActions } from "pinia";
import store from "store";
import Vue from "vue";
import { useWorkflowStore } from "@/stores/workflowStore";
import MarkdownContainer from "./MarkdownContainer.vue";
import LoadingSpan from "components/LoadingSpan.vue";
import StsDownloadButton from "components/StsDownloadButton.vue";
Expand Down Expand Up @@ -131,6 +137,7 @@ export default {
jobs: {},
invocations: {},
loading: true,
workflowID: "",
};
},
computed: {
Expand Down Expand Up @@ -158,6 +165,9 @@ export default {
}
return "unavailable";
},
workflowVersions() {
return this.getStoredWorkflowByInstanceId(this.workflowID);
},
version() {
return this.markdownConfig.generate_version || "Unknown Galaxy Version";
},
Expand All @@ -169,8 +179,10 @@ export default {
},
created() {
this.initConfig();
this.fetchWorkflowForInstanceId(this.workflowID);
},
methods: {
...mapActions(useWorkflowStore, ["getStoredWorkflowByInstanceId", "fetchWorkflowForInstanceId"]),
initConfig() {
if (Object.keys(this.markdownConfig).length) {
const config = this.markdownConfig;
Expand All @@ -184,6 +196,7 @@ export default {
this.jobs = config.jobs || {};
this.invocations = config.invocations || {};
this.loading = false;
this.workflowID = Object.keys(this.markdownConfig.workflows)[0];
}
},
splitMarkdown(markdown) {
Expand Down

0 comments on commit b7fc2e3

Please sign in to comment.