[ Index ] |
|
Code source de eZ Publish 3.9.0 |
[Code source] [Imprimer] [Statistiques]
(pas de description)
Poids: | 237 lignes (8 kb) |
Inclus ou requis: | 0 fois |
Référencé: | 0 fois |
Nécessite: | 2 fichiers kernel/classes/ezproductcategory.php kernel/classes/ezvatrule.php |
eZDefaultVATHandler:: (3 méthodes):
getVatPercent()
getProductCategory()
chooseVatType()
Classe: eZDefaultVATHandler - X-Ref
getVatPercent( $object, $country ) X-Ref |
\public \static |
getProductCategory( $object ) X-Ref |
Determine object's product category. \private \static |
chooseVatType( $productCategory, $country ) X-Ref |
Choose the best matching VAT type for given product category and country. We calculate priority for each VAT type and then choose the VAT type having the highest priority (or first of those having the highest priority). VAT type priority is calculated from county match and category match as following: CountryMatch = 0 CategoryMatch = 1 if ( <there is exact match on country> ) CountryMatch = 2 elseif ( <there is weak match on country> ) CountryMatch = 1 if ( <there is exact match on product category> ) CategoryMatch = 2 elseif ( <there is weak match on product category> ) CategoryMatch = 1 if ( <there is match on both country and category ) VatTypePriority = CountryMatch * 2 + CategoryMatch - 2 else VatTypePriority = 0 \private \static |
Généré le : Sat Feb 24 10:30:04 2007 | par Balluche grâce à PHPXref 0.7 |