I have a model “party” that has a time field “starts_at”. I have created
a form to add new instances of this model.
<%= select_date Date.today, :prefix => ‘party’ %>
Sadly I get the error:
NoMethodError in Parties#add
undefined method `month=’ for #Party:0x256a600
How can I fix this problem? I remember that I saw in scaffolds that date
selectors have something like party[year(1n)] or so as their names…
How can I achieve this using the select_date helper?
If you’re only storing a time of day, why don’t you have
start_hour and start_minute DB fields, and use select_hour
and select_minute helpers?
I only want to split the datetime selection for layouting purposes…
first the user can select the date, and then he can select the time. But
maybe I’ll have to put it in the same place under these conditions.
I only want to split the datetime selection for layouting purposes…
first the user can select the date, and then he can select the time. But
maybe I’ll have to put it in the same place under these conditions.
If you want to split the date and time you’ll have to use