[Grok-dev] Dependent choice fields with formlib

Sebastian Ware sebastian at urbantalk.se
Thu Sep 18 12:53:44 EDT 2008

I am guessing here, but I think you can add a


to your choice field, and then allways have an item in values that  
corresponds to xyz (such as "Select one...")

Mvh Sebastian

18 sep 2008 kl. 17.07 skrev Santiago Videla:

> Hi,
> I'm trying to make a custom search form using formlib
> In that form I have 1 select (schema.choice) that depends on another  
> select field, and using KSS when one changes the other is updated  
> (for example, country and city)
> My interface is something like this
>    master = schema.Choice(title='Master field',  
> vocabulary='some.registered.vocabulary')
>    slave = schema.Choice(title='Slave field', values=['Select  
> one...',])
> But when the slave field it's update using KSS, the submit action  
> give me an "Invalid Input" error in the slave field.
> I guess that this is because, the values updated does not belong to  
> the list of values (['Select one...'])
> How should I tackle this?
> thanks in advance
> -- 
> Santiago Videla
> www.revolucionesweb.com.ar
> http://www.linkedin.com/in/svidela
> Sigue la mata dando de que hablar siempre abajo y a la izquierda  
> donde el pensamiento que se hace corazón resplandece con la palabra  
> sencilla y humilde que l at s tod at s somos.
> _______________________________________________
> Grok-dev mailing list
> Grok-dev at zope.org
> http://mail.zope.org/mailman/listinfo/grok-dev

More information about the Grok-dev mailing list