Add time input to contribution form #146
Reference in New Issue
Block a user
Delete Branch "feauture/141-time_picker"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
After adding it as a separate field, I figured out that we should use the same picker, because otherwise we'd have to keep the date in sync depending on the time zone. Zones are too messy in that regard, and the date is already normalized to UTC before creating the contribution record.
Edit: I forgot to split out the commit that adds proper labels to the same form, instead of relying on placeholders only (which is bad for accessibility as well as usability).
closes #141
Someone has an idea for how to do this in the most simple and efficient way? /cc @galfert @fsmanuel
I think it works like this:
Unfortunately you can't just concatenate it (
new Date().setHours(0, 0, 0, 0)), becausesetHoursreturns a timestamp.Scrap my previous comment, I misread you wanted it to be the beginning of the day, not the current hour.
Since we already have moment in the project, I think the easiest way would be
Awesome, will try that. Thanks!
Added the missing import and fixed another issue. All ready to merge afaics.