Commit 7e0d6340 authored by Lauri Himanen's avatar Lauri Himanen
Browse files

Added a link to the nomad-lab entry in the methodology page.

parent ec3fec46
Pipeline #80874 skipped with stage
This source diff could not be displayed because it is too large. You can view the blob instead.
......@@ -34,8 +34,7 @@ let DataStore = require('./DataStore.js');
let SortingButton = require('./SortingButton.js');
const REPOSITORY_LINK =
'https://repository.nomad-coe.eu/NomadRepository-1.1/views/calculation.zul?pid=';
const REPOSITORY_LINK = window.nomadEnv.guiRoot.slice(0, -4)+"entry/id";
const calcTypesMap = new Map([
['single point', 'Single point'],
......@@ -428,7 +427,7 @@ class MethodologyDetails extends DetailsViewBase {
updateMarkedLeaf(leafId){ }
_render(){
_render() {
let html = '';
this.sortedCalcs.forEach( rowCalcData => { //leafId => {
......@@ -443,10 +442,8 @@ class MethodologyDetails extends DetailsViewBase {
let calc = DataStore.getCalc( /*DataStore.getCalcReprIntId(*/rowCalcData.calc_id);
let calcType = rowCalcData.type;
let repositoryLinkHtml = '';
if (calc.calculation_pid !== null && calc.calculation_pid !== undefined)
repositoryLinkHtml =
'<a href="'+REPOSITORY_LINK+calc.calculation_pid+'" target="blank"> '
let repositoryLinkHtml =
`<a href="${REPOSITORY_LINK}/${calc.upload_id}/${calc.calc_id}" target="blank">`
+'<img src="img/download.svg" height="20px" /> </a>';
let materialId = DataStore.getMaterialData().material_id;
......@@ -481,10 +478,11 @@ class MethodologyDetails extends DetailsViewBase {
${calc.basis_set_type}</span>
${getOptValue(calc.basis_set_quality_quantifier)}
</td>
<!--
<td style="padding-top: 8px;padding-bottom: 4px;">${repositoryLinkHtml}
</td>
<!--
<td style="padding-top: 8px;padding-bottom: 4px;">${vrLinkHtml}
</td>-->
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment