Name | Type | Description | Notes |
---|---|---|---|
Type | string | The type of discount | |
Cap | Pointer to float64 | The maximum discount dollar amount. It is not required and will be ignored when the `discount.type` is: - `net` - `delivery` - `freeItem` - `bundleSameNet` - `bundleSamePercentage` - `bundleSameFixPrice` - `bundleDiffNet` - `bundleDiffPercentage` - `bundleDiffFixPrice` | [optional] |
Value | Pointer to float64 | Specify the discount amount. Decimal number is not supported For VN, ID and TH. For example, `10.5` is not allowed and it should be `10.0`. * Dollar amount value when `discount.type` is `net`, `delivery`, `bundleSameNet`, `bundleSameFixPrice`, `bundleDiffNet`, `bundleDiffFixPrice`. * Percentage value (0-100) when `discount.type` is `percentage`, `bundleSamePercentage`, `bundleDiffPercentage`. * Not required when `discount.type` is `freeItem`. | [optional] |
Scope | CampaignScope |
func NewCampaignDiscount(type_ string, scope CampaignScope, ) *CampaignDiscount
NewCampaignDiscount instantiates a new CampaignDiscount object This constructor will assign default values to properties that have it defined, and makes sure properties required by API are set, but the set of arguments will change when the set of required properties is changed
func NewCampaignDiscountWithDefaults() *CampaignDiscount
NewCampaignDiscountWithDefaults instantiates a new CampaignDiscount object This constructor will only assign default values to properties that have it defined, but it doesn't guarantee that properties required by API are set
func (o *CampaignDiscount) GetType() string
GetType returns the Type field if non-nil, zero value otherwise.
func (o *CampaignDiscount) GetTypeOk() (*string, bool)
GetTypeOk returns a tuple with the Type field if it's non-nil, zero value otherwise and a boolean to check if the value has been set.
func (o *CampaignDiscount) SetType(v string)
SetType sets Type field to given value.
func (o *CampaignDiscount) GetCap() float64
GetCap returns the Cap field if non-nil, zero value otherwise.
func (o *CampaignDiscount) GetCapOk() (*float64, bool)
GetCapOk returns a tuple with the Cap field if it's non-nil, zero value otherwise and a boolean to check if the value has been set.
func (o *CampaignDiscount) SetCap(v float64)
SetCap sets Cap field to given value.
func (o *CampaignDiscount) HasCap() bool
HasCap returns a boolean if a field has been set.
func (o *CampaignDiscount) GetValue() float64
GetValue returns the Value field if non-nil, zero value otherwise.
func (o *CampaignDiscount) GetValueOk() (*float64, bool)
GetValueOk returns a tuple with the Value field if it's non-nil, zero value otherwise and a boolean to check if the value has been set.
func (o *CampaignDiscount) SetValue(v float64)
SetValue sets Value field to given value.
func (o *CampaignDiscount) HasValue() bool
HasValue returns a boolean if a field has been set.
func (o *CampaignDiscount) GetScope() CampaignScope
GetScope returns the Scope field if non-nil, zero value otherwise.
func (o *CampaignDiscount) GetScopeOk() (*CampaignScope, bool)
GetScopeOk returns a tuple with the Scope field if it's non-nil, zero value otherwise and a boolean to check if the value has been set.
func (o *CampaignDiscount) SetScope(v CampaignScope)
SetScope sets Scope field to given value.