dcrec1 / acts_as_solr_reloaded

ActsAsSolr with new features
http://www.diegocarrion.com
MIT License
102 stars 30 forks source link

Providing a an Overrideable Scope for ActsAsSolrReloaded #24

Closed jumph4x closed 12 years ago

jumph4x commented 12 years ago

As a part of the acts_methods.rb I say we define a scope onto the calling model to thats a placeholder. Something along the lines of:

scope :default_acts_as_solr_scope, scoped

End consumer of the gem would then be able to decorate the same scope with all sorts of where clauses and includes clauses for perfomance gains by means of scoping only the relevant collections, as well as optimizing with eager loading.

Performance potential: huge. Methinks any good enough size project warrants this. This is one of many reason I maintain a fork of my own.

Will attach a clean pull request.

dcrec1 commented 12 years ago

Ok, cool, will wait for it.