After a user filters an index page I pass a list of structs to the view to be displayed. Is it possible to pass that list back to the controller for sorting?
Why do the sorting in the controller? That sounds like a view concern to me.
Sorting logic defines the sort which requires business logic, I believe, this would be best handled by the controller or a service layer.
You can not pass the list back. But what is stopping you from passing it in already sorted?
Trying to allow the user to sort asc/desc depending on which table header is clicked on. There is also a filter system involved. As far as I know the only way to accomplish this after a sort is selected to take the currently applied filters, pass that through the query, and then apply the newly selected sort. I was just curious if there was a way to bypass running another query and just filter the current list. Perhaps through serialization or something similar.