Orderable column
Is it possible to pass a second parameter to orderable to order grouped by the second parameter? each group that has its order from 1 to X
4 Replies
1. You mean sortable() and not orderable()?
2. This snippet may help if I understood correctly:
From docs: https://filamentphp.com/docs/3.x/tables/columns/getting-started#sorting
I mean sortable. I have a table with the following columns: id, order, event_id, participant_id.
And I want something like this:
1 1 1 1
2 2 1 2
3 3 1 3
4 1 2 1
5 2 2 2
6 3 2 3
So yeah, write your custom function inside sortable()
Sorry, sortable() no, I need reorderable() to order by groups
I solved it by adding a filter, I always have one active so I can order each event independently