Skip to content

Instantly share code, notes, and snippets.

@russ
Created January 7, 2009 17:07
Show Gist options
  • Save russ/44335 to your computer and use it in GitHub Desktop.
Save russ/44335 to your computer and use it in GitHub Desktop.
class Admin::SearchesController < AdminController
def index
end
def show
@customers = case params[:query]
when 'customer': Search.find_customers(params[:value])
when 'product': Search.find_customers_from_sku(params[:value])
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment