On Wed, Feb 20, 2008 at 08:12:29AM +0100, Hermann Himmelbauer wrote: > Am Dienstag, 19. Februar 2008 20:13 schrieb Marius Gedminas: > > We don't modify fields, ever. We use the power of zope.formlib (or > > z3c.form) to get dynamic forms. > > Yes, I also use z3c.form, but my problem is that the field has the "required" > flag set to "True", which is appropriate for an add/edit form but may not be > appropriate for a search form. > > If I change the "required" flag on the field level, e.g. in the update() > method, the change is permanent in the interface, which is not appropriate. > And changing it on the widget level seems to be very complicated, at least, I > found no way to do it.
Ah, *this* problem. The way we solved it in our project was to make all the fields not required in the interface, then add extra validation to the forms where the fields were required. Marius Gedminas -- If Linux doesn't have the solution, you have the wrong problem.
signature.asc
Description: Digital signature
_______________________________________________ Zope3-users mailing list Zope3-users@zope.org http://mail.zope.org/mailman/listinfo/zope3-users