From 793d765ead26544cbcb08ca1e04084e775619e37 Mon Sep 17 00:00:00 2001 From: pietervdvn Date: Tue, 22 Feb 2022 16:11:00 +0100 Subject: [PATCH] Add contact information to recycling centers --- Models/Constants.ts | 2 +- assets/layers/direction/direction.json | 2 +- assets/layers/recycling/recycling.json | 49 ++++++++++++++++++++++++-- langs/layers/en.json | 12 +++++++ langs/layers/nl.json | 12 +++++++ 5 files changed, 73 insertions(+), 4 deletions(-) diff --git a/Models/Constants.ts b/Models/Constants.ts index c76a77f17..a8bec17f0 100644 --- a/Models/Constants.ts +++ b/Models/Constants.ts @@ -61,7 +61,7 @@ export default class Constants { * For every bin, the totals are uploaded as metadata */ static distanceToChangeObjectBins = [25, 50, 100, 500, 1000, 5000, Number.MAX_VALUE] - static themeOrder = ["personal", "cyclofix", "hailhydrant", "bookcases", "toilets", "aed"]; + static themeOrder = ["personal", "cyclofix", "waste" , "etymology", "food","cafes_and_pubs", "playgrounds", "hailhydrant", "toilets", "aed", "bookcases"]; private static isRetina(): boolean { if (Utils.runningFromConsole) { diff --git a/assets/layers/direction/direction.json b/assets/layers/direction/direction.json index 4fa7f7ce6..81dc20931 100644 --- a/assets/layers/direction/direction.json +++ b/assets/layers/direction/direction.json @@ -32,7 +32,7 @@ "presets": [], "mapRendering": [ { - "icon": "direction_gradient:var(--catch-detail-color)", + "icon": "direction_gradient:var(--catch-detail-color)", "iconSize": "200,200,center", "location": [ "point", diff --git a/assets/layers/recycling/recycling.json b/assets/layers/recycling/recycling.json index 270620fd6..bab282396 100644 --- a/assets/layers/recycling/recycling.json +++ b/assets/layers/recycling/recycling.json @@ -22,12 +22,20 @@ }, "mappings": [ { - "if": "recycling_type=centre", + "if": "name~*", "then": { + "*": "{name}", "en": "Recycling centre", "nl": "Recyclingcentrum" } }, + { + "if": "recycling_type=centre", + "then": { + "en": "Recycling container", + "nl": "Recyclingcontainer" + } + }, { "if": "recycling_type=container", "then": { @@ -419,6 +427,7 @@ } ], "tagRenderings": [ + "images", { "id": "recycling-type", "question": { @@ -471,6 +480,30 @@ } ] }, + { + "id": "recycling-centre-name", + "question": { + "en": "What is the name of this recycling centre?", + "nl": "Wat is de naam van dit recyclagecentrum?" + }, + "render": { + "en": "This recycling centre is named {name}", + "nl": "Dit recyclagecentrum heet {name}" + }, + "freeform": { + "key": "name" + }, + "mappings": [ + { + "if": "noname=yes", + "then": { + "en": "This recycling centre doesn't have a specific name", + "nl": "Dit recyclagecentrum heeft geen specifieke naam" + } + } + ], + "condition": "recycling_type=centre" + }, { "id": "container-location", "question": { @@ -770,6 +803,16 @@ "type": "string" } }, + { + "builtin": [ + "website", + "email", + "phone" + ], + "override": { + "condition": "recycling_type=centre" + } + }, { "id": "opening_hours", "render": "{opening_hours_table()}", @@ -946,7 +989,9 @@ ] } ], - "deletion": {"neededChangesets": 1}, + "deletion": { + "neededChangesets": 1 + }, "allowMove": { "enableRelocation": false, "enableImproveAccuracy": true diff --git a/langs/layers/en.json b/langs/layers/en.json index 1cbc07a8f..ac5a29326 100644 --- a/langs/layers/en.json +++ b/langs/layers/en.json @@ -4294,6 +4294,15 @@ }, "question": "What can be recycled here?" }, + "recycling-centre-name": { + "mappings": { + "0": { + "then": "This recycling centre doesn't have a specific name" + } + }, + "question": "What is the name of this recycling centre?", + "render": "This recycling centre is named {name}" + }, "recycling-type": { "mappings": { "0": { @@ -4316,6 +4325,9 @@ }, "1": { "then": "Recycling container" + }, + "2": { + "then": "Recycling container" } }, "render": "Recycling facility" diff --git a/langs/layers/nl.json b/langs/layers/nl.json index 48e89d361..58d377dd0 100644 --- a/langs/layers/nl.json +++ b/langs/layers/nl.json @@ -4086,6 +4086,15 @@ }, "question": "Wat kan hier gerecycled worden?" }, + "recycling-centre-name": { + "mappings": { + "0": { + "then": "Dit recyclagecentrum heeft geen specifieke naam" + } + }, + "question": "Wat is de naam van dit recyclagecentrum?", + "render": "Dit recyclagecentrum heet {name}" + }, "recycling-type": { "mappings": { "0": { @@ -4108,6 +4117,9 @@ }, "1": { "then": "Recyclingcontainer" + }, + "2": { + "then": "Recyclingcontainer" } }, "render": "Recyclingfaciliteit"