Hi,
I wanted to report that despite of providing a validator when creating a CalendarDatePicker widget, it always uses the same.
def __init__(self, name=None, default=None, allow_empty=False,
calendar_lang="en", **kw):
"""
Use a _javascript_ calendar system to allow picking of calendar dates.
The format is in mm/dd/yyyy unless otherwise specified
"""
super(CalendarDatePicker, self).__init__(name, **kw)
self.allow_empty = allow_empty
if default is not None or self.allow_empty:
self._default = default
self.validator =
validators.DateTimeConverter(
#HERE <-------------------
format=self.format, allow_empty=self.allow_empty)
self._javascript_=[JSLink(static, "calendar/calendar.js"),
JSLink(static, "calendar/calendar-setup.js"),
LocalizableJSLink(static,
["calendar/lang/calendar-%(lang)s-%(charset)s.js",
"calendar/lang/calendar-%(lang)s.js",
"calendar/lang/calendar-%s.js" % calendar_lang])]
it should be initialized as a keyword argument, no?
I'm using TG 0.96a, mmhhh.... if it has been solved, sorry for the post
Javier Rojas
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/turbogears
-~----------~----~----~----~------~----~------~--~---
- [TurboGears] bug? validator in CalendarDatePicker Javier Rojas

