From 811d8161a4bb2c91d09047b4b42667961bd5e18e Mon Sep 17 00:00:00 2001 From: Josemi Date: Wed, 27 Nov 2024 14:42:29 +0100 Subject: [PATCH] wc: Fix link to exit from interpreter tool #TASK-7216 #TASK-7100 --- .../variant/interpretation/variant-interpreter.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/webcomponents/variant/interpretation/variant-interpreter.js b/src/webcomponents/variant/interpretation/variant-interpreter.js index 4767717ee..9da5f181d 100644 --- a/src/webcomponents/variant/interpretation/variant-interpreter.js +++ b/src/webcomponents/variant/interpretation/variant-interpreter.js @@ -425,6 +425,10 @@ class VariantInterpreter extends LitElement { } renderToolbarRightContent() { + // Note: we have to maintain the URL structure, so if we are inside an app we have to maintain the app + const hashItems = window.location.hash.replace("#", "").split("/"); + const exitUrl = "#" + [...hashItems.slice(0, -3), "clinical-analysis-portal", this.opencgaSession.project.id, this.opencgaSession.study.id].join("/"); + return html`
${this.clinicalAnalysis?.interpretation ? html` @@ -492,7 +496,7 @@ class VariantInterpreter extends LitElement {
  • - + Exit Interpreter