Source

django-leaflet-storage / leaflet_storage / templates / leaflet_storage / map_init.html

    <div id="map"></div>
    <script type="text/javascript">
        {% if locale %}
            L.S.setLocale("{{ locale }}");
        {% endif %}
        map_settings = {
            "storage_id": {{ map.pk }},
            "center": {{ map.center.geojson|safe }},
            "categories": {{ categories|safe }},
            "urls": {{ urls|safe }},
            "default_icon_url": "{{ STATIC_URL }}storage/src/img/marker.png",
            "zoom": {{ map.zoom }},
            "tilelayers": {{ tilelayers|safe }},
            "allowEdit": {{ allowEdit }},
            "embedControl": {{ embedControl }},
            "homeControl": {{ homeControl }},
            "locateControl": {{ locateControl }},
            "jumpToLocationControl": {{ jumpToLocationControl }},
            "enableMarkerDraw": {{ enableMarkerDraw }},
            "enablePolylineDraw": {{ enablePolylineDraw }},
            "enablePolygonDraw": {{ enablePolygonDraw }}
        }
        {% if locateOnLoad %}
            map_settings['locate'] = {"setView": true}
        {% endif %}
        var MAP = new L.Storage.Map("map", map_settings);
    </script>
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.