From 9ef5a06731ceb9e6b9ee37e7e2f88f22d72ab746 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20B=C3=B6sch-Plepelits?= Date: Thu, 29 Nov 2018 18:44:31 +0100 Subject: [PATCH] public: include office=government and office=administration --- public.json | 40 ++++++++++++++++++++++++++++------------ 1 file changed, 28 insertions(+), 12 deletions(-) diff --git a/public.json b/public.json index cf28f62..63061c0 100644 --- a/public.json +++ b/public.json @@ -27,6 +27,7 @@ "node[amenity=recycling][recyling_type=centre];", "way[amenity=recycling][recyling_type=centre];", "relation[amenity=recycling][recyling_type=centre];", + "nwr[office~\"^(government|administration)$\"];", ");" ], "16": [ @@ -35,23 +36,36 @@ "way[amenity~'^(courthouse|embassy|public_building|townhall|recycling|toilets)$'];", "relation[amenity~'^(courthouse|embassy|public_building|townhall|recycling|toilets)$'];", "node[drinking_water];", + "nwr[office~\"^(government|administration)$\"];", ");" ] }, "feature": { "pre": [ "{% if tags.drinking_water %}", + "{% set key = 'amenity' %}", "{% set value = 'drinking_water' %}", - "{% else %}", + "{% elseif tags.amenity %}", + "{% set key = 'amenity' %}", "{% set value = tags.amenity %}", + "{% elseif tags.office %}", + "{% set key = 'office' %}", + "{% set value = tags.office %}", "{% endif %}" ], "title": "{{ tags.name|default(tags.operator)|default(tagTrans('amenity', value)) }}", - "description": "{{ tagTrans('amenity', value) }}", + "description": [ + "{% if key == 'office' %}", + " {{ keyTrans('office') }} ({{ tagTrans('office', tags.office) }})", + "{% else %}", + " {{ tagTrans(key, value) }}", + "{% endif %}" + ], "body": "{% if tags.operator %}{{ keyTrans('operator') }}: {{ tags.operator }}
{% endif %}", "markerSign": [ - "{% if const[value] %}", - "{{ const[value]|raw }}", + "{% set kv = key ~ '=' ~ value %}", + "{% if const[kv] %}", + "{{ const[kv]|raw }}", "{% endif %}" ] }, @@ -66,13 +80,15 @@ "" ], "const": { - "courthouse": "⚖", - "clock": "", - "drinking_water": "", - "embassy": "", - "public_building": "", - "recycling": "", - "toilets": "", - "townhall": "" + "amenity=courthouse": "⚖", + "amenity=clock": "", + "amenity=drinking_water": "", + "amenity=embassy": "", + "amenity=public_building": "", + "amenity=recycling": "", + "amenity=toilets": "", + "amenity=townhall": "", + "office=administration": "", + "office=government": "" } }