Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Single cell browser component #796

Merged
merged 6 commits into from
Nov 22, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
713 changes: 713 additions & 0 deletions src/components/researchPortal/ResearchBarPlotV2.vue

Large diffs are not rendered by default.

41 changes: 30 additions & 11 deletions src/components/researchPortal/ResearchDataTable.vue
Original file line number Diff line number Diff line change
Expand Up @@ -148,21 +148,21 @@
<b-icon
:icon="!!stared ? 'star-fill' : 'star'"
style="color: #ffcc00; cursor: pointer"


>
</b-icon>
<span class="star-items-options">
<ul>
<li><a href="javascript:;" @click="showHideStared()">Show stard only</a></li>
<li><a href="javascript:;" @click="starAll()">Star / unstar all</a></li>
</ul>
</span>
</th>
<th v-if="!!tableFormat['select column']" class="select-items-control">

</b-icon>
<span class="star-items-options">
<ul>
<li><a href="javascript:;" @click="showHideStared()">Show stard only</a></li>
<li><a href="javascript:;" @click="starAll()">Star / unstar all</a></li>
</ul>
</span>
</th>
<template v-for="(value, index) in topRows">
<th
v-if="getIfChecked(value) == true"
v-if="getIfChecked(value) == true && value !== tableFormat['select column']"
:key="index"
@click="!!multiSectionPage?callFilter(value):applySorting(value)"
class="byor-tooltip"
Expand Down Expand Up @@ -212,11 +212,15 @@
></b-icon
></span>
</td>
<td v-if="!!tableFormat['select column']">
<button @click="selectRow(value)" :disabled="isSelected(value)">Select</button>
</td>
<template
v-for="(tdValue, tdKey) in value"
v-if="
topRows.includes(tdKey) &&
getIfChecked(tdKey) == true
getIfChecked(tdKey) == true &&
tdKey !== tableFormat['select column']
"
>
<td
Expand Down Expand Up @@ -361,6 +365,7 @@

<script>
import Vue from "vue";
import EventBus from "@/utils/eventBus";
import ResearchDataTableFeatures from "@/components/researchPortal/ResearchDataTableFeatures.vue";
import ResearchSummaryPlot from "@/components/researchPortal/ResearchSummaryPlot.vue";
import ResearchSubSection from "@/components/researchPortal/ResearchSubSection.vue";
Expand Down Expand Up @@ -396,6 +401,7 @@ export default Vue.component("research-data-table", {
compareGroups: [],
stared: false,
staredAll: false,
selected: null,
subSectionData:[],
subSectionHidden:[],
subSectionLoading:[]
Expand Down Expand Up @@ -1122,6 +1128,19 @@ export default Vue.component("research-data-table", {
this.stared = false;
}
},
selectRow(ITEM){
let value = ITEM[this.tableFormat["select column"]];
this.selected = value;
EventBus.$emit('on-select', {id: this.sectionId, value});
},
isSelected(ITEM){
let value = ITEM[this.tableFormat["select column"]];
if(this.selected===value){
return true;
}else{
return false;
}
},
getColorIndex(SKEY) {
let colorIndex = "";
let compareGroups = this.compareGroups;
Expand Down
Loading
Loading