Sha256: 33897b2780d6247230a2851be83d28fa511fd0266810177736e76ba780246462
Contents?: true
Size: 671 Bytes
Versions: 1
Compression:
Stored size: 671 Bytes
Contents
module Economic class PricingRepo < Economic::ProductRepo def self.currency_specific_sales_prices_for(product_or_produduct_number) entry_number = product_or_produduct_number entry_number = entry_number.product_number if entry_number.class.method_defined? :product_number end_point = [superclass.endpoint_url, entry_number, 'pricing', 'currency-specific-sales-prices'].join('/') response = test_response(RestClient.get(end_point, headers)) entry_hash = JSON.parse(response.body) pricings = [] entry_hash['collection'].each do |pricing| pricings.push Pricing.new(pricing) end pricings end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
economic-rest-0.2.8 | lib/economic/pricing_repo.rb |