Class: Orb::Models::PercentageDiscountInterval
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- Orb::Models::PercentageDiscountInterval
- Defined in:
- lib/orb/models/percentage_discount_interval.rb
Defined Under Namespace
Modules: DiscountType
Instance Attribute Summary collapse
-
#applies_to_price_interval_ids ⇒ Array<String>
The price interval ids that this discount interval applies to.
- #discount_type ⇒ Symbol, Orb::Models::PercentageDiscountInterval::DiscountType
-
#end_date ⇒ Time?
The end date of the discount interval.
-
#filters ⇒ Array<Orb::Models::TransformPriceFilter>
The filters that determine which prices this discount interval applies to.
-
#percentage_discount ⇒ Float
Only available if discount_type is ‘percentage`.This is a number between 0 and 1.
-
#start_date ⇒ Time
The start date of the discount interval.
Instance Method Summary collapse
-
#initialize(applies_to_price_interval_ids: , discount_type: , end_date: , filters: , percentage_discount: , start_date: ) ⇒ Object
constructor
Some parameter documentations has been truncated, see PercentageDiscountInterval for more details.
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(applies_to_price_interval_ids: , discount_type: , end_date: , filters: , percentage_discount: , start_date: ) ⇒ Object
Some parameter documentations has been truncated, see Orb::Models::PercentageDiscountInterval for more details.
|
|
# File 'lib/orb/models/percentage_discount_interval.rb', line 42
|
Instance Attribute Details
#applies_to_price_interval_ids ⇒ Array<String>
The price interval ids that this discount interval applies to.
10 |
# File 'lib/orb/models/percentage_discount_interval.rb', line 10 required :applies_to_price_interval_ids, Orb::Internal::Type::ArrayOf[String] |
#discount_type ⇒ Symbol, Orb::Models::PercentageDiscountInterval::DiscountType
15 |
# File 'lib/orb/models/percentage_discount_interval.rb', line 15 required :discount_type, enum: -> { Orb::PercentageDiscountInterval::DiscountType } |
#end_date ⇒ Time?
The end date of the discount interval.
21 |
# File 'lib/orb/models/percentage_discount_interval.rb', line 21 required :end_date, Time, nil?: true |
#filters ⇒ Array<Orb::Models::TransformPriceFilter>
The filters that determine which prices this discount interval applies to.
27 |
# File 'lib/orb/models/percentage_discount_interval.rb', line 27 required :filters, -> { Orb::Internal::Type::ArrayOf[Orb::TransformPriceFilter] } |
#percentage_discount ⇒ Float
Only available if discount_type is ‘percentage`.This is a number between 0 and 1.
34 |
# File 'lib/orb/models/percentage_discount_interval.rb', line 34 required :percentage_discount, Float |
#start_date ⇒ Time
The start date of the discount interval.
40 |
# File 'lib/orb/models/percentage_discount_interval.rb', line 40 required :start_date, Time |