Skip to content

Instantly share code, notes, and snippets.

@justinfrench
Forked from kirkbushell/gist:1727355
Created February 3, 2012 03:47
Show Gist options
  • Save justinfrench/1727546 to your computer and use it in GitHub Desktop.
Save justinfrench/1727546 to your computer and use it in GitHub Desktop.
# PRODUCT MODEL
has_many :product_people
has_many :people, :through => :product_people
accepts_nested_attributes_for :people
<%= f.inputs "Cast" do %>
<%= f.inputs :for => :people do |p| %>
<%= p.input :name %>
<%= p.input :_destroy, :as => :boolean %>
<% end %>
<% end %>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment