[Product-Developers] Dexterity: make a list field required
David Glick (Plone)
david.glick at plone.org
Wed Dec 5 18:59:52 UTC 2012
I think you can also say min_length=1 ... but the error message in case
the list is too short might be cryptic, IIRC.
On 12/5/12 10:57 AM, Christian Ledermann wrote:
> OK figured out a workaround:
> def isnotempty(value):
> return bool(value)
> layers = schema.List(
> description=_(u"WMS Layers"),
> On Wed, Dec 5, 2012 at 9:50 PM, Christian Ledermann
> <christian.ledermann at gmail.com> wrote:
>> I try to make a list filed required for a dexterity type:
>> layers = schema.List(
>> description=_(u"WMS Layers"),
>> but when I save the edit form it does not complain wether
>> the list field is filled or not
>> Best Regards,
>> Christian Ledermann
>> Nairobi - Kenya
>> Mobile : +254 702978914
>> If you save the living environment, the biodiversity that we have left,
>> you will also automatically save the physical environment, too. But If
>> you only save the physical environment, you will ultimately lose both.
>> 1) Don’t drive species to extinction
>> 2) Don’t destroy a habitat that species rely on.
>> 3) Don’t change the climate in ways that will result in the above.
More information about the Product-Developers