AgileVentures/LocalSupport

View on GitHub
app/views/shared/_map_scripts.html.erb

Summary

Maintainability
Test Coverage
<% content_for :scripts do %>
  <script src="https://maps.google.com/maps/api/js?v=3&amp;libraries=geometry<%= gmap_key_value_for_url %>" type="text/javascript"></script>
  <%= javascript_include_tag 'maps' %>
<% end %>

<% content_for :map do %>
    <%= content_tag "div", "", 
      id: "marker_data", 
      data: {
        zoom: @map_zoom_level,
        latitude: Setting.latitude, 
        longitude: Setting.longitude,
        geojson_url1: Setting.geojson_url1,
        geojson_url2: Setting.geojson_url2,
        pcn_overlay: @pcn_overlay,
        markers: markers
      }  %>
<% end %>