Skip to content

Commit

Permalink
feat(dat): hide when tiered access is enabled
Browse files Browse the repository at this point in the history
  • Loading branch information
paulineribeyre committed Aug 6, 2019
1 parent b17f09c commit 7cbbe7b
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions src/GuppyDataExplorer/ExplorerVisualization/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,17 @@ class ExplorerVisualization extends React.Component {

updateConnectedFilter = async (heatMapMainYAxisVar) => {
const caseField = this.props.guppyConfig.manifestMapping.referenceIdFieldInDataIndex;
const res = await this.props.downloadRawDataByFields({ fields: [caseField] });
const caseIDList = res.map(e => e.node_id);
let caseIDList;
try {
const res = await this.props.downloadRawDataByFields({ fields: [caseField] });
caseIDList = res.map(e => e.node_id);
}
catch {
// when tiered access is enabled, we cannot get the list of IDs because
// the user does not have access to all projects. In that case, the
// heatmap is not displayed.
caseIDList = [];
}
this.connectedFilter.current.setFilter(
{ [heatMapMainYAxisVar]: { selectedValues: caseIDList } },
);
Expand Down

0 comments on commit 7cbbe7b

Please sign in to comment.