author | sylvain.thenault@logilab.fr |
Thu, 30 Apr 2009 12:36:14 +0200 | |
branch | tls-sprint |
changeset 1577 | 25b46db3cb81 |
parent 1576 | 3bfcf1e4eb26 |
child 1578 | 73af05429cb4 |
web/formfields.py | file | annotate | diff | comparison | revisions |
--- a/web/formfields.py Thu Apr 30 12:35:49 2009 +0200 +++ b/web/formfields.py Thu Apr 30 12:36:14 2009 +0200 @@ -460,6 +460,7 @@ for cstr in constraints: if isinstance(cstr, StaticVocabularyConstraint): kwargs.setdefault('widget', Select()) + kwargs.setdefault('choices', cstr.vocabulary) if card in '?1': kwargs['widget'].attrs.setdefault('size', 1) if isinstance(cstr, SizeConstraint) and cstr.max is not None: