How to allow users to edit a time?

I’m building a little time tracker. Each session has both ‘start’ and ‘end’ date fields. I want to let users edit those - but only the times, not the dates.

Is it possible to do this with a simple input? I imagine I could do something with the date/time picker, but I don’t want to show the date.

There’s an option to have a ‘date’ content format for an input element, but not ‘time’, and if I try to format a date as a time, I get an error, understandably:

23%20PM

Thanks!

2 Likes

I, too, would like this functionality, if anybody can help.

1 Like

I spent hours on this today, ending up with a bunch of different elements (separate inputs for hours and minutes, and dropdowns for am/pm) and separate workflows to make it all happen, and there were still several issues.

In the end, by far the simplest approach was to use the date/time picker and just put something over top of the ‘date’ side of it to hide it. Seems like an ugly hack, but trust me, it’s waaaaay simpler than the other way.

1 Like

I use Air Date/Time picker for this purpose (a plugin). I then store the results in date fields. Happy to explain in more detail if required.

It would be nice if there were more options to manipulate times/dates in Bubble…

1 Like

Hmmm. I hadn’t even considered just placing a group or shape with a background on top of the Date/Time picker to hide the date. You’re right, it’s hacky, but I’ll give it a shot tomorrow. Thanks!

1 Like

Thanks for the input, Andrew. I’ve used that plugin too in the past, but I’m not a big fan of the slider UI. It’s very glitchy on mobile. I wish the native Bubble Date/Time picker had a “Show Time Only” option.

3 Likes

Me too…

1 Like

This topic was automatically closed after 70 days. New replies are no longer allowed.