1
0
Fork 0
mirror of https://gitlab.com/bramw/baserow.git synced 2025-04-17 10:22:36 +00:00

Merge branch 'chart-limit-offered-agg-types' into 'develop'

Only list aggregation types that make sense for source table in chart configuration

See merge request 
This commit is contained in:
Petr Stribny 2025-03-11 07:48:24 +00:00
commit 7bad56bbcb

View file

@ -98,7 +98,13 @@ export default {
}, },
computed: { computed: {
groupedAggregationTypes() { groupedAggregationTypes() {
return this.$registry.getOrderedList('groupedAggregation') const allAggregationTypes =
this.$registry.getOrderedList('groupedAggregation')
return allAggregationTypes.filter((aggType) => {
return this.tableFields.some((tableField) =>
aggType.fieldIsCompatible(tableField)
)
})
}, },
aggregationTypesAvailableForSelection() { aggregationTypesAvailableForSelection() {
return this.groupedAggregationTypes.filter( return this.groupedAggregationTypes.filter(