The user does not know what creditcards are in your user model. You have to have an association in the user model if you want to do User.first.creditcards.new
has_many :creditcards or get the users account and then check the creditcard.. Since a user has_many accounts you would have to get an account before you could create a creditcard. So something like User.first.accounts.first.creditcard.new would explain better... Or you could use has_many through and use the accounts model as the through... has_many :accounts has_many :creditcards, :through => :accounts --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---