> > I agree. I'd specify this by saying:
> >
> >   o An empty string sent from a browser for an optional_date
> >     field is interpreted as a null (not specified) value
> >
> >   o The "internal" representation of an optional_date (the
> >     value you find in the REQUEST after conversion) is
> >     always either a valid DateTime instance or None
> I think then the value in the fields will be shown as "None", 
> which I don't
> particularily like, even though I would rather have None as the internal
> representation instead of an empty string. Is there a way to fix that, so
> that date_fields set to None will be displayed as empty?

Sure. The property forms just need to do the equivalent 

<dtml-if theDate>
<dtml-var theDate fmt="somthing">

I know that this is a style issue to some, but I feel that 
the value should either be null or valid, and code and 
templates should be written to deal with the two possibilities 
as a matter of course.

Brian Lloyd        [EMAIL PROTECTED]
V.P. Engineering   540.361.1716       
Zope Corporation   http://www.zope.com

Zope-Dev maillist  -  [EMAIL PROTECTED]
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope )

Reply via email to