suivi des suppressions d'objets par ville
This commit is contained in:
parent
62e086cd64
commit
8e43908cef
13 changed files with 1185 additions and 2 deletions
66
templates/public/atom/city_creations.xml.twig
Normal file
66
templates/public/atom/city_creations.xml.twig
Normal file
|
|
@ -0,0 +1,66 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom">
|
||||
<title>Créations d'objets OSM - {{ stats.name }}</title>
|
||||
<link href="https://{{ base_url }}{{ path('app_public_atom_city_creations', {'insee_code': stats.zone}) }}" rel="self" />
|
||||
<link href="https://{{ base_url }}{{ path('app_admin_stats', {'insee_code': stats.zone}) }}" />
|
||||
<id>https://{{ base_url }}/atom/city/{{ stats.zone }}/creations</id>
|
||||
<updated>{{ "now"|date("Y-m-d\\TH:i:s\\Z") }}</updated>
|
||||
<author>
|
||||
<name>OSM Commerces</name>
|
||||
</author>
|
||||
<subtitle>Flux Atom des créations/modifications récentes d'objets OSM pour {{ stats.name }} ({{ stats.zone }})</subtitle>
|
||||
|
||||
{% for date, themes in creationsByDate %}
|
||||
{% for theme, objects in themes %}
|
||||
{% set themeLabel = followup_labels[theme]|default(theme|capitalize) %}
|
||||
{% for obj in objects %}
|
||||
<entry>
|
||||
<title>Création/Modification : {{ themeLabel }} - {{ obj.type|upper }} {{ obj.id }}</title>
|
||||
<link href="https://www.openstreetmap.org/{{ obj.type }}/{{ obj.id }}" />
|
||||
<id>https://{{ base_url }}/atom/city/{{ stats.zone }}/creations/{{ date }}/{{ theme }}/{{ obj.type }}/{{ obj.id }}</id>
|
||||
<updated>{% if obj.timestamp %}{{ obj.timestamp|replace({' ': 'T'}) }}Z{% else %}{{ "now"|date("Y-m-d\\TH:i:s\\Z") }}{% endif %}</updated>
|
||||
<summary type="html">
|
||||
<![CDATA[
|
||||
<p><strong>Thème:</strong> {{ themeLabel }}</p>
|
||||
<p><strong>Type:</strong> {{ obj.type|upper }}</p>
|
||||
<p><strong>ID OSM:</strong> {{ obj.id }}</p>
|
||||
{% if obj.user %}
|
||||
<p><strong>Contributeur:</strong> {{ obj.user }}</p>
|
||||
{% endif %}
|
||||
{% if obj.timestamp %}
|
||||
<p><strong>Date de modification:</strong> {{ obj.timestamp }}</p>
|
||||
{% endif %}
|
||||
{% if obj.changeset %}
|
||||
<p><strong>Changeset:</strong> <a href="https://overpass-api.de/achavi/?changeset={{ obj.changeset }}">{{ obj.changeset }}</a></p>
|
||||
{% endif %}
|
||||
]]>
|
||||
</summary>
|
||||
<content type="html">
|
||||
<![CDATA[
|
||||
<p><strong>Thème:</strong> {{ themeLabel }}</p>
|
||||
<p><strong>Type:</strong> {{ obj.type|upper }}</p>
|
||||
<p><strong>ID OSM:</strong> <a href="https://www.openstreetmap.org/{{ obj.type }}/{{ obj.id }}">{{ obj.id }}</a></p>
|
||||
{% if obj.user %}
|
||||
<p><strong>Contributeur:</strong> <a href="https://www.openstreetmap.org/user/{{ obj.user|url_encode }}">{{ obj.user }}</a></p>
|
||||
{% endif %}
|
||||
{% if obj.timestamp %}
|
||||
<p><strong>Date de modification:</strong> {{ obj.timestamp }}</p>
|
||||
{% endif %}
|
||||
{% if obj.changeset %}
|
||||
<p><strong>Changeset:</strong> <a href="https://overpass-api.de/achavi/?changeset={{ obj.changeset }}">{{ obj.changeset }}</a></p>
|
||||
{% endif %}
|
||||
<p>
|
||||
<a href="https://osmlab.github.io/osm-deep-history/#/{{ obj.type }}/{{ obj.id }}">Historique OSM Deep History</a> |
|
||||
{% if obj.changeset %}
|
||||
<a href="https://overpass-api.de/achavi/?changeset={{ obj.changeset }}">Voir dans achavi</a> |
|
||||
{% endif %}
|
||||
<a href="https://www.openstreetmap.org/{{ obj.type }}/{{ obj.id }}">Voir sur OSM</a>
|
||||
</p>
|
||||
]]>
|
||||
</content>
|
||||
</entry>
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
</feed>
|
||||
|
||||
68
templates/public/atom/city_deletions.xml.twig
Normal file
68
templates/public/atom/city_deletions.xml.twig
Normal file
|
|
@ -0,0 +1,68 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<feed xmlns="http://www.w3.org/2005/Atom">
|
||||
<title>Suppressions d'objets OSM - {{ stats.name }}</title>
|
||||
<link href="https://{{ base_url }}{{ path('app_public_atom_city_deletions', {'insee_code': stats.zone}) }}" rel="self" />
|
||||
<link href="https://{{ base_url }}{{ path('app_admin_stats', {'insee_code': stats.zone}) }}" />
|
||||
<id>https://{{ base_url }}/atom/city/{{ stats.zone }}/deletions</id>
|
||||
<updated>{{ "now"|date("Y-m-d\\TH:i:s\\Z") }}</updated>
|
||||
<author>
|
||||
<name>OSM Commerces</name>
|
||||
</author>
|
||||
<subtitle>Flux Atom des suppressions d'objets OSM pour {{ stats.name }} ({{ stats.zone }})</subtitle>
|
||||
|
||||
{% for date, themes in deletionsByDate %}
|
||||
{% for theme, objects in themes %}
|
||||
{% set themeLabel = followup_labels[theme]|default(theme|capitalize) %}
|
||||
{% for obj in objects %}
|
||||
<entry>
|
||||
<title>Suppression : {{ themeLabel }} - {{ obj.type|upper }} {{ obj.id }}</title>
|
||||
<link href="https://osmlab.github.io/osm-deep-history/#/{{ obj.type }}/{{ obj.id }}" />
|
||||
<id>https://{{ base_url }}/atom/city/{{ stats.zone }}/deletions/{{ date }}/{{ theme }}/{{ obj.type }}/{{ obj.id }}</id>
|
||||
<updated>{% if obj.noticed_deleted_date %}{{ obj.noticed_deleted_date|replace({' ': 'T', '/': '-'}) }}Z{% else %}{{ "now"|date("Y-m-d\\TH:i:s\\Z") }}{% endif %}</updated>
|
||||
<summary type="html">
|
||||
<![CDATA[
|
||||
<p><strong>Thème:</strong> {{ themeLabel }}</p>
|
||||
<p><strong>Type:</strong> {{ obj.type|upper }}</p>
|
||||
<p><strong>ID OSM:</strong> {{ obj.id }}</p>
|
||||
{% if obj.user %}
|
||||
<p><strong>Dernier contributeur:</strong> {{ obj.user }}</p>
|
||||
{% endif %}
|
||||
{% if obj.timestamp %}
|
||||
<p><strong>Dernière modification:</strong> {{ obj.timestamp }}</p>
|
||||
{% endif %}
|
||||
{% if obj.changeset %}
|
||||
<p><strong>Changeset:</strong> <a href="https://overpass-api.de/achavi/?changeset={{ obj.changeset }}">{{ obj.changeset }}</a></p>
|
||||
{% endif %}
|
||||
<p><strong>Date de suppression détectée:</strong> {{ obj.noticed_deleted_date }}</p>
|
||||
]]>
|
||||
</summary>
|
||||
<content type="html">
|
||||
<![CDATA[
|
||||
<p><strong>Thème:</strong> {{ themeLabel }}</p>
|
||||
<p><strong>Type:</strong> {{ obj.type|upper }}</p>
|
||||
<p><strong>ID OSM:</strong> <a href="https://www.openstreetmap.org/{{ obj.type }}/{{ obj.id }}">{{ obj.id }}</a></p>
|
||||
{% if obj.user %}
|
||||
<p><strong>Dernier contributeur:</strong> <a href="https://www.openstreetmap.org/user/{{ obj.user|url_encode }}">{{ obj.user }}</a></p>
|
||||
{% endif %}
|
||||
{% if obj.timestamp %}
|
||||
<p><strong>Dernière modification:</strong> {{ obj.timestamp }}</p>
|
||||
{% endif %}
|
||||
{% if obj.changeset %}
|
||||
<p><strong>Changeset:</strong> <a href="https://overpass-api.de/achavi/?changeset={{ obj.changeset }}">{{ obj.changeset }}</a></p>
|
||||
{% endif %}
|
||||
<p><strong>Date de suppression détectée:</strong> {{ obj.noticed_deleted_date }}</p>
|
||||
<p>
|
||||
<a href="https://osmlab.github.io/osm-deep-history/#/{{ obj.type }}/{{ obj.id }}">Historique OSM Deep History</a> |
|
||||
{% if obj.changeset %}
|
||||
<a href="https://overpass-api.de/achavi/?changeset={{ obj.changeset }}">Voir dans achavi</a> |
|
||||
{% endif %}
|
||||
<a href="https://www.openstreetmap.org/{{ obj.type }}/{{ obj.id }}">Voir sur OSM</a>
|
||||
</p>
|
||||
]]>
|
||||
</content>
|
||||
</entry>
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
</feed>
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue