Sha256: 09e5bc6f2fec3b22e75928fa67cb868fb29caf5cbe6e422242bd14b9b07e8222

Contents?: true

Size: 437 Bytes

Versions: 3

Compression:

Stored size: 437 Bytes

Contents

<% if params[:type] == 'prototype' %>
  <%= javascript_include_tag 'prototype', 'prototype_nested_form' %>
<% else %>
  <%= javascript_include_tag 'jquery', 'jquery_nested_form' %>
<% end %>

<%= nested_form_for @project do |f| -%>
  <%= f.text_field :name %>
  <%= f.fields_for :tasks do |ff| -%>
    <%= ff.text_field :name %>
    <%= ff.link_to_remove 'Remove' %>
  <% end -%>
  <%= f.link_to_add 'Add new task', :tasks %>
<% end -%>

Version data entries

3 entries across 3 versions & 2 rubygems

Version Path
nested_form_im-0.2.0.1 spec/dummy/app/views/projects/new.html.erb
nested_form-0.2.1 spec/dummy/app/views/projects/new.html.erb
nested_form-0.2.0 spec/dummy/app/views/projects/new.html.erb