X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/2c16177174d276335babcca5439cd4e97af62ffa..b7b2b502cf2b119208e3c1f79e4a4e38cc0edcc5:/app/controllers/browse_controller.rb diff --git a/app/controllers/browse_controller.rb b/app/controllers/browse_controller.rb index 94a8a09a0..2c6c3dc5f 100644 --- a/app/controllers/browse_controller.rb +++ b/app/controllers/browse_controller.rb @@ -118,6 +118,8 @@ class BrowseController < ApplicationController @changeset = Changeset.find(params[:id]) @title = "Changeset | #{@changeset.id}" + @next = Changeset.find(:first, :order => "id ASC", :conditions => [ "id > :id", { :id => @changeset.id }] ) + @prev = Changeset.find(:first, :order => "id DESC", :conditions => [ "id < :id", { :id => @changeset.id }] ) rescue ActiveRecord::RecordNotFound @type = "changeset" render :action => "not_found", :status => :not_found