From: John Firebaugh Date: Sun, 26 Aug 2012 02:27:10 +0000 (-0700) Subject: Extract browse.js static asset X-Git-Tag: live~6086 X-Git-Url: https://git.openstreetmap.org./rails.git/commitdiff_plain/17b23b075642d6bf2ba66a0448a7a7acfd2824b6 Extract browse.js static asset --- diff --git a/app/views/browse/start.js.erb b/app/assets/javascripts/browse.js similarity index 99% rename from app/views/browse/start.js.erb rename to app/assets/javascripts/browse.js index 6478794da..fef09aada 100644 --- a/app/views/browse/start.js.erb +++ b/app/assets/javascripts/browse.js @@ -542,5 +542,3 @@ function clearStatus() { $("#browse_status").html(""); $("#browse_status").hide(); } - -startBrowse("<%=j render :partial => "sidebar" %>"); diff --git a/app/assets/javascripts/site.js b/app/assets/javascripts/site.js index 978e84e3d..df56b95bc 100644 --- a/app/assets/javascripts/site.js +++ b/app/assets/javascripts/site.js @@ -2,8 +2,10 @@ //= require jquery_ujs //= require jquery.autogrowtextarea //= require jquery.timers +//= require openlayers //= require i18n/translations //= require globals +//= require browse //= require export /* diff --git a/app/controllers/browse_controller.rb b/app/controllers/browse_controller.rb index 2a7e2c5f7..e3f20c803 100644 --- a/app/controllers/browse_controller.rb +++ b/app/controllers/browse_controller.rb @@ -7,6 +7,7 @@ class BrowseController < ApplicationController around_filter :web_timeout, :except => [:start] def start + render :partial => "sidebar" end def relation diff --git a/app/views/browse/_map.html.erb b/app/views/browse/_map.html.erb index b8077e682..340e26132 100644 --- a/app/views/browse/_map.html.erb +++ b/app/views/browse/_map.html.erb @@ -1,4 +1,3 @@ -<%= javascript_include_tag 'openlayers.js' %> <%= javascript_include_tag 'map.js' %>