How can I get the form of nested rails? I am having trouble setting this up properly. Right now I have:
<%= simple_form_for @user do |f| %>
<%= f.input :city %>
<%= f.input :address %>
<%= f.input :zipcode %>
<%= f.association :interests, :as => :check_boxes, :label => false %>
<%= f.association :holidays, :as => :check_boxes, :label => false %>
<%= f.simple_fields_for :friend_birthdays do |friend_birthday| %>
<%= f.input :name %>
<%= f.input :gender, :collection => ['male','female'] %>
<% end %>
<%= f.button :submit %>
<% end %>
f.associationworks great for my models of interests and holidays, as they only need to collect one attribute. However, the model friend_birthdayshas the same exact relationship as (interests and holidays) with the user model, but requires editing / adding several attributes. Any ideas?
js111 source
share