Class: WinewooCore::Repositories::Mongo::CriterionsMongoRepo::GrapesFinder
- Inherits:
-
Finder
- Object
- Finder
- WinewooCore::Repositories::Mongo::CriterionsMongoRepo::GrapesFinder
- Defined in:
- lib/winewoo_core/repositories/mongo/criterions_mongo_repo.rb
Instance Method Summary collapse
Methods inherited from Finder
Constructor Details
This class inherits a constructor from WinewooCore::Repositories::Mongo::CriterionsMongoRepo::Finder
Instance Method Details
#find ⇒ Object
114 115 116 117 118 119 |
# File 'lib/winewoo_core/repositories/mongo/criterions_mongo_repo.rb', line 114 def find res = GlobalWineData.all.first.grapes return @filters.query ? res.select{ |grape| grape.match(/^(#{@filters.query})/i) } : res end |