Feature #7894: Add more HTML5 input types
Add a WDateTimeEdit
It would be nice if we could bundle
WTimeEdit into one widget that uses
Natively, we can use an
<input type="datetime-local">: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/datetime-local
For the non-native implementation, we could base it on a
WLineEdit, just like
WTimeEdit, and popup something that allows changing both the date and time at the same time. We'll need some icon that expresses this. Font Awesome does not appear to include it, but there may be other similar royalty-free icons that we can use.
WDateTime should be changed to use a
WDateTimeEdit instead of a
WLineEdit as well.
Updated by Mark Travis 8 months ago
I just ran into a need for this. I have quite a few fields in the database defined as WDateEdit, which would be easy to modify with this functionality.
Instead, I create a WDateTime object, use calendar widget to set a date, setDate() in the WDateTime object, then pass the value of WDateTime to the database without regard to the time component.
It would be nice to simplify this process and get rid of the intermediate WDateTime object and get the value directly from the widget(s).