Sha256: 2b04253cf35de8d392ec824d6e06b634aa031721f6fa94351c3ac64bc4988871
Contents?: true
Size: 1.8 KB
Versions: 1
Compression:
Stored size: 1.8 KB
Contents
<%- model_class = @content.class; @ancestry = @content.ancestry -%> <div class="page-header"> <h3><%=t '.title', :default => t('helpers.titles.define', :model => model_class.model_name.human, :default => "Edit #{@content.slug or model_class.model_name.human}") %></h3> </div> <%= form_for @content, :html => { :class => 'form-horizontal' } do |f| %> <% if @content.errors.any? %> <div class="errors"> <h3>ERROR!</h3> <ul> <% @content.errors.full_messages.each do |msg| %> <%= content_tag :li, msg %> <% end %> </ul> </div> <% end %> <%= render :partial => 'fields_new', :locals => {f: f} %> <%= render :partial => 'fields_edit', :locals => {f: f} %> <hr/> <%= link_to_add_fields "+ seo", f, :seo unless @content.seo %> <%= f.fields_for :seo do |seo| %> <%= render :partial => 'seo_fields', :locals => {f: seo} %> <% end %> <h4>Resources</h4> <%= link_to_add_fields "Add Resource", f, :resources, '#resources' %> <div id="resources"> <%= f.fields_for :resources do |res| %> <%= render :partial => 'resource_fields', :locals => {f: res} %> <% end %> </div> <h4>Children</h4> <%= f.hidden_field :child_order %> <%= link_to_add_fields "Add Child", f, :child_contents, '#children' %> <div id="children"> <%= f.fields_for :child_contents do |child| %> <%= render :partial => 'child_content_fields', :locals => {f: child} %> <% end %> </div> <div class="form-actions"> <%= f.submit nil, :class => 'btn btn-primary' %> <%= link_to t('.cancel', :default => t("helpers.links.cancel")), contents_path, :class => 'btn' %> </div> <% end %> <% content_for :breadcrumb do %> <%= content_tag :anchor, @content.ancestry %> <% end %>
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
common-content-0.0.5 | app/views/contents/edit.html.erb |