I've used the nested\_form gem, whenever i try and submit something to my form i get the `Can't mass-assign protected attributes:items` message, even though i've already put `attr_accessible` in my models.

Form:

```
<%= nested_form_for(@goods_in) do |f| %>
...

<%= f.fields_for :items do |i| %>
<td><%= i.text_field :description, :autocomplete => :off%></td>
<td><%= i.text_field :quantity, :autocomplete => :off %></td>
<th><%= i.link_to_remove "Remove this item" %></th>
<% end %>
<%= f.submit :"Submit Delivery" %>
<% end %>

```

Goods In Model:class GoodsIn < ActiveRecord::Base
 belongs\_to :supplier
 has\_many :items

```
attr_accessible :c4lpono, 
              :courier, 
              :deliverydate,  
              :deliverynoteno,  
              :destination,  
              :notes,  
              :quantity,  
              :signedby,
              :supplier_id,
              :partcode_ids

accepts_nested_attributes_for :supplier

validates :c4lpono, 
              :deliverydate,  
              :deliverynoteno,  
              :destination,  
              :quantity,  
              :signedby,
              :presence =>true                  

end

```

Item Model

```
class Item < ActiveRecord::Base
belongs_to :goods_in

attr_accessible :quantity,
              :partcode,
              :description,
              :goods_in_id

accepts_nested_attributes_for :goods_in

end

```

Goods In Controller:

```
def create
@goods_in = GoodsIn.new(params[:goods_in])
end

```