Sha256: 697f4551688b0e4d399a4c940f725f46ef9cbe188b17e6a0c785f2ba8b652a00

Contents?: true

Size: 598 Bytes

Versions: 1

Compression:

Stored size: 598 Bytes

Contents

<% f.object.send(fk).each_with_index do |ar, idx|  %>
  <div class="control-group">
    <%= f.fields_for fk do |ar_form| %>
    <div class="controls">
      <!-- do some stuff to see if this type has a specific view partial -->
      <% if File.file?(File.expand_path("_#{ar.type.to_s.downcase}_form.html.erb", File.dirname(__FILE__))) %>
        <%= render :partial => "#{ar.type.to_s.downcase}_form", :locals => {f: f, fk: fk} %>
      <% else %>
        <%= ar_form.text_field  "",  :class => 'text_field', :value => ar %>
      <% end %>
    </div>
    <% end %>
  </div>
<% end %>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
common-content-0.0.5 app/views/contents/_array_form.html.erb