Notice_Helper
in package
Quantity Step
Tags
Table of Contents
- get_add_to_cart_notice() : mixed
- get_cart_notice() : mixed
- get_add_to_cart_value_string() : string
- Gets the add to cart message value string
- get_comparison_string() : string
- Gets the comparison string for the error message
- get_object_name() : string
- Gets the appropriate object name for an error message
- get_quantity_comparison_string() : string
- Gets the quantity comparison string for quantity rules
- get_unit_string() : string
- Gets the unit string for the rule level
- get_value_comparison_string() : string
- Gets the value comparison string for value rules
Methods
get_add_to_cart_notice()
public
static get_add_to_cart_notice(Cart_Validation $validation, mixed $quantity) : mixed
Parameters
- $validation : Cart_Validation
- $quantity : mixed
Return values
mixed —get_cart_notice()
public
static get_cart_notice(Cart_Validation $validation) : mixed
Parameters
- $validation : Cart_Validation
Return values
mixed —get_add_to_cart_value_string()
Gets the add to cart message value string
private
static get_add_to_cart_value_string(Cart_Validation $validation) : string
Parameters
- $validation : Cart_Validation
Return values
string —get_comparison_string()
Gets the comparison string for the error message
private
static get_comparison_string(Cart_Validation $validation) : string
Parameters
- $validation : Cart_Validation
Return values
string —get_object_name()
Gets the appropriate object name for an error message
private
static get_object_name(Cart_Validation $validation) : string
Parameters
- $validation : Cart_Validation
Return values
string —get_quantity_comparison_string()
Gets the quantity comparison string for quantity rules
private
static get_quantity_comparison_string(string $rule_level, mixed $rule_value) : string
Parameters
- $rule_level : string
- $rule_value : mixed
Return values
string —get_unit_string()
Gets the unit string for the rule level
private
static get_unit_string(string $rule_level) : string
Parameters
- $rule_level : string
Return values
string —get_value_comparison_string()
Gets the value comparison string for value rules
private
static get_value_comparison_string(array<string|int, mixed> $rule_value) : string
Parameters
- $rule_value : array<string|int, mixed>