Method: JsonApiClient::Query::Builder#where

Defined in:
lib/json_api_client/query/builder.rb

#where(conditions = {}) ⇒ Object



22
23
24
25
26
27
28
# File 'lib/json_api_client/query/builder.rb', line 22

def where(conditions = {})
  # pull out any path params here
  path_conditions = conditions.slice(*klass.prefix_params)
  unpathed_conditions = conditions.except(*klass.prefix_params)

  _new_scope( path_params: path_conditions, filters: unpathed_conditions )
end