ePages 6.11.0 - DE_EPAGES/Tax/API/TLE/TaxMatrixHandler.pm

Package DE_EPAGES::Tax::API::TLE::TaxMatrixHandler

Implements TLE functions for tax matrix

Functions

RegisterHandlerProc
TaxAreaByCountryID
TaxRateForDefaultTaxArea
ZipcodesForCountry
new
register

RegisterHandlerProc

this function registers this attribute handle on the processor via hook function on hook TLEProcessorRegistration

Syntax
$RegisterHandlerProc( $hParams );
Input
$hParams (ref.hash)
hook arguments keys :
  • Processor - tle processor - object

TaxAreaByCountryID

Returns the TaxArea for a given countryid

Syntax
#FUNCTION("TaxAreaByCountryID", #TaxMatrix, #CountryID, #ZipcodeFrom, $ZipcodeTo)
Input
#TaxMatrix (object)
taxmatrix object
#CountryID (int)
country id
#ZipcodeFrom (string)
min zipcode (optional)
#ZipcodeTo (string)
max zipcode (optional)

TaxRateForDefaultTaxArea

Returns the tax rate for the tax class in default tax area of shop

Syntax
#FUNCTION("TaxRateForDefaultTaxArea", #Shop.Object, #TaxClass.Object)
Input
#Shop (object)
shop
#TaxClass (object)
tax class

ZipcodesForCountry

Returns the Zipcodes with TaxArea for a country.

Syntax
#FUNCTION("ZipcodesForCountry", #TaxMatrix, #CountryID)
Input
#TaxMatrix (object)
taxmatrix object
#CountryID (int)
country id

new

create a new handler

Syntax
$Handler = new DE_EPAGES::Tax::API::TLE::TaxMatrixHandler;
Example
my $PrefixHandler  = new DE_EPAGES::Tax::API::TLE::TaxMatrixHandler;
Return
$Handler (object)
blessed object

register

this function register this handle on the processor

Syntax
$Handler->register( $Processor );
Input
$Processor (object)
tle processor