Sha256: 54ec017541e6591bc3919e541ec44bfb2a9503ef3e12158e231e4ce55d623390

Contents?: true

Size: 488 Bytes

Versions: 21

Compression:

Stored size: 488 Bytes

Contents

<%= form_for @parent do |f| %>
  <fieldset>
    <legend>Children</legend>

    <ol data-role="activerecord_sortable">
      <%= f.fields_for :children do |ff| %>
        <li data-role="child<%= ff.object.to_s %>" data-position="<%= ff.object.position %>">
          <%= ff.object.name %>

          <%= ff.hidden_field :name %>
          <%= ff.hidden_field :position, :data => { :role => 'position' } %>
        </li>
      <% end %>
    </ol>
  </fieldset>

  <%= f.submit %>
<% end %>

Version data entries

21 entries across 6 versions & 1 rubygems

Version Path
activerecord-sortable-0.0.8 spec/dummy-3.2/app/views/parents/_form.html.erb
activerecord-sortable-0.0.8 spec/dummy-4.2/app/views/parents/_form.html.erb
activerecord-sortable-0.0.8 spec/dummy-4.1/app/views/parents/_form.html.erb
activerecord-sortable-0.0.8 spec/dummy-4.0/app/views/parents/_form.html.erb
activerecord-sortable-0.0.7 spec/dummy-4.0/app/views/parents/_form.html.erb
activerecord-sortable-0.0.7 spec/dummy-4.2/app/views/parents/_form.html.erb
activerecord-sortable-0.0.7 spec/dummy-4.1/app/views/parents/_form.html.erb
activerecord-sortable-0.0.7 spec/dummy-3.2/app/views/parents/_form.html.erb
activerecord-sortable-0.0.6 spec/dummy-4.0/app/views/parents/_form.html.erb
activerecord-sortable-0.0.6 spec/dummy-3.2/app/views/parents/_form.html.erb
activerecord-sortable-0.0.6 spec/dummy-4.1/app/views/parents/_form.html.erb
activerecord-sortable-0.0.6 spec/dummy-4.2/app/views/parents/_form.html.erb
activerecord-sortable-0.0.5 spec/dummy-3.2/app/views/parents/_form.html.erb
activerecord-sortable-0.0.5 spec/dummy-4.2/app/views/parents/_form.html.erb
activerecord-sortable-0.0.5 spec/dummy-4.1/app/views/parents/_form.html.erb
activerecord-sortable-0.0.5 spec/dummy-4.0/app/views/parents/_form.html.erb
activerecord-sortable-0.0.4 spec/dummy-4.0/app/views/parents/_form.html.erb
activerecord-sortable-0.0.4 spec/dummy-4.2/app/views/parents/_form.html.erb
activerecord-sortable-0.0.4 spec/dummy-4.1/app/views/parents/_form.html.erb
activerecord-sortable-0.0.4 spec/dummy-3.2/app/views/parents/_form.html.erb