diff --git a/components/report_cards/chemical_probe/Summary.vue b/components/report_cards/chemical_probe/Summary.vue index 6f21d123aed0a8ccae6f9091b5ab8bd3083344f3..fd185f49f4ed7648dd107ba74ee146a57fb396de 100644 --- a/components/report_cards/chemical_probe/Summary.vue +++ b/components/report_cards/chemical_probe/Summary.vue @@ -101,10 +101,7 @@ <v-col cols="12"> <b>Download probe data package:</b> <br /><br /> - <v-btn - href="https://drive.google.com/file/d/1FQOGQxTdcIfTeM1Vq73vbHOEJ0ZptkHV/view?usp=sharing" - color="primary" - > + <v-btn :href="linkToPDF" color="primary"> <v-icon>mdi-download</v-icon> PDF </v-btn> </v-col> @@ -163,6 +160,17 @@ export default { entityID() { return EntityNames.EubopenCompound.entityID }, + linkToPDF() { + const compoundRecords = ObjectPropertyAccess.getPropertyPalue( + this.probeSummaryData, + '_metadata.compound_records' + ) + const srcIDs = compoundRecords.map((record) => record.src_id) + if (srcIDs.includes(55)) { + return 'https://www.thesgc.org/donated-chemical-probes' + } + return 'https://www.eubopen.org/chemical-probes' + }, }, mounted() { this.$store.dispatch('probe/probeSummary/loadData', this.itemID) diff --git a/store/probe/probeSummary.js b/store/probe/probeSummary.js index f853bfab6959b0c9b8365c5a38d3ea6d2879dfdc..42d51b2891c4d72de93b533f760ae49e2d8ae79e 100644 --- a/store/probe/probeSummary.js +++ b/store/probe/probeSummary.js @@ -25,6 +25,7 @@ export const actions = { '_metadata.eubopen.in_vivo_use', 'molecule_structures.canonical_smiles', 'molecule_structures.standard_inchi_key', + '_metadata.compound_records.src_id', ] const entityID = EntityNames.EubopenCompound.entityID const indexName = IndexNames.getIndexNameFromEntityID(entityID)