|
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
|
Public Member Functions | |
| __construct (Calculation $calculation, CalculatorFactory $calculatorFactory, Config $config, TaxDetailsInterfaceFactory $taxDetailsDataObjectFactory, TaxDetailsItemInterfaceFactory $taxDetailsItemDataObjectFactory, StoreManagerInterface $storeManager, TaxClassManagementInterface $taxClassManagement, \Magento\Framework\Api\DataObjectHelper $dataObjectHelper) | |
| getDefaultCalculatedRate ( $productTaxClassID, $customerId=null, $storeId=null) | |
| getCalculatedRate ( $productTaxClassID, $customerId=null, $storeId=null) | |
Public Member Functions inherited from TaxCalculationInterface | |
| calculateTax (\Magento\Tax\Api\Data\QuoteDetailsInterface $quoteDetails, $storeId=null, $round=true) | |
Protected Member Functions | |
| getRate ( $productTaxClassID, $customerId=null, $storeId=null, $isDefault=false) | |
| processItem (QuoteDetailsItemInterface $item, AbstractCalculator $calculator, $round=true) | |
| calculateParent ($children, $quantity) | |
| aggregateItemData ($taxDetailsData, TaxDetailsItemInterface $item) | |
| getTotalQuantity (QuoteDetailsItemInterface $item) | |
Additional Inherited Members | |
Data Fields inherited from TaxCalculationInterface | |
| const | CALC_UNIT_BASE = 'UNIT_BASE_CALCULATION' |
| const | CALC_ROW_BASE = 'ROW_BASE_CALCULATION' |
| const | CALC_TOTAL_BASE = 'TOTAL_BASE_CALCULATION' |
@SuppressWarnings(PHPMD.CouplingBetweenObjects)
Definition at line 26 of file TaxCalculation.php.
| __construct | ( | Calculation | $calculation, |
| CalculatorFactory | $calculatorFactory, | ||
| Config | $config, | ||
| TaxDetailsInterfaceFactory | $taxDetailsDataObjectFactory, | ||
| TaxDetailsItemInterfaceFactory | $taxDetailsItemDataObjectFactory, | ||
| StoreManagerInterface | $storeManager, | ||
| TaxClassManagementInterface | $taxClassManagement, | ||
| \Magento\Framework\Api\DataObjectHelper | $dataObjectHelper | ||
| ) |
| Calculation | $calculation | |
| CalculatorFactory | $calculatorFactory | |
| Config | $config | |
| TaxDetailsInterfaceFactory | $taxDetailsDataObjectFactory | |
| TaxDetailsItemInterfaceFactory | $taxDetailsItemDataObjectFactory | |
| StoreManagerInterface | $storeManager | |
| TaxClassManagementInterface | $taxClassManagement | |
| \Magento\Framework\Api\DataObjectHelper | $dataObjectHelper |
Definition at line 111 of file TaxCalculation.php.
|
protected |
Add row total item amount to subtotal
| array | $taxDetailsData | |
| TaxDetailsItemInterface | $item |
Definition at line 328 of file TaxCalculation.php.
|
protected |
Calculate row information for item based on children calculation
| TaxDetailsItemInterface[] | $children | |
| int | $quantity |
Definition at line 294 of file TaxCalculation.php.
| getCalculatedRate | ( | $productTaxClassID, | |
$customerId = null, |
|||
$storeId = null |
|||
| ) |
{Get rate request
| int | $productTaxClassID | |
| int | $customerId | |
| string | $storeId |
Implements TaxCalculationInterface.
Definition at line 216 of file TaxCalculation.php.
| getDefaultCalculatedRate | ( | $productTaxClassID, | |
$customerId = null, |
|||
$storeId = null |
|||
| ) |
{Get default rate request
| int | $productTaxClassID | |
| int | $customerId | |
| string | $storeId |
Implements TaxCalculationInterface.
Definition at line 205 of file TaxCalculation.php.
|
protected |
Calculate rate based on default parameter
| int | $productTaxClassID | |
| int | null | $customerId | |
| string | null | $storeId | |
| bool | $isDefault |
Definition at line 233 of file TaxCalculation.php.
|
protected |
Calculates the total quantity for this item.
What this really means is that if this is a child item, it return the parent quantity times the child quantity and return that as the child's quantity.
| QuoteDetailsItemInterface | $item |
Definition at line 381 of file TaxCalculation.php.
|
protected |
Calculate item tax with customized rounding level
| QuoteDetailsItemInterface | $item | |
| AbstractCalculator | $calculator | |
| bool | $round |
Definition at line 278 of file TaxCalculation.php.
|
protected |
Definition at line 47 of file TaxCalculation.php.
|
protected |
Definition at line 94 of file TaxCalculation.php.
|
protected |
Definition at line 40 of file TaxCalculation.php.
|
protected |
Definition at line 99 of file TaxCalculation.php.
|
protected |
Definition at line 54 of file TaxCalculation.php.
|
protected |
Definition at line 66 of file TaxCalculation.php.
|
protected |
Definition at line 87 of file TaxCalculation.php.
|
protected |
Definition at line 33 of file TaxCalculation.php.
|
protected |
Definition at line 61 of file TaxCalculation.php.