Ruby on Rails
Tuesday, April 25, 2017
I'm trying to assign additional parameters to create to satisfy validations in the model like so
-- address="params[:address0] + params[:address1]
@user.address=address
if @user.save
...
In this example there's address0 and address1 in the form but not the schema which has only :address
Should this work?
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/fa52769d-ae0e-41de-90ef-9acca82edc23%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment