Thanks for the reply. My models are correct, they work find at the
higher levels of the hierarchy.
On Sep 18, 9:01 am, Patrick Doyle
<wpds...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
wrote:> Could this be a pluralization issue?
> Did you set up your models as:
>
> class Parent < ActiveRecord::Base
> has_many :children
> end
>
> class Parent < ActiveRecord::Base
> has_many :children
> belongs_to :parent
> end
>
> class Dog < ActiveRecord::Base
> has_many :dogs
> belongs_to :child
> end
>
> If so, then I would think that something like this might work:
>
> parent = Parent.find(params[:parent_id])
> child = parent.children.find(params[:child_id])
> @record= child.dogs.build(params[:dog])
>
> ...but I am still very much a RoR neophyte. Everything I know about
> nested routes I learned
fromhttp://akitaonrails.com/2007/12/12/rolling-with-rails-2-0-the-first-f...,
> and I refer back to there each time I try to do it again.
>
> --wpd