Sha256: e69912245999b47b0e73e211d670365307c36b7f68f60e58e2a3f04a58e934cb

Contents?: true

Size: 1.72 KB

Versions: 5

Compression:

Stored size: 1.72 KB

Contents

  <fieldset class="form_container">
    <%= legend_tag 'Summary' -%>
    <div class="form_column">
      <%= f.text_field :headline, :label => 'Term' -%>
    </div>
    <div class="form_column">
      <%= f.text_field :desired_slug, :value => @managed_content.slug, :help => "The slug is the portion of the URL that refers directly to this term. The full URL will consist of the slug for the managed content section plus what you enter below, e.g. /#{@publication.slug}/#{@managed_content.slug || 'foo'}/" -%>
      <%= f.select :state, ManagedContent::STATES.map{|s| s.capitalize} -%>
    </div>
    <br style="clear: both;" />
    <label>Definition</label><br />
    <%= f.cktext_area :content, :toolbar => 'Full', :width => '900px' -%>
  </fieldset>

  <fieldset class="form_container">
    <%= legend_tag 'References' -%>
    <%= f.cktext_area :references, :toolbar => 'Full', :width => '900px' -%>
  </fieldset>

  <fieldset class="form_container">
    <%= legend_tag 'Related Terms' -%>
    <%- @publication.managed_contents.reject{|c| c == @managed_content}.sort{|a,b| a.headline <=> b.headline}.in_groups(2, false) do |column| -%>
      <div class="form_column">
        <%- column.each do |content| -%>
          <fieldset>
            <%= check_box "managed_content", "managed_content_related_content[]", {:checked =>  @managed_content.related_content.include?(content), :name => "managed_content[related_content][]"}, content.id, nil -%>
            <%= content.headline -%>
          </fieldset>
        <%- end -%>
      </div>
    <%- end -%>
    <div class="link_block">
      <%= f.submit 'Save', :class => 'link_button' -%>
      <%= link_to 'Cancel', admin_publication_path(@publication), :class => 'link_button' -%>
    </div>
  </fieldset>

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
editorial_logic-1.3.3 app/views/admin/managed_contents/_term_fields.html.erb
editorial_logic-1.3.2 app/views/admin/managed_contents/_term_fields.html.erb
editorial_logic-1.3.1 app/views/admin/managed_contents/_term_fields.html.erb
editorial_logic-1.3.0 app/views/admin/managed_contents/_term_fields.html.erb
editorial_logic-1.1.6 app/views/admin/managed_contents/_term_fields.html.erb