<% content_for :content do %>
<% if @collection.num_pages < 2 %> <% if @collection.size == 0 %> No <%= @interface.collection.titleize %> found <% elsif @collection.size == 1 %> Displaying 1 <%= @interface.member.titleize %> <% else %> Displaying all <%= @collection.size %> <%= @interface.collection.titleize %> <% end %> <% else %> Displaying <%= @interface.collection.titleize %> <%= (@collection.current_page * SimpleAdmin.default_per_page) - SimpleAdmin.default_per_page + 1 %> - <%= (@collection.current_page * SimpleAdmin.default_per_page) > @collection.total_count ? @collection.total_count : (@collection.current_page * SimpleAdmin.default_per_page) %> of <%= @collection.total_count %> in total <% end %>
<% @interface.attributes_for(:index).each do |col| %> <% end %> <% @collection.each do |object| %> <% @interface.attributes_for(:index).each do |col| %> <% end %> <% end %>
<%= link_to(col.title, request.query_parameters.merge(:order => "#{col.sort_key}_#{order_for_sort_key(col.sort_key)}").except(:page)) %>  
<% if col.data %> <%= col.data.call(object, col) %> <% else %> <%= pretty_format(object.send(col.attribute)) %> <% end %> <%= resource_actions(object) %>
<%= paginate(@collection) %>
<% end %> <% content_for :sidebar do %> <%= sidebars %> <% end %>