Class: ShopifyAPI::Customer

Inherits:
Base show all
Includes:
Metafields
Defined in:
lib/shopify_api/resources/customer.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Metafields

#add_metafield, #metafields

Methods inherited from Base

activate_session, #as_json, clear_session, #encode, #headers, init_prefix, init_prefix_explicit, #persisted?

Methods included from Countable

#count

Methods inherited from ActiveResource::Base

delete, headers

Class Method Details

.search(params) ⇒ Object



9
10
11
# File 'lib/shopify_api/resources/customer.rb', line 9

def self.search(params)
  find(:all, from: :search, params: params)
end

Instance Method Details

#ordersObject



5
6
7
# File 'lib/shopify_api/resources/customer.rb', line 5

def orders
  Order.find(:all, params: {customer_id: self.id})
end