Sha256: ad5e4bd12c6c999277fdffa1e4689b57eb3c7274063d59c1034505b51e2950a3

Contents?: true

Size: 1.87 KB

Versions: 1

Compression:

Stored size: 1.87 KB

Contents

<% content_for :header do %>
  <div class="main-header--buttons">
    <%= link_to "<i class=\"fa fa-plus\" aria-hidden=\"true\"></i> New #{ @structure.name.humanize.split.map(&:capitalize).join(' ') }".html_safe, new_structure_component_path , class: 'main-header--link b-btn b-btn-primary' %>
  </div>

  <p class="main-header--title"><%= t('binda.sort').capitalize %> <%= @structure.name.humanize.split.map(&:capitalize).join(' ').pluralize %></p>
  <a href="<%= structure_components_path %>" class="main-header--back"><span class="glyphicon glyphicon-list"></span> <%= "#{ t :back_to_index }".capitalize %></a>
<% end %>

<% content_for :content do %>

  <%= render 'layouts/binda/popup_warning' %>

  <div class="main-sortable-table">

    <div class="main-sortable-table--header-row">
      <div class="main-sortable-table--header-title"><p>Title</p></div>
      <div class="main-sortable-table--header-title"><p>Publish State</p></div>
    </div>

    <div id="<%= @structure.slug %>-components--sort-index" class="sortable" data-update-url="<%= structure_components_sort_path( @structure.slug ) %>" data-message="<%= t 'binda.sort_items_loader', { arg1: t('binda.components').downcase } %>">
      <% @components.order( :position, :name ).each do |component| %>
        <div class="main-sortable-table--row ui-sortable-handle" id="component_<%= component.id %>">
          <div class="main-sortable-table--row-cell"><%= link_to component.name, structure_component_path( @structure.slug, component ) %></div>
          <div class="main-sortable-table--row-cell"><%= component.publish_state %></div>
        </div>
      <% end %>
    </div>

  </div>

  <%= link_to "<i class=\"fa fa-plus\" aria-hidden=\"true\"></i> New #{ @structure.name.humanize.split.map(&:capitalize).join(' ') }".html_safe, new_structure_component_path, class: 'main-header--link b-btn b-btn-primary', action: "new" %>


<% end %>

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
binda-0.1.3 app/views/binda/components/sort_index.html.erb