New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add the deform.widget.DateTimeWidget
widget, which uses the jQueryUI Timepicker add-on.
#11
Conversation
jQueryUI Timepicker add-on. ``DateTimeWidget`` uses the ISO8601 combined date and time format internally, as expected by ``colander.DateTime``, but converts to the more friendly separate date and time format for display in the widget.
Let me know if I can help get this merged. If it were my birthday, I'd also wish for a new release. I have a package that's already depending on these changes. :-) |
I just did something similar to a local branch. I have however created new types as well, called SimpleTime and SimpleDateTime, that strip the seconds and milliseconds. The rationale is that any user facing data doesn't need that kind of precision. Imagine if you had a form to book a flight, and the date time widget asked you to fill in seconds? I'm also looking into a javascript-based date-range validator, that would enforce start < end. |
I'd rather keep using the |
This patch looks great. Unfortunately, the DateTime widget, while it works fine in Firefox 3, does not seem to work in Chromium. Could I tweak you into maybe testing/fixing that? |
I should clarify "doesn't work"... no matter what input you provide to the widget in Chromium, it won't allow you to submit, claiming "Invalid value". |
You're right. I think I need to use the |
I experimented with
|
OK, I think without full features in IE, Chrome, FF this probably belongs in an add-on unless there's some way to get it all to go. |
Well I implemented it with |
Nope, no insistence here.. just let me know what to do. |
I would go with text. I'm happy to be HTML5 compliant, but only when it doesn't break HTML4+ while doing so. I think the datetime stuff falls in that category. |
Hehe. So this last commit 7028e90 fixes the problem that you were seeing. I realise I might have confused you with my "I experimented with..." comment. Thanks. |
Rock on. Merged. |
DateTimeWidget
uses the ISO8601 combined date and time formatinternally, as expected by
colander.DateTime
, but converts to themore friendly separate date and time format for display in the widget.