X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/4d91fe3dd95c1058cb8d24fd4c900223e30b9059..2a3bc0a38789b29b8798eafd80fc4fb77c5c7957:/app/controllers/browse_controller.rb diff --git a/app/controllers/browse_controller.rb b/app/controllers/browse_controller.rb index 2c22a9b83..622bcadd5 100644 --- a/app/controllers/browse_controller.rb +++ b/app/controllers/browse_controller.rb @@ -30,9 +30,6 @@ class BrowseController < ApplicationController @way = Way.find(params[:id], :include => [:way_tags, {:changeset => :user}, {:nodes => [:node_tags, {:ways => :way_tags}]}, :containing_relation_members]) @next = Way.visible.where("id > ?", @way.id).order("id ASC").first @prev = Way.visible.where("id < ?", @way.id).order("id DESC").first - - # Used for edit link, takes approx middle node of way - @midnode = @way.nodes[@way.nodes.length/2] rescue ActiveRecord::RecordNotFound render :action => "not_found", :status => :not_found end @@ -83,6 +80,7 @@ class BrowseController < ApplicationController def note @type = "note" @note = Note.find(params[:id]) + @title = "#{I18n.t('browse.note.title')} | #{@note.id}" @next = Note.find(:first, :order => "id ASC", :conditions => [ "status != 'hidden' AND id > :id", { :id => @note.id }] ) @prev = Note.find(:first, :order => "id DESC", :conditions => [ "status != 'hidden' AND id < :id", { :id => @note.id }] ) rescue ActiveRecord::RecordNotFound