* Added links to previous and next revisions on revision view (patch by Cyril Mougel slightly edited)

* Fixed TimelogController#report december error
* Fixed ProjectsControllerTest#test_activity 1st and 2nd day of the month failure

git-svn-id: http://redmine.rubyforge.org/svn/trunk@938 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2007-12-01 17:15:42 +00:00
parent 3baf086e2d
commit db002edabd
10 changed files with 118 additions and 11 deletions
+11 -3
View File
@@ -19,6 +19,9 @@ require 'SVG/Graph/Bar'
require 'SVG/Graph/BarHorizontal'
require 'digest/sha1'
class ChangesetNotFound < Exception
end
class RepositoriesController < ApplicationController
layout 'base'
before_filter :find_repository, :except => :edit
@@ -94,14 +97,19 @@ class RepositoriesController < ApplicationController
def revision
@changeset = @repository.changesets.find_by_revision(@rev)
show_error and return unless @changeset
raise ChangesetNotFound unless @changeset
@changes_count = @changeset.changes.size
@changes_pages = Paginator.new self, @changes_count, 150, params['page']
@changes = @changeset.changes.find(:all,
:limit => @changes_pages.items_per_page,
:offset => @changes_pages.current.offset)
render :action => "revision", :layout => false if request.xhr?
respond_to do |format|
format.html
format.js {render :layout => false}
end
rescue ChangesetNotFound
show_error
end
def diff