Class: Spree::Menus::Find

Inherits:
BaseFinder show all
Defined in:
app/finders/spree/menus/find.rb

Instance Attribute Summary

Attributes inherited from BaseFinder

#params, #scope

Instance Method Summary collapse

Methods inherited from BaseFinder

#initialize

Constructor Details

This class inherits a constructor from Spree::BaseFinder

Instance Method Details

#executeObject



4
5
6
7
8
# File 'app/finders/spree/menus/find.rb', line 4

def execute
  return scope.where(location: params[:filter]['location']) if params[:filter].present? && params[:filter]['location'].present?

  scope
end