Sha256: 4652b82e82ee4e2d1dd3fc39bf2c974c8f4d8114ff1235c043f66cc5d58e67df
Contents?: true
Size: 1.41 KB
Versions: 7
Compression:
Stored size: 1.41 KB
Contents
- if tmpl = admin_partial_name(table_builder) = render tmpl - else table.table.table-striped.index_table#list thead tr.pjax_links = batch_action_toggle th= sort_link(@search, :id) - table_builder.fields.each do |field| th - if field.options[:sortable] && !field.options[:image] - if field.options[:sortable].is_a?(TrueClass) = sort_link @search, field.name - else - opts = field.options[:sortable].is_a?(Hash) ? field.options[:sortable] : {column: field.options[:sortable]} = sort_link @search, field.name, opts - else = field.name.is_a?(Symbol) ? ha(field.name) : field.name th=t 'admin.table.actions' tbody - is_edit_link = manager.actions.include?(:edit) - collection.each do |item| tr id=dom_id(item, 'list') = batch_action_item(item) td= id_link(item, is_edit_link) - table_builder.fields.each do |field| td - if field.options[:editable] && field.data.is_a?(Symbol) = admin_editable item, field.data, field.options[:editable] - elsif field.options[:image] = item_image_link(item, assoc: field.name) - else = admin_pretty_data call_method_or_proc_on(item, field.data) td.actions= item_index_actions(item)
Version data entries
7 entries across 7 versions & 1 rubygems