pallets-eco / wtforms-appengine

WTForms integration for Google App Engine
https://wtforms-appengine.readthedocs.io
Other
42 stars 16 forks source link

Fix 'choices' argument to correctly accept tuple #9

Closed sadovnychyi closed 8 years ago

sadovnychyi commented 9 years ago

Currently if you will pass choices argument for select field with list of tuples (as per docs) it will force to use only value, without label.

sadovnychyi commented 8 years ago

As I remember, there's no way to pass a list of tuples with [('choice_id', 'choice_label'), ...] as you always use ID as a label, which is hardcoded. For a compatibility it makes sense to first check the value and make transformations only if needed.

You are too late with response anyway, I'm not using wtforms anymore.