Sha256: 8021b4c9bcdba454dba20a0779a46f25b1c62a79c3bea7c5428bb484b34653fd

Contents?: true

Size: 372 Bytes

Versions: 2

Compression:

Stored size: 372 Bytes

Contents

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

    params[:user_id] = try_spree_current_user.id if try_spree_current_user
    @searcher = Spree::Config.searcher_class.new(params.merge(:taxon => @taxon.id))
    @products = @searcher.retrieve_products

    respond_with(@taxon)
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
spree_restriction-1.2.4 app/controllers/taxons_controller_decorator.rb
spree_restriction-1.2.3 app/controllers/taxons_controller_decorator.rb