Replies: 11 comments 8 replies
-
Yeah, this topic is pretty tricky for me as well. The documentation comes with one clue, nearby Ok. I'm expected to manually group the rows. But what does it mean in |
Beta Was this translation helpful? Give feedback.
-
Anything new with this ? There is no documentation or example of how the data should be passed for |
Beta Was this translation helpful? Give feedback.
-
Any update on this? Crazy that there is no info available |
Beta Was this translation helpful? Give feedback.
-
I am struggling with this too... Seems to mess up the entire table api. |
Beta Was this translation helpful? Give feedback.
-
I've been digging into this in the last couple of days and I think the documentation is a bit misleading. It says that if However, this can be achieved by using functionality of
With this you can achieve server side grouping. This will apply to all the other row model functionality. |
Beta Was this translation helpful? Give feedback.
-
I am 90% done with the example. There are quite a few bits. You will all have a repo sometime next week
…________________________________
From: Keith Hubert ***@***.***>
Sent: Friday, April 19, 2024 9:21:41 AM
To: TanStack/table ***@***.***>
Cc: Deshi Rahim ***@***.***>; Mention ***@***.***>
Subject: Re: [TanStack/table] [v8] Manual grouping on server (Discussion #4990)
@deshiknaves<https://github.com/deshiknaves> I've been checking this thread daily for any updates 😂
We desperately need some docs and examples regarding manual grouping and server-side subRows. I'll be sure to update if I make any progress.
—
Reply to this email directly, view it on GitHub<#4990 (reply in thread)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/AAGSU4V7BAUGXCLMVNH4VWDY6FABLAVCNFSM6AAAAAA2WZNFCWVHI2DSMVQWIX3LMV43SRDJONRXK43TNFXW4Q3PNVWWK3TUHM4TCNRYGY4DS>.
You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Here is the example on how to sort/group on the server. Let me know the right format to document this in. Also if there are other examples you'd like to see. It's very much possible to do computation on the server and present it on the client side using this library. |
Beta Was this translation helpful? Give feedback.
-
This was also bugging me for a while now, and I spent part of my day digging into it. Here are my findings. Hopefully some of you will find it useful. Client side groupingIf you don't need server side grouping, and you just want to change how default grouping works, copy Server side groupingWith server side grouping, either I am still missing something or this case wasn't truly considered. The contextThe core of grouping inside React Table are two properties that each grouped row should have. These are The solutionI think the best way to add these two missing properties is via
This might be easier to understand with actual code examples, so I prepared a reproduction project. Example repoHere is a commit made to my example Material React Table project, that adds all necessary bits to enable manual grouping on the server: pf1gura/react-table-manual-grouping-example@4397ef1. In this example, grouping works only for the first selected column, but that is only due to the fact that I wanted to keep it simple. The same approach will work on as many |
Beta Was this translation helpful? Give feedback.
-
Thank you all for the contributions to this thread. Despite the helpful suggestions, I'm still facing challenges with server-side grouping and aggregation. Here's the issue: I'm also trying to incorporate server-calculated aggregate values for certain columns within these groups. This is where I run into trouble. I've tried following @deshiknaves' approach with a custom
It seems to depend on the To complicate matters further, I'm using material-react-table instead of the base tanstack-table, and the documentation and examples for this scenario are limited. Any guidance or insights would be greatly appreciated! |
Beta Was this translation helpful? Give feedback.
-
If this property doesn't do anything why it's in the docs? It should be removed. Looks like we all just probably need to mock the behavior of row grouping by using subrows with depth of 1. |
Beta Was this translation helpful? Give feedback.
-
Hello, |
Beta Was this translation helpful? Give feedback.
-
Hi @tannerlinsley, thanks for the awesome libraries from Tanstack.
I have a question and I haven't been able to find a solution or example.
The table supports manual grouping on server, but how the data I pass into the table should look like?
Thanks
Beta Was this translation helpful? Give feedback.
All reactions