feat: add AggregationValue type and improve type safety in aggregation filtering

This commit is contained in:
DarkPhoenix2704
2025-08-01 06:47:06 +00:00
parent 459c7ecb61
commit 7c9c2c1711

View File

@@ -56,6 +56,8 @@ const AllAggregations = {
...DateAggregations,
};
type AggregationValue = typeof AllAggregations[keyof typeof AllAggregations]
const getAvailableAggregations = (type: string, parsed_tree?): string[] => {
let returnAggregations = [];
if (type === UITypes.Formula && parsed_tree?.dataType) {
@@ -235,4 +237,5 @@ export {
AttachmentAggregations,
AllAggregations,
formatAggregation,
AggregationValue,
};