diff --git a/app/controllers/moderator/post/queues_controller.rb b/app/controllers/moderator/post/queues_controller.rb index 4af728feb..189ec50da 100644 --- a/app/controllers/moderator/post/queues_controller.rb +++ b/app/controllers/moderator/post/queues_controller.rb @@ -5,12 +5,22 @@ module Moderator before_filter :post_approvers_only def show + if params[:per_page] + session["mq_per_page"] = params[:per_page] + end + ::Post.without_timeout do - @posts = ::Post.order("posts.id asc").pending_or_flagged.available_for_moderation(params[:hidden]).search(:tag_match => "#{params[:query]} status:any").paginate(params[:page], :limit => 25) + @posts = ::Post.order("posts.id asc").pending_or_flagged.available_for_moderation(params[:hidden]).search(:tag_match => "#{params[:query]} status:any").paginate(params[:page], :limit => per_page) @posts.each # hack to force rails to eager load end respond_with(@posts) end + + protected + + def per_page + session["mq_per_page"] || params[:per_page] || 25 + end end end end diff --git a/app/views/moderator/post/queues/show.html.erb b/app/views/moderator/post/queues/show.html.erb index 29337d62b..bfc3a002d 100644 --- a/app/views/moderator/post/queues/show.html.erb +++ b/app/views/moderator/post/queues/show.html.erb @@ -1,15 +1,16 @@
- -

Moderation Queue

+ +

Deletion Guidelines