Revision 9e1b7578
Added by Marek Hulán over 10 years ago
app/controllers/application_controller.rb | ||
---|---|---|
before_filter :welcome, :only => :index, :unless => :api_request?
|
||
before_filter :authorize
|
||
|
||
attr_reader :original_search_parameter
|
||
|
||
cache_sweeper :topbar_sweeper
|
||
|
||
def welcome
|
||
... | ... | |
# it automatically updates the search text box with the relevant relationship
|
||
# e.g. /hosts/fqdn/reports # would add host = fqdn to the search bar
|
||
def setup_search_options
|
||
@original_search_parameter = params[:search]
|
||
params[:search] ||= ""
|
||
params.keys.each do |param|
|
||
if param =~ /(\w+)_id$/
|
Also available in: Unified diff
fixes #3339 - nested fact support, allow fact importers to be registered by plugins