With this code:
deals.paginate(page: @page, per_page: PER_PAGE, inner_window: 2, outer_window: 1)
I get this Error:
ArgumentError (Unknown key(s): inner_window, outer_window):
Other than that it's a really great gem. Keep up the good work.
The outer_window and inner_window options are for the will_paginate view helper. I haven't tested it, but I guess it works like this. In the controller:
deals = deals.paginate(page: @page, per_page: PER_PAGE)
and in the view
<%= will_paginate deals, :inner_window => 2, :outer_window => 1 %>
@fschwahn is right. Also, you can set defaults like this
WillPaginate::ViewHelpers.pagination_options[:inner_window] = 2
WillPaginate::ViewHelpers.pagination_options[:outer_window] = 1
for example within initializers directory.
@fschwahn is right. You are using these options in the wrong method.
I will write better usage docs soon in the wiki.