Skip to content

Commit

Permalink
Fixed master object bug
Browse files Browse the repository at this point in the history
-Previously the smart pivot didn't render as
 a master object.

Issue: DEB-173
  • Loading branch information
Albert Backenhof authored and Albert Backenhof committed May 3, 2019
1 parent 2f59d97 commit 5d45f57
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/dataset.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,13 @@ export async function initializeDataCube (component, layout) {
}

const app = qlik.currApp(component);
const hyperCubeDef = (await component.backendApi.getProperties()).qHyperCubeDef;
const properties = (await component.backendApi.getProperties());

// If this is a master object, fetch the hyperCubeDef of the original object
const hyperCubeDef = properties.qExtendsId
? (await app.getObjectProperties(properties.qExtendsId)).properties.qHyperCubeDef
: properties.qHyperCubeDef;

return buildDataCube(hyperCubeDef, layout.qHyperCube.qDimensionInfo.length === 2, app);
}

Expand Down

0 comments on commit 5d45f57

Please sign in to comment.