Skip to content

Commit

Permalink
Merge pull request #61 from qlik-oss/DEB-232/DoubleMeasure
Browse files Browse the repository at this point in the history
Made the table cell keys more unique
  • Loading branch information
AlbertBackenhof authored May 27, 2019
2 parents 80f9760 + 1436463 commit c22b7f5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/data-table/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ const DataTable = ({ data, general, component, renderData, styling }) => {
}

const { dimension1: dimension1Info, dimension2, measurement } = measurementData.parents;
const id = `${dimension1Info.elementNumber}-${dimension2 && dimension2.elementNumber}-${measurement.header}`;
const id = `${dimension1Info.elementNumber}-${dimension2 && dimension2.elementNumber}-${measurement.header}-${measurement.index}`;
return (
<DataCell
data={data}
Expand Down
4 changes: 2 additions & 2 deletions src/headers-table/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ const HeadersTable = ({ data, general, component, styling, isKpi }) => {
baseCSS={baseCSS}
general={general}
hasSecondDimension={hasSecondDimension}
key={`${measurementEntry.displayValue}-${measurementEntry.name}`}
key={`${measurementEntry.displayValue}-${measurementEntry.name}-${measurementEntry.index}`}
measurement={measurementEntry}
styling={styling}
/>
Expand Down Expand Up @@ -105,7 +105,7 @@ const HeadersTable = ({ data, general, component, styling, isKpi }) => {
dimensionEntry={dimensionEntry}
general={general}
hasSecondDimension={hasSecondDimension}
key={`${measurementEntry.displayValue}-${measurementEntry.name}-${dimensionEntry.name}`}
key={`${measurementEntry.displayValue}-${measurementEntry.name}-${measurementEntry.index}-${dimensionEntry.name}`}
measurement={measurementEntry}
styling={styling}
/>
Expand Down

0 comments on commit c22b7f5

Please sign in to comment.