fix slow backend index page

This commit is contained in:
manson 2014-08-20 11:47:33 +08:00
parent 93337c1019
commit 8aa5a4f7d6
1 changed files with 2 additions and 1 deletions

View File

@ -361,7 +361,8 @@ class ApplicationController < ActionController::Base
end
if pagination
Kaminari.paginate_array(filter_authorized_objects(objects)).page(params[:page]).per(10)
# Kaminari.paginate_array(filter_authorized_objects(objects)).page(params[:page]).per(10)
filter_authorized_objects(objects).page(params[:page]).per(10)
else
filter_authorized_objects(objects)
end