Sha256: 2fdb19d039c0161e855770d33f57ac2e516293cf51ede038090a0aecf5278f7b
Contents?: true
Size: 873 Bytes
Versions: 13
Compression:
Stored size: 873 Bytes
Contents
# frozen_string_literal: true module IronBank module Resources # A product rate plan belongs to a product and holds many product rate plan # charges. It represents what a customer is subscribing to. # class ProductRatePlan < Resource # Zuora limitation: we cannot query for `ActiveCurrencies` with any other # fields, so instead we define a separate `#active_currencies` method. def self.exclude_fields %w[ActiveCurrencies] end with_schema with_local_records with_cache with_one :product with_many :product_rate_plan_charges, alias: :charges def active_currencies query_string = IronBank::QueryBuilder.zoql( self.class.object_name, ["ActiveCurrencies"], id: id ) IronBank.client.query(query_string) end end end end
Version data entries
13 entries across 13 versions & 1 rubygems