ModelDiscounts module
BaseAction
Action
A model in the Discounts module, with 19 members for templates, 16 API properties and 19 members for admin templates.
Templates view
Properties 19
Take no arguments.
-
#
getSnakeType() -
string - Returns the type of condition in the snake case format: lowercase and connected by underline
-
#
getSlugType() -
string - Returns the type of condition in the slug format: lowercase and connected by hyphen
-
#
getId() -
?int -
#
getName() -
?string -
#
getValue() -
?string -
#
getModifier() -
?string -
#
isWaterfall() -
bool - When
trueevery following discount applies to the previously discounted price, whenfalsediscount is applied to the original item price -
#
getData() -
?array -
#
getCurrency() -
?Currency - Only applies to fixed-amount (
$) actions. When set, the action is only applied when the cart currency matches. When not set, the default site currency is assumed. Percentage (%) actions always apply regardless of currency. -
#
isHierarchicalModel()Not in API & Jobs -
bool - Check whether a model is a hierarchical model, i.e. can have children
No members match the filter.
API & Jobs view
API & JobsEach property is a key in REST API responses and job payloads. Its name is the template getter without get, is or has. Methods that need arguments are not available here.
Properties 16
Read-only values on the record.
-
#
snakeType -
string - Returns the type of condition in the snake case format: lowercase and connected by underline
-
#
slugType -
string - Returns the type of condition in the slug format: lowercase and connected by hyphen
-
#
id -
?int -
#
name -
?string -
#
value -
?string -
#
modifier -
?string -
#
waterfall -
bool - When
trueevery following discount applies to the previously discounted price, whenfalsediscount is applied to the original item price -
#
data -
?array
No members match the filter.
Admin view
AdminAvailable in cdna-admin templates. Copy an admin template into your site repository to change how this record is edited.
Properties 19
Take no arguments.
-
#
getSnakeType() -
string - Returns the type of condition in the snake case format: lowercase and connected by underline
-
#
getSlugType() -
string - Returns the type of condition in the slug format: lowercase and connected by hyphen
-
#
getId() -
?int -
#
getName() -
?string -
#
getValue() -
?string -
#
getModifier() -
?string -
#
isWaterfall() -
bool - When
trueevery following discount applies to the previously discounted price, whenfalsediscount is applied to the original item price -
#
getData() -
?array -
#
getCurrency() -
?Currency - Only applies to fixed-amount (
$) actions. When set, the action is only applied when the cart currency matches. When not set, the default site currency is assumed. Percentage (%) actions always apply regardless of currency. -
#
isHierarchicalModel()Not in API & Jobs -
bool - Check whether a model is a hierarchical model, i.e. can have children
No members match the filter.