Reputation: 19247
Interesting bug or side effect or something...
using will_paginate to handle the pagination of two sets of data on the same screen (blog_article and favorites_list)
what happens is when the user clicks "next" for blog_articles, it also paginates favorites_lists, which disappears if there are fewer pages of favorites than blogs.
The issue (presumably) is that the url contains "page=3" and there's no description of WHICH set of data is being paginated.
Any thoughts on the "right" way to have the url (and controller code) specify WHICH dataset is being paginated?
Upvotes: 1
Views: 259
Reputation: 19247
found the answer, the :param_name
parameter
will_paginate @users, :param_name => 'user_page'
at http://candidcode.com/2009/11/03/paginating-multiple-models-using-will_paginate-on-the-same-page/
Upvotes: 2