Class: TableSettings::CustomColumn
- Inherits:
-
Column
- Object
- Column
- TableSettings::CustomColumn
show all
- Defined in:
- lib/table_settings/table_column.rb
Instance Attribute Summary
Attributes inherited from Column
#index
Instance Method Summary
collapse
Methods inherited from Column
#column_hash, #css_class, #css_header_class, #editable, #filter_data, #filter_type, #format_method, #global_format_method, #initialize, #max_text_length, #non_breakable, #sql_expression, #summarize_all, #summarize_page
Instance Method Details
#callback_class(name) ⇒ Object
140
141
142
143
|
# File 'lib/table_settings/table_column.rb', line 140
def callback_class(name)
@column_hash[:column_class] = name
self
end
|
#callback_method(name) ⇒ Object
136
137
138
139
|
# File 'lib/table_settings/table_column.rb', line 136
def callback_method(name)
@column_hash[:column_method] = name
self
end
|
#callback_params(params) ⇒ Object
131
132
133
134
|
# File 'lib/table_settings/table_column.rb', line 131
def callback_params(params)
@column_hash[:column_params] = params
self
end
|
#params(name, label, column_method, column_class = nil, column_params = nil) ⇒ Object
118
119
120
121
122
123
124
125
126
127
128
129
130
|
# File 'lib/table_settings/table_column.rb', line 118
def params( name, label, column_method, column_class = nil, column_params = nil)
@column_hash = {
:name => name,
:label => label,
:column_method => column_method,
:filter => :none
}
@column_hash[:column_class] = column_class unless column_class.nil?
@column_hash[:column_params] = column_params unless column_params.nil?
self
end
|