Skip to content
Snippets Groups Projects
Commit f09c906b authored by David Mendez's avatar David Mendez
Browse files

Tweak sizes for molecule image and null values for summary data

parent ca843a69
No related branches found
No related tags found
1 merge request!10Fix some bugs with images and null values
...@@ -5,10 +5,11 @@ ...@@ -5,10 +5,11 @@
<v-col cols="12" sm="6"> <v-col cols="12" sm="6">
<v-card tile elevation="0"> <v-card tile elevation="0">
<v-card-title>PFI-6 Chemical Probe</v-card-title> <v-card-title>PFI-6 Chemical Probe</v-card-title>
<v-img <MoleculeImage
height="250" molecule-chembl-id="CHEMBL160074"
src="https://www.ebi.ac.uk/chembl/api/data/image/CHEMBL160074.svg" contain
></v-img> :aspect-ratio="16 / 9"
/>
<v-card-subtitle> <v-card-subtitle>
<a <a
href="https://www.ebi.ac.uk/chembl/compound_report_card/CHEMBL160074" href="https://www.ebi.ac.uk/chembl/compound_report_card/CHEMBL160074"
...@@ -39,10 +40,11 @@ ...@@ -39,10 +40,11 @@
<v-col cols="12" sm="6"> <v-col cols="12" sm="6">
<v-card tile elevation="0"> <v-card tile elevation="0">
<v-card-title>PFI-6N Negative Control</v-card-title> <v-card-title>PFI-6N Negative Control</v-card-title>
<v-img <MoleculeImage
height="250" molecule-chembl-id="CHEMBL1269459"
src="https://www.ebi.ac.uk/chembl/api/data/image/CHEMBL1269459.svg" contain
></v-img> :aspect-ratio="16 / 9"
/>
<v-card-subtitle> <v-card-subtitle>
<a <a
href="https://www.ebi.ac.uk/chembl/compound_report_card/CHEMBL1269459" href="https://www.ebi.ac.uk/chembl/compound_report_card/CHEMBL1269459"
...@@ -73,10 +75,11 @@ ...@@ -73,10 +75,11 @@
<v-col cols="12" sm="6"> <v-col cols="12" sm="6">
<v-card tile elevation="0"> <v-card tile elevation="0">
<v-card-title>PFI-6N Another Control 1</v-card-title> <v-card-title>PFI-6N Another Control 1</v-card-title>
<v-img <MoleculeImage
height="250" molecule-chembl-id="CHEMBL1276106"
src="https://www.ebi.ac.uk/chembl/api/data/image/CHEMBL1276106.svg" contain
></v-img> :aspect-ratio="16 / 9"
/>
<v-card-subtitle> <v-card-subtitle>
<a <a
href="https://www.ebi.ac.uk/chembl/compound_report_card/CHEMBL1276106" href="https://www.ebi.ac.uk/chembl/compound_report_card/CHEMBL1276106"
...@@ -107,10 +110,11 @@ ...@@ -107,10 +110,11 @@
<v-col cols="12" sm="6"> <v-col cols="12" sm="6">
<v-card tile elevation="0"> <v-card tile elevation="0">
<v-card-title>PFI-6N Another Control 2</v-card-title> <v-card-title>PFI-6N Another Control 2</v-card-title>
<v-img <MoleculeImage
height="250" molecule-chembl-id="CHEMBL1557"
src="https://www.ebi.ac.uk/chembl/api/data/image/CHEMBL1557.svg" contain
></v-img> :aspect-ratio="16 / 9"
/>
<v-card-subtitle> <v-card-subtitle>
<a <a
href="https://www.ebi.ac.uk/chembl/compound_report_card/CHEMBL1557" href="https://www.ebi.ac.uk/chembl/compound_report_card/CHEMBL1557"
...@@ -145,9 +149,12 @@ ...@@ -145,9 +149,12 @@
<script> <script>
import TextToClipboard from '~/web-components-submodule/components/common/TextToClipboard.vue' import TextToClipboard from '~/web-components-submodule/components/common/TextToClipboard.vue'
import MoleculeImage from '~/web-components-submodule/components/common/ReportCards/Shared/MoleculeImage.vue'
export default { export default {
components: { components: {
TextToClipboard, TextToClipboard,
MoleculeImage,
}, },
} }
</script> </script>
......
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
<v-row class="details-row" dense> <v-row class="details-row" dense>
<v-col cols="12"> <v-col cols="12">
<b>Chemical Probe Name:</b> <b>Chemical Probe Name:</b>
{{ probeSummaryData.pref_name }} {{ getPropertyPalue(probeSummaryData, 'pref_name', '---') }}
</v-col> </v-col>
</v-row> </v-row>
<v-divider /> <v-divider />
...@@ -184,6 +184,9 @@ export default { ...@@ -184,6 +184,9 @@ export default {
mounted() { mounted() {
this.$store.dispatch('probe/probeSummary/loadData', this.itemID) this.$store.dispatch('probe/probeSummary/loadData', this.itemID)
}, },
methods: {
getPropertyPalue: ObjectPropertyAccess.getPropertyPalue,
},
} }
</script> </script>
......
...@@ -7,14 +7,16 @@ ...@@ -7,14 +7,16 @@
<v-row class="details-row" dense> <v-row class="details-row" dense>
<v-col cols="12"> <v-col cols="12">
<b>Type:</b> <b>Type:</b>
{{ nameAndClassificationData.target_type }} {{
getPropertyPalue(nameAndClassificationData, 'target_type', '---')
}}
</v-col> </v-col>
</v-row> </v-row>
<v-divider /> <v-divider />
<v-row class="details-row" dense> <v-row class="details-row" dense>
<v-col cols="12"> <v-col cols="12">
<b>Preferred Name:</b> <b>Preferred Name:</b>
{{ nameAndClassificationData.pref_name }} {{ getPropertyPalue(nameAndClassificationData, 'pref_name', '---') }}
</v-col> </v-col>
</v-row> </v-row>
<v-divider /> <v-divider />
...@@ -33,7 +35,7 @@ ...@@ -33,7 +35,7 @@
<v-row class="details-row" dense> <v-row class="details-row" dense>
<v-col cols="12"> <v-col cols="12">
<b>Organism:</b> <b>Organism:</b>
{{ nameAndClassificationData.organism }} {{ getPropertyPalue(nameAndClassificationData, 'organism', '---') }}
</v-col> </v-col>
</v-row> </v-row>
<v-divider /> <v-divider />
...@@ -66,6 +68,7 @@ ...@@ -66,6 +68,7 @@
import { mapState } from 'vuex' import { mapState } from 'vuex'
import Synonyms from '~/web-components-submodule/components/common/ReportCards/Shared/Synonyms.vue' import Synonyms from '~/web-components-submodule/components/common/ReportCards/Shared/Synonyms.vue'
import ProteinTargetClassification from '~/web-components-submodule/components/common/ReportCards/Target/ProteinTargetClassification.vue' import ProteinTargetClassification from '~/web-components-submodule/components/common/ReportCards/Target/ProteinTargetClassification.vue'
import ObjectPropertyAccess from '~/web-components-submodule/utils/ObjectPropertyAccess.js'
export default { export default {
components: { components: {
...@@ -95,10 +98,12 @@ export default { ...@@ -95,10 +98,12 @@ export default {
return 'No' return 'No'
}, },
}), }),
mounted() { mounted() {
this.$store.dispatch('target/nameAndClassification/loadData', this.itemID) this.$store.dispatch('target/nameAndClassification/loadData', this.itemID)
}, },
methods: {
getPropertyPalue: ObjectPropertyAccess.getPropertyPalue,
},
} }
</script> </script>
......
static/img/placeholders/structureLoadingPlaceholder.png

55 KiB

Subproject commit 28f28cd2cafd89687a170b5a9191b1ed8199c026 Subproject commit 6e14f50d6975490861689cd3f838830632b7448d
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