#67 ✓resolved
powertoaster

I am getting [nil_class] in my forms with multiple parents

Reported by powertoaster | March 14th, 2009 @ 08:29 AM

I have a document object.

class Document < ActiveRecord::Base belongs_to :devicetype belongs_to :doctype belongs_to :manufacturer end

class Manufacturer < ActiveRecord::Base has_many :documents end class Devicetype < ActiveRecord::Base has_many :documents end class Doctype < ActiveRecord::Base has_many :documents end

In my search form I have fields for all three parents. This works beautifully for the first parent and any fields of the document object but any parent fields after the first come back as nil_class here is what gets generated.

I have attached my index.html.erb so that you can see how I am calling the helper.

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Provides common named scopes and object based searching.

People watching this ticket

Attachments

Pages