-
Notifications
You must be signed in to change notification settings - Fork 1
Description
Hello!
I’m trying to use aggregationFn in my column definitions to display aggregated values when grouping rows, but the summed values don’t appear as expected. Here’s my current setup:
columnDefs = [
{"accessorKey": "region", "header": "region"},
{"accessorKey": "id_item", "header": "id_item"},
{"accessorKey": "id_doc", "header": "id_doc", "enableGrouping": False},
{"accessorKey": "revenue", "header": "revenue", "aggregationFn": "sum"},
]
grid = dmc.Box(DashMantineReactTable(
data=data,
columns=columnDefs,
mrtProps={
"enablePagination": False,
"enableRowVirtualization": True,
"enableColumnResizing": True,
"enableGrouping": True,
}
), mt='md')
Could you please guide me on the correct way to implement aggregationFn so that grouped rows display the sum (or other aggregations) properly?
Thank you in advance for your help!