Module: PlainQuery::Base
- Defined in:
- lib/plain_query.rb
Overview
Realises methods for scope building by execution of sequence of steps Query class defines query steps: query_step :filter_by_status, if: -> { options.present? }
def filter_by_status
relation.where(status: [:status])
end
Class Method Summary collapse
Class Method Details
.included(klass) ⇒ Object
14 15 16 |
# File 'lib/plain_query.rb', line 14 def self.included(klass) klass.include(PlainQuery::Base()) end |