Use scoped models for pagination.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@11027 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
1cf379f370
commit
85fb937a4e
|
@ -25,7 +25,7 @@ class IssueStatusesController < ApplicationController
|
|||
def index
|
||||
respond_to do |format|
|
||||
format.html {
|
||||
@issue_status_pages, @issue_statuses = paginate :issue_statuses, :per_page => 25, :order => "position"
|
||||
@issue_status_pages, @issue_statuses = paginate IssueStatus.sorted, :per_page => 25
|
||||
render :action => "index", :layout => false if request.xhr?
|
||||
}
|
||||
format.api {
|
||||
|
|
|
@ -26,7 +26,7 @@ class RolesController < ApplicationController
|
|||
def index
|
||||
respond_to do |format|
|
||||
format.html {
|
||||
@role_pages, @roles = paginate :roles, :per_page => 25, :order => 'builtin, position'
|
||||
@role_pages, @roles = paginate Role.sorted, :per_page => 25
|
||||
render :action => "index", :layout => false if request.xhr?
|
||||
}
|
||||
format.api {
|
||||
|
|
|
@ -25,7 +25,7 @@ class TrackersController < ApplicationController
|
|||
def index
|
||||
respond_to do |format|
|
||||
format.html {
|
||||
@tracker_pages, @trackers = paginate :trackers, :per_page => 10, :order => 'position'
|
||||
@tracker_pages, @trackers = paginate Tracker.sorted, :per_page => 10
|
||||
render :action => "index", :layout => false if request.xhr?
|
||||
}
|
||||
format.api {
|
||||
|
|
Loading…
Reference in New Issue