-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

I using the following pattern to define some properties
as lists of ints:

class Numbers(SequenceSchema):
   number = SchemaNode(Int)

class MySchema(MappingSchema):
   products = Numbers(widget=MultiSelectWidget)
   field_ids = Numbers(widget=MultiSelectWidget)

Inside a Zope 2 app I derived MultiSelectWidget from SelectWidget
and provided a slightly different edit template generating

<select name="${field.name}:list" multiple="1">
....

</select>

as we would do it inside a traditional Zope 2 app.

Rendering the edit view with passing in lists of ints into the form
works fine.

Upon submit I am using basically the following  code (as Chris described
here) for turning the Zope request into a webob compatible request:

http://lists.repoze.org/pipermail/repoze-dev/2010-December/003706.html

However this does not work properly.
Common error message:
    "[1,2,3] is not iterable").

How should I treat a list of ints as provided by the ZPublisher in order
make it compatible with the schema above?

Andreas



-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (Darwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQGUBAEBAgAGBQJNJvqjAAoJEADcfz7u4AZjkG8Lv0n8FDjUJJ+Llr2k9f1U/67U
3C8c5/8vu7l7kpxx3rxQdVFuYgUT2KLrEwRSBFit2huSyIAgQsQIcN1DCppUuXYD
UB2itKz9IH2pvQ4N3lqLCmDqpYb3TnEgRXC83WgCKtXq3hldvvcz5BmJ3EwA0id0
IFRr2fK7OB94vASkqy1eyC4JSbpoqU5lVI4MXy84r2uzlXI/LXKxuTPa2mpN/86v
Pp2bifkj9NUYM0Qay3exeUezSfYH5BaCZ7Bu0/9IB63TVwAM7qQkmhgzfaXcDzxP
zHqWmksCGydNxtaXZry2lob5JmmbP+tvqIHpN2VvBZuIJTDKX+Y+QsHfViceopYB
wqCGLQu6NCjQC79lRd+7zX3XjsZEyLWElaOT6V22QpBK5hjcm0DH6YFenXWOs/X9
TZ2zTa1v6tbK9xaQvdkVFHxNsR1Crv14SHCNn2rVX2e+CnwaqaAUHcvQFCWxTJ4V
Cp92XfL5g97o0zs6qeE2sifyFyr9Kks=
=rtRt
-----END PGP SIGNATURE-----

<<attachment: lists.vcf>>

_______________________________________________
Repoze-dev mailing list
Repoze-dev@lists.repoze.org
http://lists.repoze.org/listinfo/repoze-dev

Reply via email to