I'm back to this good old problem where using a Varien_Data_Collection
in a grid does not handle sorting, paging nor filtering.
I've found some useful resources such as :
- https://www.maximehuran.fr/en/use-a-varien-data-collection-with-filters-sorts-orders-and-limits/
- Filtering error when using custom Varien object collection in admin grid
The first one is incomplete whereas the answer in the second one is too broad to help.
I know I have to use a custom collection class that extends Varien_Data_Collection
I simply wanna know exactly the methods (and the details of them) I need to implement inside to be able to handle paging, sorting and filtering ?
Best Answer
After several tests I managed to get it right.
Here's the collection class that extends
Varien_Data_Collection
and that handles paging / filtering / sorting so it can be used in admin grids.Feel free to let me know if you find a bug or something missing