From: Thomas Wood Date: Wed, 17 Jun 2009 16:37:43 +0000 (+0000) Subject: Add an edit link to the browse page for nodes, since it's been bugging me a while... X-Git-Tag: live~7034 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/3edd81f03b5f06636e0e206fd8427e8c4456658b?ds=sidebyside Add an edit link to the browse page for nodes, since it's been bugging me a while. Ways will follow when i can work out how to generate a lat/lon for them... Translation updates required (small edit) --- diff --git a/app/views/browse/node.html.erb b/app/views/browse/node.html.erb index 19aeb7dca..14e8aa503 100644 --- a/app/views/browse/node.html.erb +++ b/app/views/browse/node.html.erb @@ -16,7 +16,9 @@ <%= render :partial => "node_details", :object => @node %>
<%= t'browse.node.download', :download_xml_link => link_to(t('browse.node.download_xml'), :controller => "node", :action => "read"), - :view_history_link => link_to(t('browse.node.view_history'), :action => "node_history") %> + :view_history_link => link_to(t('browse.node.view_history'), :action => "node_history"), + :edit_link => link_to(t('browse.node.edit'), :controller => "site", :action => "edit", :lat => @node.lat, :lon => @node.lon, :zoom => 18, :node => @node.id) + %> <%= render :partial => "map", :object => @node %> diff --git a/config/locales/en.yml b/config/locales/en.yml index 94a5f6873..dd76441ca 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -117,9 +117,10 @@ en: node: node: "Node" node_title: "Node: {{node_name}}" - download: "{{download_xml_link}} or {{view_history_link}}" + download: "{{download_xml_link}}, {{view_history_link}} or {{edit_link}}" download_xml: "Download XML" view_history: "view history" + edit: "edit" not_found: sorry: "Sorry, the {{type}} with the id {{id}}, could not be found." type: