[Grok-dev] Grok & Annoying time problem

Marcel Klapschus battlefox at gmail.com
Tue Aug 10 04:05:32 EDT 2010




Sascha Boch wrote:
> 
> I think the problem is that the code that sets up the widgets is only
> executed when the server starts. From that point on, they remain static
> until the next restart. 
> 
> What you want is to define a constraint on the field like this:
> 
> def check_date(value):
>   return value < datetime.date.today()
> 
> 
> currentdate = zope.schema.Date(
>                       title=  u'currentdate',
>                       constraint = check_date,
> 
> HTH,
> Sascha
> -- 
> GMX DSL SOMMER-SPECIAL: Surf & Phone Flat 16.000 für nur 19,99 ¿/mtl.!*
> http://portal.gmx.net/de/go/dsl
> _______________________________________________
> Grok-dev mailing list
> Grok-dev at zope.org
> https://mail.zope.org/mailman/listinfo/grok-dev
> 
> 


Thank you very much, that solved the problem. ;-)
-- 
View this message in context: http://old.nabble.com/Grok---Annoying-time-problem-tp29394781p29395238.html
Sent from the Grok mailing list archive at Nabble.com.



More information about the Grok-dev mailing list