posm / OpenMapKitAndroid

http://openmapkit.org
BSD 3-Clause "New" or "Revised" License
128 stars 38 forks source link

Enable / Disable Custom Value Input #147

Closed hallahan closed 8 years ago

hallahan commented 8 years ago

Sometimes we might not want to allow a custom value input for the user.

One example is could be building. When this feature was requested, what tags did you have in mind?

cc/ @PaulUithol @dalekunce

PaulUithol commented 8 years ago

Any question where there's just a small set of accepted answers; there's some tags that are only used for yes/no for example. In Uganda, we also had a list of all possible (regulated) banks for the operator key on that form. level could be another one, although restricting that to /[0-9]/ would perhaps be better. On May 11, 2016 9:38 PM, "Nicholas Hallahan" notifications@github.com wrote:

Sometimes we might not want to allow a custom value input for the user.

One example is could be building. When this feature was requested, what tags did you have in mind?

cc/ @PaulUithol https://github.com/PaulUithol @dalekunce https://github.com/dalekunce

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/AmericanRedCross/OpenMapKitAndroid/issues/147

hallahan commented 8 years ago

building:level? I guess that would make sense in Paris or DC where you know all buildings are below a certain threshold.

Another would be building:condition.

https://wiki.openstreetmap.org/wiki/Key:building:condition

dalekunce commented 8 years ago

honestly I think 90% of the time we do not want the user to be able to enter a custom value. For me the default should be tags/option only with flag for the potential 'other' value similar to how ODK works now.

hallahan commented 8 years ago

Ok, I'll have it off by default.

hallahan commented 8 years ago

In the constraints JSON, the custom value input will be enabled if:

"shop": {
    "custom_value": true
  }

where "shop" is the tag with select one or select multiple you want to provide the custom value input.