From: Tom Hughes Date: Thu, 12 Apr 2012 14:49:41 +0000 (+0100) Subject: Don't show "Browse Map Data" when we're not on the map view X-Git-Tag: live~5574 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/ababece2cc0e5caf946242d097e80ae7c3dc877d Don't show "Browse Map Data" when we're not on the map view --- diff --git a/app/views/layouts/site.html.erb b/app/views/layouts/site.html.erb index 2d0c60a96..c572b1926 100644 --- a/app/views/layouts/site.html.erb +++ b/app/views/layouts/site.html.erb @@ -51,9 +51,7 @@ <% Editors::ALL_EDITORS.each do |editor| %>
  • <%= link_to t('layouts.edit_with', :editor => t("editor.#{editor}.description")), {:controller => 'site', :action => 'edit', :editor => editor}, {:id => editor + 'anchor', :class => "geolink llz object"} %>
  • <% end %> - <% unless STATUS == :api_offline or STATUS == :database_offline %> -
  • <%= link_to_function(t('browse.start_rjs.data_layer_name'), 'showData()') %>
  • - <% end %> + <%= yield :editmenu %> diff --git a/app/views/site/index.html.erb b/app/views/site/index.html.erb index 0c7b53203..4c954e6cb 100644 --- a/app/views/site/index.html.erb +++ b/app/views/site/index.html.erb @@ -4,6 +4,12 @@ <% end %> <% end %> +<% unless STATUS == :api_offline or STATUS == :database_offline -%> + <% content_for :editmenu do -%> +
  • <%= link_to_function(t('browse.start_rjs.data_layer_name'), 'showData()') %>
  • + <% end -%> +<% end -%> + <%= render :partial => 'sidebar', :locals => { :onopen => "resizeMap();", :onclose => "resizeMap();" } %> <%= render :partial => 'key' %> <%= render :partial => 'search' %>