Reputation: 2982
I have an index page with a search form that generates a list of partials. The data is all comming from the same table, but there are 10 unique types of items, each with some unique data fields. The partials are all customized tables to display the data. Picture like a long list of different types of little business cards with graphics logos on them.
So, right now I have a div with a scrollbar holding this list of little custom tables. For maybe 100 records or so it would work fine like this, but of course the result sets will end up being a lot bigger.
I'm just looking for suggestions on how to handle this as far as pagination (maybe even also being sortable if somehow this could be done through table id's or something). I'm invested in Prototype right now but would it be possible to use something like jQuery's Tablesorter plugin (or anything else) where each record of the table would be one of my little custom tables?
I'm on an internal work server w/ Ruby 1.86 & Rails 2.35. I get stuck a lot with gems I can't use (like Searchlogic) which require Ruby 1.87.
-Thanks, hopefully I made sense.
Upvotes: 0
Views: 63
Reputation: 4799
Have you considered using the WillPaginate gem? It'll handle this for you without requiring much setup or configuration.
Upvotes: 1