Sha256: 92a7c4d42ae1982be026961576e5d711aa715408225d0cb95f00377a59e59545
Contents?: true
Size: 1.2 KB
Versions: 3
Compression:
Stored size: 1.2 KB
Contents
<% content_for :table_headers do %> <thead> <tr> <% if controller.respond_to?(:bulk) %> <th><%= check_box_tag "action-toggle", "", false, :class => "action-toggle" %></th> <% end %> <% headers.each do |header| %> <th><%= header %></th> <% end %> </tr> </thead> <% end %> <table> <%= yield :table_headers %> <% items.each do |item| %> <tr class="<%= cycle('even', 'odd') %>" id="<%= dom_id(item) %>"> <% if controller.respond_to?(:bulk) %> <td width="16"> <%= check_box_tag "selected_item_ids[]", item.id, false, :class => "action-select" %> </td> <% end %> <% table_fields_for_item(item, fields).each_with_index do |field, index| %> <td> <%= field %> <% if index.zero? %> <div class="actions"> <% table_actions(model, item, association_name).each_with_index do |action, index| %> <%= "/" unless index.zero? %> <%= link_to action[:message], action[:url], action[:options] %> <% end %> </div> <% end %> </td> <% end %> </tr> <% end %> <%= yield :table_headers %> </table>
Version data entries
3 entries across 3 versions & 1 rubygems