function commerce_tax_type_load in Commerce Core 7
Returns a single tax type object.
Parameters
$name: The name of the tax type to return.
Return value
The specified tax type object or FALSE if it did not exist.
8 calls to commerce_tax_type_load()
- CommerceBaseTestCase::createDummyTaxType in tests/
commerce_base.test - * Create a dummy tax type. * *
- CommerceTaxUIAdminTest::testCommerceTaxUICreateTaxType in modules/
tax/ tests/ commerce_tax_ui.test - Test the creation of a tax type.
- CommerceTaxUIAdminTest::testCommerceTaxUIEditTaxType in modules/
tax/ tests/ commerce_tax_ui.test - Test editing a tax type.
- commerce_tax_calculate_by_type in modules/
tax/ commerce_tax.rules.inc - Rules action: checks for the application of each tax rate of a certain type.
- commerce_tax_rate_apply in modules/
tax/ commerce_tax.module - Applies a tax rate to the unit price of a line item.
1 string reference to 'commerce_tax_type_load'
- commerce_tax_ui_tax_type_form in modules/
tax/ includes/ commerce_tax_ui.admin.inc - Form callback: create or edit a tax type.
File
- modules/
tax/ commerce_tax.module, line 106 - Defines tax rates and Rules integration for configuring tax rules for applicability and display.
Code
function commerce_tax_type_load($name) {
$tax_types = commerce_tax_types();
return empty($tax_types[$name]) ? FALSE : $tax_types[$name];
}