Finetune hydrant questions

This commit is contained in:
Midgard 2021-04-03 17:14:23 +02:00
parent ed56c1b1e1
commit 8bdd2b2151
Signed by untrusted user who does not match committer: midgard
GPG key ID: 511C112F1331BBB4

View file

@ -21,8 +21,8 @@
"title": {
"render": {
"nl": "Hydrant {ref}",
"en": "Hydrant {ref}"
"nl": "Hydrant",
"en": "Hydrant"
},
"mappings": [
@ -30,57 +30,43 @@
"disused:emergency=fire_hydrant",
"abandoned:emergency=fire_hydrant"
]}, "then": {
"nl": "Onbruikbare hydrant {ref}",
"en": "Unusable hydrant {ref}"
"nl": "Onbruikbare hydrant",
"en": "Unusable hydrant"
}},
{"if": {"or": [ "removed:emergency=fire_hydrant" ]}, "then": {
"nl": "Verwijderde hydrant {ref}",
"en": "Removed hydrant {ref}"
{"if": {"and": ["removed:emergency=fire_hydrant", "has_marker=yes"]}, "then": {
"nl": "Bordje bij verwijderde hydrant",
"en": "Marker for removed hydrant"
}},
{"if": "removed:emergency=fire_hydrant", "then": {
"nl": "Verwijderde hydrant",
"en": "Removed hydrant"
}},
{"if": "has_marker=no", "then": {
"nl": "Hydrant zonder bordje",
"en": "Hydrant without marker"
}},
{"if": "ref~*", "then": {
"nl": "Hydrant {ref}",
"en": "Hydrant {ref}"
}}
]
},
"tagRenderings": [
{
"question": {
"nl": "Wat is de meest opvallende kleur van de hydrant?",
"en": "What is the most prominent colour of the hydrant?"
},
"render": {
"nl": "Kleur (in het Engels): {colour}",
"en": "Colour: {colour}"
},
"condition": { "and": [
"fire_hydrant:type!=underground",
"fire_hydrant:type!=pipe"
] },
"freeform": { "key": "colour" },
"mappings": [
{"if": {"and": ["colour=red"]}, "then": {
"nl": "De hydrant is rood",
"en": "The hydrant is red"
}},
{"if": {"and": ["colour=yellow"]}, "then": {
"nl": "De hydrant is geel",
"en": "The hydrant is yellow"
}},
{"if": {"and": ["colour=grey"]}, "then": {
"nl": "De hydrant is grijs",
"en": "The hydrant is grey"
}}
]
},
{
"question": {
"nl": "Welk soort hydrant is het?",
"en": "What type of hydrant is it?"
},
"condition": {"or": [
"removed:emergency!=fire_hydrant",
"fire_hydrant:type~*"
]},
"mappings": [
{"if": {"and": ["fire_hydrant:type=underground"]}, "then": {
@ -111,6 +97,40 @@
]
},
{
"question": {
"nl": "Wat is de meest opvallende kleur van de hydrant?",
"en": "What is the most prominent colour of the hydrant?"
},
"render": {
"nl": "Kleur (in het Engels): {colour}",
"en": "Colour: {colour}"
},
"condition": { "and": [
"removed:emergency!=fire_hydrant",
"fire_hydrant:type!=underground",
"fire_hydrant:type!=pipe"
] },
"freeform": { "key": "colour" },
"mappings": [
{"if": {"and": ["colour=red"]}, "then": {
"nl": "De hydrant is rood",
"en": "The hydrant is red"
}},
{"if": {"and": ["colour=yellow"]}, "then": {
"nl": "De hydrant is geel",
"en": "The hydrant is yellow"
}},
{"if": {"and": ["colour=grey"]}, "then": {
"nl": "De hydrant is grijs",
"en": "The hydrant is grey"
}}
]
},
{
"question": {
"nl": "Wat is de nominale diameter van de aanvoerleiding in millimeter?",
@ -125,29 +145,16 @@
"type": "pnat"
},
"mappings": [
{
"if": { "and": [ "fire_hydrant:diameter~^[0-9.]+$" ] }, "then": {
"nl": "Nominale diameter van aanvoerleiding: {fire_hydrant:diameter} mm",
"en": "Nominal diameter of supply: {fire_hydrant:diameter} mm"
}
}
]
},
{
"question": {
"nl": "Hoeveel aansluitingen zijn er?",
"en": "How many couplings are there?"
},
"render": {
"nl": "Aantal aansluitingen: {couplings}",
"en": "Amount of couplings: {couplings}"
},
"freeform": {
"key": "couplings",
"type": "pnat"
},
"condition": {"or": ["fire_hydrant:type=pillar", "fire_hydrant:type=wall", "couplings~[0-9]+"]}
{ "if": { "and": [ "fire_hydrant:diameter~^[0-9.]+$" ] }, "then": {
"nl": "Nominale diameter van aanvoerleiding: {fire_hydrant:diameter} mm",
"en": "Nominal diameter of supply: {fire_hydrant:diameter} mm"
}, "hideInAnswer": true }
],
"condition": {"or": [
"removed:emergency!=fire_hydrant",
"has_marker=yes",
"fire_hydrant:diameter~*"
]}
},
{
@ -174,16 +181,33 @@
]
},
{
"question": {
"nl": "Hoeveel aansluitingen zijn er?",
"en": "How many couplings are there?"
},
"render": {
"nl": "Aantal aansluitingen: {couplings}",
"en": "Amount of couplings: {couplings}"
},
"freeform": {
"key": "couplings",
"type": "pnat"
},
"condition": {"or": [
{"and": [
{"or": ["fire_hydrant:type=pillar", "fire_hydrant:type=wall"]},
"removed:emergency!=fire_hydrant"
]},
"couplings~^[0-9]+$"
]}
},
{
"question": {
"nl": "Update de status van de hydrant.",
"en": "Update the status of the hydrant."
},
"render": {
"nl": "Status",
"en": "Status"
},
"freeform": { "key": "disused:emergency" },
"mappings": [
{ "if": { "and": [
"emergency=fire_hydrant",
@ -225,6 +249,7 @@
"nl": "Is er een bordje aanwezig?",
"en": "Is there a marker for the hydrant?"
},
"condition": {"and": ["emergency=fire_hydrant"]},
"mappings": [
{"if": {"and": ["has_marker=no"]}, "then": {
"nl": "Een bordje ontbreekt!",
@ -238,8 +263,7 @@
"nl": "Er is een bordje voor de hydrant.",
"en": "A marker is present."
}, "hideInAnswer": true }
],
"condition": {"and": ["emergency=fire_hydrant"]}
]
},
{
"#": "Marker for disused hydrant",
@ -247,6 +271,7 @@
"nl": "Is er een bordje aanwezig?",
"en": "Is there a marker for the hydrant?"
},
"condition": {"or": ["disused:emergency=fire_hydrant", "abandoned:emergency=fire_hydrant"]},
"mappings": [
{"if": {"and": ["has_marker=no"]}, "then": {
"nl": "Een bordje ontbreekt.",
@ -256,8 +281,7 @@
"nl": "Er is een bordje voor de hydrant.",
"en": "A marker is present."
}}
],
"condition": {"or": ["disused:emergency=fire_hydrant", "abandoned:emergency=fire_hydrant"]}
]
},
{
"#": "Marker for removed hydrant",
@ -265,6 +289,7 @@
"nl": "Is er nog (ten onrechte) een bordje voor de verwijderde hydrant?",
"en": "Is there a (now incorrect) marker left for the removed hydrant?"
},
"condition": {"and": ["removed:emergency=fire_hydrant"]},
"mappings": [
{"if": {"and": ["has_marker=yes"]}, "then": {
"nl": "Er is ten onrechte een bordje!",
@ -274,8 +299,7 @@
"nl": "Het bordje is weggehaald.",
"en": "The marker is removed too."
}}
],
"condition": {"and": ["removed:emergency=fire_hydrant"]}
]
},
{
@ -287,6 +311,8 @@
"nl": "Omgeving: {fire_hydrant:position}",
"en": "Position: {fire_hydrant:position}"
},
"freeform": {"key": "fire_hydrant:position:description"},
"condition": {"and": ["removed:emergency!=fire_hydrant"]},
"mappings": [
{"if": {"and": ["fire_hydrant:position=lane"]}, "then": {
"nl": "In of naast de rijbaan",
@ -306,10 +332,13 @@
{"if": {"and": ["fire_hydrant:position=green"]}, "then": {
"nl": "In het gras",
"en": "In a grassy area"
}},
{"if": {"and": ["fire_hydrant:position="]}, "then": {
"nl": "Anders / Onbekend",
"en": "Other / Unknown"
}}
],
"freeform": {"key": "fire_hydrant:position"},
"condition": {"and": ["removed:emergency!=fire_hydrant"]}
]
},
{
@ -340,6 +369,11 @@
"has_marker=yes"
] }, "then": "./assets/layers/fire_hydrants/hydrant_marker_only.svg" },
{ "if": { "and": [
"emergency=fire_hydrant",
"has_marker=no"
] }, "then": "./assets/layers/fire_hydrants/hydrant_attention.svg" },
{ "if": { "and": [
"emergency=fire_hydrant",
"fire_hydrant:type=underground"