<table class="table table-hover text-center shixuns-list-table">
  <thead class="thead-light">
  <th width="4%">序号</th>
  <th width="8%">ID</th>
  <th width="32%" class="text-left">实训名称</th>
  <th width="16%">子站源</th>
  <th width="10%">创建者</th>
  <th width="20%"><%= sort_tag('创建于', name: 'created_at', path: admins_shixun_recycles_path) %></th>
  <th width="10%">操作</th>
  </thead>
  <tbody>
  <% if shixuns.present? %>
    <% shixuns.each_with_index do |shixun, index| %>
      <tr id="shixun_recycle_item_<%= shixun.id %>">
        <td><%= list_index_no((params[:page] || 1).to_i, index) %></td>
        <td><%= shixun.identifier %></td>
        <td class="text-left"><span><%= link_to overflow_hidden_span(shixun.name), "/shixuns/#{shixun.identifier}", :target => "_blank", :title => shixun.name %></span></td>
        <td><%= shixun.laboratory&.school&.name %></td>
        <td><%= link_to shixun.user.try(:real_name),"/users/#{shixun.user.try(:login)}",target:'_blank' %></td>
        <td><%= format_time shixun.created_at %></td>
        <td class="operate">
          <%= delete_link '删除', admins_shixun_recycle_path(shixun, element: ".shixun-recycle-item-#{shixun.id}"), class: 'delete-shixun-recyle-action' %>
          <%= link_to('恢复', resume_admins_shixun_recycle_path(shixun), :method => :post, :remote => true, :data => { confirm: "您确定要恢复吗？" } ) %>
        </td>
      </tr>
    <% end %>
  <% else %>
    <%= render 'admins/shared/no_data_for_table' %>
  <% end %>
  </tbody>
</table>

<%= render partial: 'admins/shared/paginate', locals: { objects: shixuns } %>