toodego/villeurbanne: adapt custom map.html template for search (#78115) #298
|
@ -3,16 +3,7 @@
|
||||||
{% block widget-title %}
|
{% block widget-title %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
{% block widget-control %}
|
{% block widget-content %}
|
||||||
<input type="hidden" name="{{widget.name}}$latlng" {% if widget.value %}value="{{widget.value}}"{% endif %}>
|
{# must be repeated here as it's expected to exist when rendering view values #}
|
||||||
<div id="map-{{widget.name}}" class="qommon-map"
|
{{ block.super }}
|
||||||
{% if widget.readonly %}data-readonly="true"{% endif %}
|
|
||||||
{% if widget.sync_map_and_address_fields %}data-address-sync="true"{% endif %}
|
|
||||||
{% for key, value in widget.map_attributes.items %}{{key}}="{{value}}" {% endfor %}
|
|
||||||
{% if widget.initial_position %}
|
|
||||||
data-init-lat="{{ widget.initial_position.lat }}"
|
|
||||||
data-init-lng="{{ widget.initial_position.lng }}"
|
|
||||||
{% endif %}
|
|
||||||
{% block widget-control-attributes %}{% endblock %}
|
|
||||||
></div>
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
|
@ -15,6 +15,7 @@
|
||||||
data-init-lat="{{ widget.initial_position.lat }}"
|
data-init-lat="{{ widget.initial_position.lat }}"
|
||||||
data-init-lng="{{ widget.initial_position.lng }}"
|
data-init-lng="{{ widget.initial_position.lng }}"
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
data-search-url="{% url 'api-geocoding' %}"
|
||||||
{% block widget-control-attributes %}{% endblock %}
|
{% block widget-control-attributes %}{% endblock %}
|
||||||
></div>
|
></div>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
Loading…
Reference in New Issue