Get the right columns from aggregation
This commit is contained in:
parent
acd0610517
commit
e93fe13b41
@ -44,6 +44,8 @@ module.exports = class AggregationMapConfigAdapter {
|
||||
const aggregationColumns = this._getAggregationColumns(aggregation);
|
||||
const layerColumns = mapConfig.getColumnsByLayer(index);
|
||||
|
||||
console.log(aggregationColumns, layerColumns);
|
||||
|
||||
if (layerColumns.length === 0) {
|
||||
continue;
|
||||
}
|
||||
@ -210,12 +212,11 @@ module.exports = class AggregationMapConfigAdapter {
|
||||
const hasAggregationColumns = aggregation !== undefined &&
|
||||
typeof aggregation !== 'boolean' &&
|
||||
typeof aggregation.columns === 'object';
|
||||
|
||||
let aggregationColumns = [];
|
||||
|
||||
if (hasAggregationColumns) {
|
||||
aggregationColumns = Object.keys(aggregation.columns).map(key => {
|
||||
return aggregation.columns[key].aggregated_column;
|
||||
});
|
||||
aggregationColumns = Object.keys(aggregation.columns);
|
||||
}
|
||||
|
||||
return aggregationColumns;
|
||||
|
Loading…
Reference in New Issue
Block a user