Properties

$name

$name : string

Type

string — Name

$rate

$rate : float

Type

float — Rate (%)

$active

$active : boolean

Type

boolean — active state

$deleted

$deleted : boolean

Type

boolean — true if the tax has been historized

$definition

$definition : 

Type

$_product_country_tax

$_product_country_tax : 

Type

$_product_tax_via_rules

$_product_tax_via_rules : 

Type

$webserviceParameters

$webserviceParameters : 

Type

Methods

delete()

delete() 

historize()

historize() 

Save the object with the field deleted to true

@return bool

toggleStatus()

toggleStatus() 

update()

update(  $nullValues = false) 

Parameters

$nullValues

isUsed()

isUsed() : boolean

Returns true if the tax is used in an order details

Returns

boolean

getTaxes()

getTaxes(  $id_lang = false,   $active_only = true) : array

Get all available taxes

Parameters

$id_lang
$active_only

Returns

array —

Taxes

excludeTaxeOption()

excludeTaxeOption() 

getTaxIdByName()

getTaxIdByName(string  $tax_name, boolean  $active = 1) 

Return the tax id associated to the specified name

Parameters

string $tax_name
boolean $active

(true by default)

getProductEcotaxRate()

getProductEcotaxRate(  $id_address = null) : float

Returns the ecotax tax rate

Parameters

$id_address

Returns

float —

$tax_rate

getCarrierTaxRate()

getCarrierTaxRate(  $id_carrier,   $id_address = null) : float

Returns the carrier tax rate

Parameters

$id_carrier
$id_address

Returns

float —

$tax_rate

getProductTaxRateViaRules()

getProductTaxRateViaRules(integer  $id_product, integer  $id_country,   $id_state,   $zipcode) : \Tax

Return the product tax rate using the tax rules system

Parameters

integer $id_product
integer $id_country
$id_state
$zipcode

Returns

\Tax

getProductTaxRate()

getProductTaxRate(integer  $id_product,   $id_address = null, \Context  $context = null) : \Tax

Returns the product tax

Parameters

integer $id_product
$id_address
\Context $context

Returns

\Tax

_onStatusChange()

_onStatusChange()