Module: Pageflow::ActiveAdminPatches::Views::TableFor Private
- Defined in:
- lib/pageflow/active_admin_patches/views/table_for.rb
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Instance Method Summary collapse
- #boolean_status_tag_column(name, yes_state = :warning) ⇒ Object private
- #row_attributes ⇒ Object private
Instance Method Details
#boolean_status_tag_column(name, yes_state = :warning) ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
17 18 19 20 21 |
# File 'lib/pageflow/active_admin_patches/views/table_for.rb', line 17 def boolean_status_tag_column(name, yes_state = :warning) status_tag_column(name, [I18n.t('active_admin.status_tag.yes'), '-'], [yes_state, nil]) end |
#row_attributes ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
6 7 8 9 10 11 12 13 14 15 |
# File 'lib/pageflow/active_admin_patches/views/table_for.rb', line 6 def row_attributes @collection.each_with_index do |item, i| tr = @tbody.children[i] attributes = yield(item) attributes[:class] = [tr.attributes[:class], attributes[:class]].compact.join(' ') tr.attributes.merge!(attributes) end end |