]> git.openstreetmap.org Git - chef.git/commitdiff
imagery: just add basic permalink support for now
authorGrant Slater <grant.slater@wearefriday.com>
Fri, 17 Jun 2016 16:59:16 +0000 (17:59 +0100)
committerGrant Slater <grant.slater@wearefriday.com>
Fri, 17 Jun 2016 16:59:16 +0000 (17:59 +0100)
cookbooks/imagery/templates/default/imagery.js.erb
cookbooks/imagery/templates/default/index.html.erb

index a728ef60e2ca6fb6833cb63def759725b6656c9d..f992ef08df07c73e7de6ec7d66f4c154a7af70d9 100644 (file)
@@ -33,6 +33,6 @@ function createMap(divName) {
 
   // Add the layer switch to the mao
   layers.addTo(map);
 
   // Add the layer switch to the mao
   layers.addTo(map);
-
+  map.addControl(new L.Control.Permalink());
   return map;
 }
   return map;
 }
index 74b7d53d0192f3975f2f4d96d5f085bf527e696c..a53b27fadcbe99059eafeb71a054a90b4aec5d27 100644 (file)
@@ -9,6 +9,9 @@
     <link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.ie.css" />
     <![endif]-->
     <script type="text/javascript" src="http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.js"></script>
     <link rel="stylesheet" href="http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.ie.css" />
     <![endif]-->
     <script type="text/javascript" src="http://cdn.leafletjs.com/leaflet/v0.7.7/leaflet.js"></script>
+    <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/leaflet-plugins/1.6.1/control/Permalink.min.js"></script>
+    <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/leaflet-plugins/1.6.1/control/Permalink.Layer.min.js"></script>
+    <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/leaflet-plugins/1.6.1/control/Permalink.Overlay.js"></script>
     <script type="text/javascript" src="imagery.js"></script>
     <style type="text/css">
     @media print {
     <script type="text/javascript" src="imagery.js"></script>
     <style type="text/css">
     @media print {