My rails date picker field sends date time info broken into different values in params hash like :
Parameters: {"commit"=>"Save",
"interview_date(3i)"=>"29",
"interview_date(1i)"=>"2013",
"interview_date(4i)"=>"20",
"interview_date(5i)"=>"13",
"interview_date(2i)"=>"8}
How can I make it send the date time as one proper string?
Parameters: {"commit"=>"Save",
"interview_date"=>"2013-8-29 20:8:13"}
I know Rails will convert this into date, but that happens only when my model has interview_date as attribute. ActiveRecord recognizes and converts it into interview_date. In my case I am storing this information in a model named Response in an attribute named 'answer'. So rails does not convert it as it does not match the name of attribute.