Tim Penhey wrote:
>     postal_address = InterfaceField(
>         title=u"Postal Address"
>         )

Use zope.schema.Object here:

  postal_address = Object(
      title=u"...",
      schema=IAddress
      )

You can then have the this subobject's widget rendered as a subform by
the ObjectWidget. You'll have to give ObjectWidget a constructor that it
will call in case it has to create an IAddress object.

> Now it is with the postal_address I hit my first snag.  I really want to say 
> that it is an IAddress.  Am I using InterfaceField correctly here?  Is there 
> an option to specify the type of the interface?
> 
> Also how do I specify a list of addresses?

  addresses = List(
      title=u"...",
      value_type=Object(schema=IAdress),
      )

Philipp

_______________________________________________
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users

Reply via email to