Method: TableMe::Column#initialize
- Defined in:
- lib/table_me/column.rb
#initialize(column_name, args = {}, &block) ⇒ Column
Returns a new instance of Column.
8 9 10 11 12 13 14 15 16 17 |
# File 'lib/table_me/column.rb', line 8 def initialize column_name, args = {}, &block self.name = column_name self.content = block if block self.sortable = args[:sort_on] else self.sortable = column_name end end |