Module: ThinkingSphinx::ActiveRecord::HasManyAssociationWithScopes

Defined in:
lib/thinking_sphinx/active_record/has_many_association_with_scopes.rb

Instance Method Summary collapse

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(method, *args, &block) ⇒ Object



4
5
6
7
8
9
10
11
12
# File 'lib/thinking_sphinx/active_record/has_many_association_with_scopes.rb', line 4

def method_missing(method, *args, &block)
  if responds_to_scope(method)
    @reflection.klass.
      search(:with => default_filter).
      send(method, *args, &block)
  else
    super
  end
end