Class: Fera::Product

Inherits:
Base
  • Object
show all
Includes:
HasManyReviews, HasMedia
Defined in:
lib/fera/models/product.rb

Instance Attribute Summary

Attributes inherited from Base

#last_response, #last_response_body, #last_response_exception, #last_response_message, #options

Class Method Summary collapse

Methods included from HasMedia

#add_media, #add_photo, #add_video, #media, #media=, #new_media, #new_photo, #new_video, #photos, #photos=, #videos, #videos=

Methods included from HasManyReviews

#reviews, #reviews=

Methods inherited from Base

api_key, api_key=, belongs_to, belongs_tos, #clone_selected_fields, #clone_with_nil, #create, create, #create!, create!, #created_at=, #destroy!, find_every, find_one, find_single, has_many, has_manys, has_one, has_ones, headers, headers=, #initialize, #known_attribute?, #load, #method_missing, new_element_path, order, #respond_to_missing?, #save, #save!, #set_last_response, #update, #update!, #updated_at=, #valid?

Constructor Details

This class inherits a constructor from Fera::Base

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Fera::Base

Class Method Details

.ratings(query = {}) ⇒ Object



8
9
10
# File 'lib/fera/models/product.rb', line 8

def self.ratings(query = {})
  ProductRating.where(query)
end