I have a user model where I cannot create a client due to it being unwritable in mass assignment.
How do I make it so that I can create a client model?
Code and error are found here: http://pastie.org/1206482
I have a user model where I cannot create a client due to it being unwritable in mass assignment.
How do I make it so that I can create a client model?
Code and error are found here: http://pastie.org/1206482
I think you have to add:
attr_accessible client_attributes
to your user model. client_attributes is the hash in the user hash posted to the create action.
The transmitted hash looks something like this: :user => { :username => "one", ..., :client_attributes => { :name => "client" } }