In my Rails 3 application, I have the following simple relational structure:
class Rollout < ActiveRecord::Base has_many :items, :through => :rollout_items end class RolloutItem < ActiveRecord::Base belongs_to :rollout belongs_to :item end class Item < ActiveRecord::Base has_many :rollouts, :through => :rollout_items end
Controller:
def new @rollout = Rollout.new end
I get the above error with the following form:
<%= simple_form_for @rollout do |f| %> <%= f.association :items %> <% end %>
source share