In py4web, when form validation fails on a datetime field, py4web throws 
and exception.
In the IS_DATETIME validator, when validation fails, validate() returns 
value as string (the original value).
The form code tries to display the fields properly by calling field's 
validator formatter().
Since the value is string and not datetime, formatter() throws exception.

I wrote issue here:https://github.com/web2py/pydal/issues/609
but now I'm not sure whether change should be pydal or py4web.
Should the formatter() handle value with type of string?
Or, should form not try to call formatter() when there is an error?


-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/web2py/695844b9-801c-432e-98fd-a981c95090ad%40googlegroups.com.

Reply via email to