I’m using Rails 2.3.2, and trying to get a nested object form to work
properly. I’ve narrowed my problem to the issue that Rails is not
setting my nested form elements with the *_attributes required to
initiate the accepts_nested_attributes_for processing. So instead of
As a result, I get a TypeMismatch exception. I’ve followed the
documentation from Ryan Daigle. I’ve also followed the advice from this
blog and the complex-forms-example.
Using Firebug, I went through my form and adjusted the name attribute of
the input tags from name to name_attributes. This produced the params
with name_attributes, and the create worked fine.
I’m stuck as I cannot figure out why my form is not producing the
*_attributes form of the name.
Another thing I tried is I got the complex_form_example working in my
environment. I’ve gone through every inch of the controller, models and
views and compared it to my code. I cannot find what is different. I
know this is something small, and would appreciate any help!