Skip to content

Instantly share code, notes, and snippets.

View tlueker's full-sized avatar

Tom Lueker tlueker

  • Williamsburg, VA
View GitHub Profile
@tlueker
tlueker / active_admin.rb
Last active March 30, 2017 18:10 — forked from tinynumbers/active_admin.rb
ActiveAdmin controller extension to persist resource index filters between requests.
# this stuff goes in config/initializers/active_admin.rb
ActiveAdmin.setup do |config|
# ...
# put these lines in the "Controller Filters" section of the ActiveAdmin.setup block
# These two are defined in ActiveAdmin::FilterSaver::Controller, which is loaded below.
config.before_filter :restore_search_filters