Skip to content

Commit

Permalink
Social Facility preset improvements
Browse files Browse the repository at this point in the history
(closes #3702)

* Add `social facility` field
* Make sure Social Facility presets have both `social_facility` and `social_facility:for`
* Change `social_facility:for` from radio to combo, because so many choices
  • Loading branch information
bhousel committed Dec 31, 2016
1 parent 9033c9d commit e9dfa04
Show file tree
Hide file tree
Showing 11 changed files with 48 additions and 64 deletions.
7 changes: 4 additions & 3 deletions data/presets.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1062,11 +1062,12 @@ en:
very_horrible: 'Specialized off-road: tractor, ATV'
# smoothness field placeholder
placeholder: 'Thin Rollers, Wheels, Off-Road...'
social_facility:
# social_facility=*
label: Type
social_facility_for:
# 'social_facility:for=*'
label: People served
# social_facility_for field placeholder
placeholder: 'Homeless, Disabled, Child, etc'
label: People Served
source:
# source=*
label: Source
Expand Down
26 changes: 7 additions & 19 deletions data/presets/fields.json
Original file line number Diff line number Diff line change
Expand Up @@ -1409,25 +1409,13 @@
},
"social_facility_for": {
"key": "social_facility:for",
"type": "radio",
"label": "People served",
"placeholder": "Homeless, Disabled, Child, etc",
"options": [
"abused",
"child",
"disabled",
"diseased",
"drug_addicted",
"homeless",
"juvenile",
"mental_health",
"migrant",
"orphan",
"senior",
"underprivileged",
"unemployed",
"victim"
]
"type": "combo",
"label": "People Served"
},
"social_facility": {
"key": "social_facility",
"type": "combo",
"label": "Type"
},
"source": {
"key": "source",
Expand Down
5 changes: 5 additions & 0 deletions data/presets/fields/social_facility.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"key": "social_facility",
"type": "combo",
"label": "Type"
}
24 changes: 3 additions & 21 deletions data/presets/fields/social_facility_for.json
Original file line number Diff line number Diff line change
@@ -1,23 +1,5 @@
{
"key": "social_facility:for",
"type": "radio",
"label": "People served",
"placeholder": "Homeless, Disabled, Child, etc",
"options": [
"abused",
"child",
"disabled",
"diseased",
"drug_addicted",
"homeless",
"juvenile",
"mental_health",
"migrant",
"orphan",
"senior",
"underprivileged",
"unemployed",
"victim"
]

}
"type": "combo",
"label": "People Served"
}
18 changes: 11 additions & 7 deletions data/presets/presets.json
Original file line number Diff line number Diff line change
Expand Up @@ -2109,9 +2109,10 @@
"operator",
"address",
"building_area",
"social_facility",
"social_facility_for",
"opening_hours",
"wheelchair",
"social_facility_for"
"wheelchair"
],
"geometry": [
"point",
Expand All @@ -2128,8 +2129,9 @@
"operator",
"address",
"building_area",
"opening_hours",
"social_facility_for"
"social_facility",
"social_facility_for",
"opening_hours"
],
"geometry": [
"point",
Expand All @@ -2147,9 +2149,10 @@
"operator",
"address",
"building_area",
"social_facility",
"social_facility_for",
"opening_hours",
"wheelchair",
"social_facility_for"
"wheelchair"
],
"geometry": [
"point",
Expand All @@ -2172,9 +2175,10 @@
"operator",
"address",
"building_area",
"social_facility",
"social_facility_for",
"opening_hours",
"wheelchair",
"social_facility_for",
"internet_access",
"internet_access/fee",
"internet_access/ssid"
Expand Down
5 changes: 2 additions & 3 deletions data/presets/presets/amenity/crematorium.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,14 @@
"phone",
"opening_hours",
"wheelchair"

],
"geometry": [
"area",
"area",
"point"
],
"tags": {
"amenity": "crematorium"
},
"terms": ["cemetery","funeral"],
"name": "Crematorium"
}
}
8 changes: 4 additions & 4 deletions data/presets/presets/amenity/social_facility.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,16 @@
"operator",
"address",
"building_area",
"social_facility",
"social_facility_for",
"opening_hours",
"wheelchair",
"social_facility_for"
"wheelchair"
],
"geometry": [
"point",
"area"
],
"terms": [
],
"terms": [],
"tags": {
"amenity": "social_facility"
},
Expand Down
5 changes: 3 additions & 2 deletions data/presets/presets/amenity/social_facility/food_bank.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@
"operator",
"address",
"building_area",
"opening_hours",
"social_facility_for"
"social_facility",
"social_facility_for",
"opening_hours"
],
"geometry": [
"point",
Expand Down
5 changes: 3 additions & 2 deletions data/presets/presets/amenity/social_facility/group_home.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@
"operator",
"address",
"building_area",
"social_facility",
"social_facility_for",
"opening_hours",
"wheelchair",
"social_facility_for"
"wheelchair"
],
"geometry": [
"point",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@
"operator",
"address",
"building_area",
"social_facility",
"social_facility_for",
"opening_hours",
"wheelchair",
"social_facility_for",
"internet_access",
"internet_access/fee",
"internet_access/ssid"
Expand Down
6 changes: 4 additions & 2 deletions dist/locales/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -1607,8 +1607,10 @@
}
},
"social_facility_for": {
"label": "People served",
"placeholder": "Homeless, Disabled, Child, etc"
"label": "People Served"
},
"social_facility": {
"label": "Type"
},
"source": {
"label": "Source"
Expand Down

0 comments on commit e9dfa04

Please sign in to comment.