What would be the best way to combine two fields in a form into a single model field in Rails 4? My form has separate date and time picker text inputs, and I'd like those to be combined on the fly into a single timestamp field.
<%= f.text_field :published_at, class: 'datepicker' %>
<%= f.text_field :published_at, class: 'timepicker' %>
User @Chris Barretto makes a wonderful job explaining how you could do this: https://stackoverflow.com/a/6730104/2620080
You can try to change the input to
data_select
andtime_select
.