lib/acts_as_data_table/shared/session.rb
#
# Checks whether the given filter is currently active
# Note that it also checks if it is active with exactly the given arguments.
#
# @return [TrueClass, FalseClass] +true+ if the filter is active AND
#   the given +args+ match the ones used in the filter.
#
Checks whether the given filter is currently active
Note that it also checks if it is active with exactly the given arguments.
Checks whether the given filter is currently active Note that it also checks if it is active with exactly the given arguments .
def active_filter?(group, scope, args)
          args ||= {}
          used_args = Acts::DataTable.lookup_nested_hash(active_filters, group.to_s, scope.to_s)
          used_args && (args.stringify_keys.to_a - used_args.to_a).empty?
        end
def active_filter? ( group , scope , args ) args ||= { } used_args = Acts :: DataTable . lookup_nested_hash ( active_filters , group . to_s , scope . to_s ) used_args && ( args . stringify_keys . to_a - used_args . to_a ) . empty? end
Checks whether the given filter is currently active
Note that it also checks if it is active with exactly the given arguments.
Checks whether the given filter is currently active Note that it also checks if it is active with exactly the given arguments .
+true+ if the filter is active AND the given +args+ match the ones used in the filter.
+ true + if the filter is active AND the given + args + match the ones used in the filter .
TrueClass, FalseClass
group
scope
args