[Zope3-Users] z3c.form: Integer-based fields incorrectly validated
Markus Leist
ml_zope3_dev at ikom-online.de
Wed Aug 1 14:37:36 EDT 2007
Hi,
do you have a
from zope.schema.fieldproperty import FieldProperty
class Foo:
implements(IFoo)
foobarid = FieldProperty( IFoo['foobarid'])
?
Regards,
Markus
Am Mittwoch 01 August 2007 um 19:15 Uhr schrieb Hermann Himmelbauer <dusty at qwer.tk>:
> Hi,
> In one of my forms, one field is defined like that:
>
> foobarid = Int(
> title=u'ID',
> description=u'ID of Foobar',
> required=False)
>
> When I add this field in a z3c.form based form, e.g.:
>
> fields = field.Fields(IFoo['foobarid'])
>
> Then the validation of the field fails, e.g. if I type in a correct value,
> e.g. "123", zope returns an error:
>
> "The entered value is not a valid integer literal."
>
> Interestingly, if I set "1,123" as value, zope outputs:
>
> "Objekttyp ist falsch."
>
> I tried to investigate this futher, but things are getting complicated at the
> file "converter.py", line 96 (no clue what a formatter is).
>
> Is this a bug or am I doing something wrong?
>
> Best Regards,
> Hermann
>
More information about the Zope3-users
mailing list