[TransWarp] Use cases/design goals/scope for peak.web forms (part 1)

Phillip J. Eby pje at telecommunity.com
Tue Aug 12 17:20:54 EDT 2003

At 10:47 PM 8/12/03 +0200, Roché Compaan wrote:

>At the time of the adaptation we don't know what items must be in the
>list and what items must be selected. This means that the form should
>discover this at render time and supply these values to the widget. We
>need to give the form some hint to where these values should come from.
>If we take your bulletins app as example then one would want a select
>control for the category of a bulletin. I thought one way of handling
>this would be to set an attribute on the feature that can be used by the
>form or a field to populate the widget with items:
>     class Bulletin(model.Element):
>         class category(model.Attribute):
>             referencedType = 'Category'
>             referencedEnd = 'bulletins'
>             sortKey = 'id'
>             displayName = 'title'
>             selectFrom = 'NameOfBindingToCategories'
>I am not sure though. Maybe it should be a binding that can be resolved
>by walking up the component hierarchy. Any ideas how this will work in

This will probably be done by looking for a 
'web.SpecialistFor(elementClass)' utility, and then asking it for a widget 

More information about the PEAK mailing list