lib/table_object/base_extension.rb
# Creates a column and stores it in the columns attribute
Creates a column and stores it in the columns attribute
Creates a column and stores it in the columns attribute
def column(name, options = {})
    options[:path] = default_path unless options[:path].present?
    options[:type] = find_type_for(name) unless options[:type].present?
    options[:label] = find_label_for(name) unless options[:label].present?
    column = TableObject::Column.new(name, options)
    columns << column
    column
  end
def column ( name , options = { } ) options [ :path ] = default_path unless options [ :path ] . present? options [ :type ] = find_type_for ( name ) unless options [ :type ] . present? options [ :label ] = find_label_for ( name ) unless options [ :label ] . present? column = TableObject :: Column . new ( name , options ) columns << column column end
Creates a column and stores it in the columns attribute
Creates a column and stores it in the columns attribute
name
<not_specific>
options
<not_specific>