Class: Google::Apis::ContentV2_1::RepricingRuleCostOfGoodsSaleRule

Inherits:
Object
  • Object
show all
Includes:
Google::Apis::Core::Hashable, Google::Apis::Core::JsonObjectSupport
Defined in:
lib/google/apis/content_v2_1/classes.rb,
lib/google/apis/content_v2_1/representations.rb,
lib/google/apis/content_v2_1/representations.rb

Overview

A repricing rule that changes the sale price based on cost of goods sale.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ RepricingRuleCostOfGoodsSaleRule

Returns a new instance of RepricingRuleCostOfGoodsSaleRule.



12447
12448
12449
# File 'lib/google/apis/content_v2_1/classes.rb', line 12447

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#percentage_deltaFixnum

The percent change against the COGS. Ex: 20 would mean to set the adjusted price 1.2X of the COGS data. Corresponds to the JSON property percentageDelta

Returns:

  • (Fixnum)


12440
12441
12442
# File 'lib/google/apis/content_v2_1/classes.rb', line 12440

def percentage_delta
  @percentage_delta
end

#price_deltaString

The price delta against the COGS. E.g. 2 means $2 more of the COGS. Corresponds to the JSON property priceDelta

Returns:

  • (String)


12445
12446
12447
# File 'lib/google/apis/content_v2_1/classes.rb', line 12445

def price_delta
  @price_delta
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



12452
12453
12454
12455
# File 'lib/google/apis/content_v2_1/classes.rb', line 12452

def update!(**args)
  @percentage_delta = args[:percentage_delta] if args.key?(:percentage_delta)
  @price_delta = args[:price_delta] if args.key?(:price_delta)
end