Skip to content

Commit

Permalink
Fix pagination in existing image/resource partial after uploading new…
Browse files Browse the repository at this point in the history
… image/resource.

Since we call insert action from create action params passed to
will_paginate holds :action => "create" which is not correct and thus
breaks.
  • Loading branch information
ugisozols authored and parndt committed Sep 27, 2012
1 parent 23952e1 commit 9ca26e7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,7 @@
<%= t('no_results', :scope => 'refinery.admin.search') %>
<% end %>
</div>

<%= will_paginate @images, :params => params.dup %>
<%= will_paginate @images, :params => params.dup.merge(:action => "insert") %>

<% unless @app_dialog or @images.empty? %>
<div id="existing_image_size_area" class="clearfix">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
</div>
</div>

<%= will_paginate @resources, :params => params.dup %>
<%= will_paginate @resources, :params => params.dup.merge(:action => "insert") %>

<%= render '/refinery/admin/form_actions', :f => nil,
:submit_button_text => t('.button_text'),
Expand Down

0 comments on commit 9ca26e7

Please sign in to comment.