On Sat, Nov 6, 2010 at 1:13 AM, TomRossi7 <[email protected]> wrote:
> Why is belongs_to :through not an option with Rails? I'm sure there > is something I'm missing! I find myself wanting it more now with lazy > loading in Rails 3. > > project belongs_to client > > task belongs_to project > task belongs_to client :through project > > I can work around it by just creating a method on the task model > called client and just returns project.client, but that isn't as > beautiful! > > Thanks, > Tom What you're really looking for is has_one :through. -- Erol M. Fornoles http://github.com/Erol http://twitter.com/erolfornoles http://ph.linkedin.com/in/erolfornoles -- 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.

