diff --git a/components/report_cards/chemical_probe/ActivityProfileComponents/ActivityDataSingleTab.vue b/components/report_cards/chemical_probe/ActivityProfileComponents/ActivityDataSingleTab.vue index 00c24ac428698aa18dbb8ec8369e5316f5ec2fed..3a90c7aea4ab200e59a5349504f60507088f2de9 100644 --- a/components/report_cards/chemical_probe/ActivityProfileComponents/ActivityDataSingleTab.vue +++ b/components/report_cards/chemical_probe/ActivityProfileComponents/ActivityDataSingleTab.vue @@ -36,7 +36,7 @@ export default { return { propertiesGroups: { 1: { - id: 'eubopen_compound_probe_profile', + id: 'eubopen_compound_activity_profile', selected: true, allHeaders: [], }, diff --git a/components/report_cards/chemical_probe/ActivityProfileComponents/ActivityDataTabs.vue b/components/report_cards/chemical_probe/ActivityProfileComponents/ActivityDataTabs.vue index 4f5c28ef9ab5d645b163d38c89bc34b7366de626..caef41e55ddd91eb376a03f86a6db8b9794b14ab 100644 --- a/components/report_cards/chemical_probe/ActivityProfileComponents/ActivityDataTabs.vue +++ b/components/report_cards/chemical_probe/ActivityProfileComponents/ActivityDataTabs.vue @@ -1,5 +1,6 @@ <template> <div> + <DownloadButton :item-i-d="itemID" :section-key="sectionKey" /> <v-tabs v-model="tab" show-arrows> <v-tab v-for="item in shownSections" :key="item.key"> {{ item.title }} @@ -16,8 +17,9 @@ <script> import ActivityDataSingleTab from '~/components/report_cards/chemical_probe/ActivityProfileComponents/ActivityDataSingleTab.vue' +import DownloadButton from '~/components/report_cards/chemical_probe/ActivityProfileComponents/DownloadButton.vue' export default { - components: { ActivityDataSingleTab }, + components: { ActivityDataSingleTab, DownloadButton }, props: { sectionKey: { type: String, @@ -43,7 +45,7 @@ export default { key: 'INCU', filter: 'filter2', title: 'Incucyte Cell Viability', - label: 'Incucyte Cell Viability', + label: 'Incucyte Cell Viability Data', }, { key: 'LIABILITY', diff --git a/components/report_cards/chemical_probe/ActivityProfileComponents/DownloadButton.vue b/components/report_cards/chemical_probe/ActivityProfileComponents/DownloadButton.vue new file mode 100644 index 0000000000000000000000000000000000000000..0805e82638d398060569c7baa6ef00da560cf114 --- /dev/null +++ b/components/report_cards/chemical_probe/ActivityProfileComponents/DownloadButton.vue @@ -0,0 +1,79 @@ +<template> + <div> + <v-banner> + <v-row> + <v-col cols="6" + ><ActionsProgress :dataset-state="datasetState" + /></v-col> + <v-col cols="6" + ><DatasetDownloadButtons + :store-module-name="storeModuleName" + :dataset-state="datasetState" + /></v-col> + </v-row> + </v-banner> + </div> +</template> + +<script> +import IndexNames from '@/web-components-submodule/standardisation/IndexNames.js' +import { datasetMixin } from '~/web-components-submodule/mixins/datasets/datasetMixin.js' +import EntityNames from '~/web-components-submodule/standardisation/EntityNames.js' +import DatasetDownloadButtons from '~/web-components-submodule/components/common/Browsers/actions/Downloads/DatasetDownloadButtons.vue' +import ActionsProgress from '~/web-components-submodule/components/common/Browsers/actions/ActionsProgress.vue' + +export default { + components: { + DatasetDownloadButtons, + ActionsProgress, + }, + mixins: [datasetMixin], + props: { + itemID: { + type: String, + default: () => undefined, + }, + sectionKey: { + type: String, + default: () => undefined, + }, + }, + data() { + return { + propertiesGroups: { + 1: { + id: 'eubopen_compound_activity_profile_download', + selected: true, + allHeaders: [], + }, + }, + entityID: EntityNames.EubopenActivity.entityID, + customDataRepresentationParams: { + possiblePageSizes: [5, 10], + itemsPerPage: 5, + }, + } + }, + computed: { + storeModuleName() { + return `activity_profile_${this.sectionKey}` + }, + starterParams() { + return { + chemblID: this.itemID, + propertiesGroups: this.propertiesGroups, + initialQuery: { + query: { + bool: { + must: [{ terms: { molecule_chembl_id: [this.itemID] } }], + }, + }, + }, + indexName: IndexNames.getIndexNameFromEntityID(this.entityID), + } + }, + }, +} +</script> + +<style></style> diff --git a/web-components-submodule b/web-components-submodule index 17dea0638968ad291c50a5e23648eeddf193f50e..f878bf7551b98e38f9bf1e71a1153f1499b07112 160000 --- a/web-components-submodule +++ b/web-components-submodule @@ -1 +1 @@ -Subproject commit 17dea0638968ad291c50a5e23648eeddf193f50e +Subproject commit f878bf7551b98e38f9bf1e71a1153f1499b07112