Fixed: GET /time_entries.xml ignores limit/offset parameters (#8356).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5881 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2011-05-22 10:48:59 +00:00
parent ef00501c36
commit 12801ca031
3 changed files with 14 additions and 4 deletions
+3 -3
View File
@@ -67,13 +67,13 @@ class TimelogController < ApplicationController
}
format.api {
@entry_count = TimeEntry.visible.count(:include => [:project, :issue], :conditions => cond.conditions)
@entry_pages = Paginator.new self, @entry_count, per_page_option, params['page']
@offset, @limit = api_offset_and_limit
@entries = TimeEntry.visible.find(:all,
:include => [:project, :activity, :user, {:issue => :tracker}],
:conditions => cond.conditions,
:order => sort_clause,
:limit => @entry_pages.items_per_page,
:offset => @entry_pages.current.offset)
:limit => @limit,
:offset => @offset)
}
format.atom {
entries = TimeEntry.visible.find(:all,