To get rid of the "user is invalid",  remove
validates_associated :user from the UserInfo model

Meanwhile, read up on validates_associated:
http://api.rubyonrails.org/classes/ActiveRecord/Validations/ClassMethods.html#M002461
and make sure you want ot use it here.

Gavin

http://handyrailstips.com

On Jul 3, 4:00 pm, Salil Gaikwad <[email protected]>
wrote:
> Hi Gavin,
>
> I try following as u say
> <%= error_messages_for :user %>
>  but it gives me same error messages.
> i don't know how to use @user.errors.on(:first_name)
> and where to use?
>
> Regards,
>
> Salil Gaikwad
> --
> Posted viahttp://www.ruby-forum.com/.
--~--~---------~--~----~------------~-------~--~----~
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 [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to