How to create another object when creating a Devise User from their registration form in Rails?
问题 There are different kinds of users in my system. One kind is, let's say, a designer: class Designer < ActiveRecord::Base attr_accessible :user_id, :portfolio_id, :some_designer_specific_field belongs_to :user belongs_to :portfolio end That is created immediately when the user signs up. So when a user fills out the sign_up form, a Devise User is created along with this Designer object with its user_id set to the new User that was created. It's easy enough if I have access to the code of the