feat: add map to search
This commit is contained in:
parent
2dbd908f4c
commit
3881a4f3b4
@ -746,6 +746,10 @@ div.announcement {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.half {
|
||||||
|
width: 49%;
|
||||||
|
}
|
||||||
|
|
||||||
/************************/
|
/************************/
|
||||||
/* GENERAL HIGHLIGHTING */
|
/* GENERAL HIGHLIGHTING */
|
||||||
/************************/
|
/************************/
|
||||||
|
@ -4,7 +4,8 @@
|
|||||||
{% block title %}<title>{% translate "Suche" %}</title>{% endblock %}
|
{% block title %}<title>{% translate "Suche" %}</title>{% endblock %}
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
<form class="form-search card" method="post">
|
<div class="container-cards">
|
||||||
|
<form class="form-search card half" method="post">
|
||||||
{% csrf_token %}
|
{% csrf_token %}
|
||||||
<input type="hidden" name="longitude" maxlength="200" id="longitude">
|
<input type="hidden" name="longitude" maxlength="200" id="longitude">
|
||||||
<input type="hidden" name="latitude" maxlength="200" id="latitude">
|
<input type="hidden" name="latitude" maxlength="200" id="latitude">
|
||||||
@ -24,6 +25,10 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</form>
|
</form>
|
||||||
|
<div class="card half">
|
||||||
|
{% include "fellchensammlung/partials/partial-map.html" %}
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
{% if place_not_found %}
|
{% if place_not_found %}
|
||||||
<p class="error">{% translate "Ort nicht gefunden" %}</p>
|
<p class="error">{% translate "Ort nicht gefunden" %}</p>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
@ -199,7 +199,8 @@ def search(request):
|
|||||||
"search_form": search.search_form,
|
"search_form": search.search_form,
|
||||||
"place_not_found": search.place_not_found,
|
"place_not_found": search.place_not_found,
|
||||||
"subscribed_search": subscribed_search,
|
"subscribed_search": subscribed_search,
|
||||||
"searched": searched}
|
"searched": searched,
|
||||||
|
"adoption_notices_map": AdoptionNotice.get_active_ANs()}
|
||||||
return render(request, 'fellchensammlung/search.html', context=context)
|
return render(request, 'fellchensammlung/search.html', context=context)
|
||||||
|
|
||||||
|
|
||||||
@ -518,7 +519,7 @@ def updatequeue(request):
|
|||||||
|
|
||||||
|
|
||||||
def map(request):
|
def map(request):
|
||||||
adoption_notices = AdoptionNotice.objects.all() #TODO: Filter to active
|
adoption_notices = AdoptionNotice.get_active_ANs()
|
||||||
context = {"adoption_notices_map": adoption_notices}
|
context = {"adoption_notices_map": adoption_notices}
|
||||||
return render(request, 'fellchensammlung/map.html', context=context)
|
return render(request, 'fellchensammlung/map.html', context=context)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user