Files
grecia/app/views/links/_nested_links.html.erb
Juan Salvador Pérez García 3c3f60dfcc Implements #173
Public view for suggested actions as well as resources has been
completelly redesigned.

Private side for this feature has been adapted as well in order to meet
the requirements.
2018-07-17 17:58:22 +02:00

23 lines
752 B
Plaintext

<div class="links-list">
<%= f.hidden_field :id %>
<%= f.label :links, t('.title') %>
<p class="help-text"><%= t('.note') %></p>
<div id="nested-links">
<%= f.fields_for :links do |links_builder| %>
<%= render 'links/link_fields', f: links_builder %>
<% end %>
</div>
<%= link_to_add_association t('.add_new_link'), f, :links,
partial: 'links/link_fields',
id: 'new_link_button',
class: 'button hollow',
data: {
association_insertion_node: '#nested-links',
association_insertion_method: 'append'
} %>
</div>