So I have this

Event
  has_many :assistance
  has_many :users, :through => :assistance

User
  has_many :assistance
  has_many :assisted_events, :through => :assistance, :source =>
:assistance

Assistance
  belongs_to :user
  belongs_to :event

Users assisting to events are assigned using

@event.users << user
BUT assistance model also have an status attribute, so I need to fill it
at the same time of doing @event.users << user, is it possible to make
it on the same line? I actually dont know how to assign that attribute

-- 
Posted via http://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