add themes in main city page
This commit is contained in:
parent
952254b5d0
commit
03fede15aa
5 changed files with 91 additions and 18 deletions
|
|
@ -282,14 +282,7 @@
|
|||
'healthcare': 'nwr["healthcare"](area.searchArea);nwr["amenity"="doctors"](area.searchArea);nwr["amenity"="pharmacy"](area.searchArea);nwr["amenity"="hospital"](area.searchArea);nwr["amenity"="clinic"](area.searchArea);nwr["amenity"="social_facility"](area.searchArea);'
|
||||
} %}
|
||||
|
||||
{% set theme_groups = {
|
||||
'emergency': ['fire_hydrant', 'defibrillator'],
|
||||
'transport': ['bus_stop', 'charging_station', 'bicycle_parking'],
|
||||
'healthcare': ['healthcare', 'laboratory', 'drinking_water'],
|
||||
'education': ['school'],
|
||||
'security': ['police', 'camera'],
|
||||
'infrastructure': ['toilets', 'recycling', 'substation']
|
||||
} %}
|
||||
{# theme_groups est maintenant passé depuis le contrôleur pour inclure tous les thèmes #}
|
||||
|
||||
<div class="row mb-4" id="themes">
|
||||
<div class="col-12">
|
||||
|
|
@ -346,14 +339,39 @@
|
|||
<tr>
|
||||
<td class="text-muted">
|
||||
{% if loop.first %}
|
||||
{% set group_display_names = {
|
||||
'batiments': '🏢 Bâtiments',
|
||||
'commerces': '🏪 Commerces',
|
||||
'divers': '📦 Divers',
|
||||
'education': '🎓 Éducation',
|
||||
'emergency': '🚨 Urgence',
|
||||
'healthcare': '🏥 Santé',
|
||||
'infrastructure': '🏗️ Infrastructure',
|
||||
'loisirs': '🎮 Loisirs',
|
||||
'mobilier_urbain': '🪑 Mobilier urbain',
|
||||
'security': '🛡️ Sécurité',
|
||||
'transport': '🚌 Transport'
|
||||
} %}
|
||||
{% set sorted_group_names = group_display_names|keys|sort %}
|
||||
{% set sorted_group_display_names = {} %}
|
||||
{% for g in sorted_group_names %}
|
||||
{% set sorted_group_display_names = sorted_group_display_names|merge({ (g): group_display_names[g] }) %}
|
||||
|
||||
|
||||
{% endfor %}
|
||||
{% if group_name == 'emergency' %}🚨 Urgence
|
||||
{% elseif group_name == 'transport' %}🚌 Transport
|
||||
{% elseif group_name == 'healthcare' %}🏥 Santé
|
||||
{% elseif group_name == 'education' %}🎓 Éducation
|
||||
{% elseif group_name == 'security' %}🛡️ Sécurité
|
||||
{% elseif group_name == 'infrastructure' %}🏗️ Infrastructure
|
||||
{% else %}{{ group_name|capitalize }}
|
||||
{% endif %}
|
||||
{% elseif group_name == 'transport' %}🚌 Transport
|
||||
{% elseif group_name == 'healthcare' %}🏥 Santé
|
||||
{% elseif group_name == 'education' %}🎓 Éducation
|
||||
{% elseif group_name == 'security' %}🛡️ Sécurité
|
||||
{% elseif group_name == 'infrastructure' %}🏗️ Infrastructure
|
||||
{% elseif group_name == 'mobilier_urbain' %}🪑 Mobilier urbain
|
||||
{% elseif group_name == 'loisirs' %}🎮 Loisirs
|
||||
{% elseif group_name == 'commerces' %}🏪 Commerces
|
||||
{% elseif group_name == 'batiments' %}🏢 Bâtiments
|
||||
{% elseif group_name == 'divers' %}📦 Divers
|
||||
{% else %}{{ group_name|capitalize }}
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</td>
|
||||
<td>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue