reorder functions and rename template
This commit is contained in:
parent
dc24e3f7e7
commit
59611dd077
2 changed files with 59 additions and 60 deletions
40
templates/detail.html
Normal file
40
templates/detail.html
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Geocode to commons</title>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>Geocode coordinates to Commons Category</h1>
|
||||
|
||||
<p><a href="{{ url_for('index', lat=lat, lon=lon) }}">visit endpoint</a>
|
||||
|
||||
| <a href="https://www.openstreetmap.org/#map=17/{{lat }}/{{ lon }}">view in OSM</a>
|
||||
|
||||
{% if result.commons_cat %}
|
||||
| <a href="{{ result.commons_cat.url }}">Commons category</a>
|
||||
{% endif %}
|
||||
|
||||
{% if result.wikidata %}
|
||||
| <a href="https://www.wikidata.org/wiki/{{ result.wikidata }}">{{ result.wikidata }}</a>
|
||||
{% endif %}
|
||||
|
||||
| <a href="{{ url_for('detail_page', lat=lat, lon=lon) }}">#</a>
|
||||
|
||||
</p>
|
||||
|
||||
<pre>{{ result | pprint }}</pre>
|
||||
|
||||
{% if result.commons_cat %}
|
||||
<p>({{ lat }}, {{ lon }}, {{result.commons_cat.title | pprint }}),</p>
|
||||
{% endif %}
|
||||
|
||||
{% for element in elements %}
|
||||
{% set tags = element.tags %}
|
||||
<pre>{{ element | pprint }}</pre>
|
||||
{% endfor %}
|
||||
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Loading…
Add table
Add a link
Reference in a new issue