[Pools] Fix exception on the ordering page

Broken through 0381653e80
This commit is contained in:
Earlopain 2024-02-27 18:37:22 +01:00
parent a3a508c92c
commit 7c03dddc56
No known key found for this signature in database
GPG Key ID: 48860312319ADF61
2 changed files with 6 additions and 1 deletions

View File

@ -6,7 +6,7 @@
<%= render "posts/partials/common/inline_blacklist" %> <%= render "posts/partials/common/inline_blacklist" %>
<ul id="sortable"> <ul id="sortable">
<% @pool.posts(:limit => 1_000).each do |post| %> <% @pool.posts.paginate(1, limit: 1_000).each do |post| %>
<li class="ui-state-default" id="pool[post_ids]_<%= post.id %>"> <li class="ui-state-default" id="pool[post_ids]_<%= post.id %>">
<%= PostPresenter.preview(post).presence || "Hidden: Post ##{post.id}" %> <%= PostPresenter.preview(post).presence || "Hidden: Post ##{post.id}" %>
</li> </li>

View File

@ -115,5 +115,10 @@ class PoolsControllerTest < ActionDispatch::IntegrationTest
assert_response :missing assert_response :missing
end end
end end
should "render the order action" do
get_auth edit_pool_order_path(@pool), @user
assert_response :success
end
end end
end end