<%- model_class = @content.class -%> <%= form_for @content, :html => { :class => 'form-horizontal' } do |f| %> <% if @content.errors.any? %>

ERROR!

<% end %> <%= render :partial => 'fields_new', :locals => {f: f} %> <%= render :partial => 'fields_edit', :locals => {f: f} %>

Seo

<%= f.fields_for :seo do |seo| %> <%= render :partial => 'seo_fields', :locals => {f: seo} %> <% end %>

Resources

<%= link_to_add_fields "Add Resource", f, :resources %> <%= f.fields_for :resources do |res| %> <%= render :partial => 'resource_fields', :locals => {f: res} %> <% end %>

Children

<%= link_to_add_fields "Add Child", f, :child_contents %> <%= render :partial => 'show_children', object: @content.child_contents %>
<%= f.submit nil, :class => 'btn btn-primary' %> <%= link_to t('.cancel', :default => t("helpers.links.cancel")), contents_path, :class => 'btn' %>
<% end %> <% content_for :breadcrumb do %> <%= content_tag :anchor, @content.ancestry %> <% end %>