Class: TaxonsController

Inherits:
Spree::BaseController show all
Defined in:
app/controllers/taxons_controller.rb

Instance Method Summary collapse

Methods included from SpreeBase

included

Methods inherited from ActionController::Base

#respond_with

Instance Method Details

#showObject



7
8
9
10
11
12
13
14
15
# File 'app/controllers/taxons_controller.rb', line 7

def show
  @taxon = Taxon.find_by_permalink!(params[:id])
  return unless @taxon

  @searcher = Spree::Config.searcher_class.new(params.merge(:taxon => @taxon.id))
  @products = @searcher.retrieve_products

  respond_with(@taxon)
end