Tax Rates

Tax rates are specific rates of tax applied for a specific classes of products in specific geographical zones. For a list of tax classes and rates, see the wikipedia article Value Added Tax.

Configuration Example

Sweden

 Rate ame: SE VAT 25%
 Tax Class: Default
 Geo Zone: SE
 Rules: Applies to all

 Rate Name: SE VAT 25%
 Tax Class: Default
 Geo Zone: EU (excl. SE)
 Rules: Applies to individuals

 Rate Name: SE VAT 25%
 Tax Class: Default
 Geo Zone: EU (excl. SE)
 Rules: Applies to companies without a tax id.

EU Reverse Tax Charge Mechanism

Businesses in the E.U. selling to other businesses in the E.U. where VATIN is provided for Tax ID are subject to the reversed tax charge mechanism. For more information consult your national tax office.

Entity Object

$tax_rate = new ent_tax_rate();
$tax_rate->data['tax_class_id'] = 1;
$tax_rate->data['name'] = '...';
...
$tax_rate->data['rate'] = 20;
$tax_rate->save();

Reference Model

Tax rates doesn't have a reference object. Instead, values from the entity will be returned.

echo reference::tax_rate($tax_rate_id)->rate;

Database Query

$query = database::query(
  "select * from ". DB_TABLE_PREFIX ."tax_rates
  where tax_class_id = ". (int)$tax_class_id .";"
);

while ($tax_rate = database::fetch($query)) {
  echo $tax_rate['rate'];
}

Revisiot

Äskettäin muokatut artikkelit