From 6b21617d2748017ead7ca7171b84cd7a613273cb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20B=C3=B6sch-Plepelits?= Date: Sun, 20 Jan 2019 22:32:19 +0100 Subject: [PATCH] More filters --- culture.json | 11 ++++++++++- emergency.json | 28 ++++++++++++++++++++++++++++ historic.json | 45 +++++++++++++++++++++++++++++++++++++++++++++ memorial.json | 36 ++++++++++++++++++++++++++++++++++++ 4 files changed, 119 insertions(+), 1 deletion(-) diff --git a/culture.json b/culture.json index 630f375..219651a 100644 --- a/culture.json +++ b/culture.json @@ -121,5 +121,14 @@ " ", "{% endfor %}", "" - ] + ], + "filter": { + "type": { + "name": "Type", + "query": "nwr[{{ value }}]", + "type": "select", + "values": "const", + "valueName": "{{ trans('tag' ~ value) }}" + } + } } diff --git a/emergency.json b/emergency.json index 73b606d..c739352 100644 --- a/emergency.json +++ b/emergency.json @@ -96,5 +96,33 @@ "sign": "", "background": "#009262" } + }, + "filter": { + "type": { + "name": "{{ keyTrans('amenity') }}", + "type": "select", + "values": { + "fire_station": { + "name": "{{ tagTrans('amenity', 'fire_station') }}", + "query": "nwr[amenity=fire_station]" + }, + "hospital": { + "name": "{{ tagTrans('amenity', 'hospital') }}", + "query": "nwr[amenity=hospital]" + }, + "police": { + "name": "{{ tagTrans('amenity', 'police') }}", + "query": "nwr[amenity=police]" + }, + "emergency_phone": { + "name": "{{ tagTrans('emergency', 'phone') }}", + "query": "node[emergency=phone]" + }, + "emergency_access_point": { + "name": "{{ tagTrans('highway', 'emergency_access_point') }}", + "query": "node[highway=emergency_access_point]" + } + } + } } } diff --git a/historic.json b/historic.json index 0042fc1..067b740 100644 --- a/historic.json +++ b/historic.json @@ -113,5 +113,50 @@ "sign": "", "zoom": 14 } + }, + "filter": { + "type": { + "key": "historic", + "name": "Type", + "type": "select", + "values": "const", + "valueName": "{{ tagTrans('historic', value) }}" + }, + "conflict": { + "key": "memorial:conflict", + "op": "has", + "name": "{{ keyTrans('memorial:conflict') }}", + "type": "select", + "values": [ + "WW1", + "WW2" + ], + "valueName": "{{ tagTrans('memorial:conflict', value) }}" + }, + "civilization": { + "key": "historic:civilization", + "op": "has", + "name": "{{ keyTrans('historic:civilization') }}", + "type": "select", + "values": [ + "ancient_egyptian", + "ancient_greek", + "ancient_roman", + "byzantine", + "celtic", + "etruscan", + "imperial_chinese", + "korean", + "medieval", + "modern", + "neolithic", + "nuragic", + "ottoman", + "prehistoric", + "roman", + "western_roman" + ], + "valueName": "{{ tagTrans('historic:civilization', value) }}" + } } } diff --git a/memorial.json b/memorial.json index 0580731..c2c4908 100644 --- a/memorial.json +++ b/memorial.json @@ -125,6 +125,42 @@ "query": "(nwr[memorial=stolperstein];nwr[\"memorial:type\"=stolperstein];)" } } + }, + "conflict": { + "key": "memorial:conflict", + "op": "has", + "name": "{{ keyTrans('memorial:conflict') }}", + "type": "select", + "values": [ + "WW1", + "WW2" + ], + "valueName": "{{ tagTrans('memorial:conflict', value) }}" + }, + "civilization": { + "key": "historic:civilization", + "op": "has", + "name": "{{ keyTrans('historic:civilization') }}", + "type": "select", + "values": [ + "ancient_egyptian", + "ancient_greek", + "ancient_roman", + "byzantine", + "celtic", + "etruscan", + "imperial_chinese", + "korean", + "medieval", + "modern", + "neolithic", + "nuragic", + "ottoman", + "prehistoric", + "roman", + "western_roman" + ], + "valueName": "{{ tagTrans('historic:civilization', value) }}" } } }