Sha256: b5fc7bf8ffbedc2d526b40cd5ba4b6fee9dd261792b8d418881de247d8e3c092

Contents?: true

Size: 1.04 KB

Versions: 1

Compression:

Stored size: 1.04 KB

Contents

<fieldset class="field-unit--nested <%= field.attribute %>">
  <div class="container-flex">
    <!-- <legend><%= f.label field.attribute %></legend> -->
    <%= f.fields_for field.association_name do |nested_form| %>
        <%= render(
          partial: "fields/nested_has_many/fields",
          locals: {
            f: nested_form,
            field: field,
          },
        ) %>
    <% end %>
    <div class = "add_has_many">
      <%= link_to_add_association(
        I18n.t("administrate.fields.nested_has_many.add", resource: field.associated_class_name.titleize),
        f,
        field.association_name,
        class: "button toto button_add_associated_#{field.associated_class_name}",
        # class: "button toto button_add_associated_#{field.associated_class_name}",
        # # id usefull for the JS inside New quotation
        # id: "button_add_associated_#{field.associated_class_name}",
        partial: "fields/nested_has_many/fields",
        render_options: { locals: { field: field } },
      ) %>
    </div>
  </div>
</fieldset>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
worker-field-nested_has_many-0.1.0 app/views/fields/nested_has_many/_form.html.erb