Sha256: d41d4f30eef1877cea6487357f7a558bc607fd4484795e63a537bd8708ac8d65
Contents?: true
Size: 1.21 KB
Versions: 35
Compression:
Stored size: 1.21 KB
Contents
module Effective module EffectiveDatatable module Hooks # Called on the final collection after searching, ordering, arrayizing and formatting have been completed def finalize(collection) # Override me if you like collection end # Override this function to perform custom searching on a column def search_column(collection, table_column, search_term, sql_column_or_array_index) if table_column[:array_column] array_tool.search_column_with_defaults(collection, table_column, search_term, sql_column_or_array_index) else table_tool.search_column_with_defaults(collection, table_column, search_term, sql_column_or_array_index) end end # Override this function to perform custom ordering on a column # direction will be :asc or :desc def order_column(collection, table_column, direction, sql_column_or_array_index) if table_column[:array_column] array_tool.order_column_with_defaults(collection, table_column, direction, sql_column_or_array_index) else table_tool.order_column_with_defaults(collection, table_column, direction, sql_column_or_array_index) end end end end end
Version data entries
35 entries across 35 versions & 1 rubygems