0

I am facing a problem in which row total of products are not taking special price for some products. I need to check the calculation from where it is calculated.

Anyone who knows the file in which it is calculated.

1 Answer 1

0

This value calculated in app\code\core\Mage\Tax\Model\Sales\Total\Quote\Subtotal.php Depends on selected algorithm, it use

 protected function _processItem($item, $taxRequest)
{
    switch ($this->_config->getAlgorithm($this->_store)) {
        case Mage_Tax_Model_Calculation::CALC_UNIT_BASE:
            $this->_unitBaseCalculation($item, $taxRequest);
            break;
        case Mage_Tax_Model_Calculation::CALC_ROW_BASE:
            $this->_rowBaseCalculation($item, $taxRequest);
            break;
        case Mage_Tax_Model_Calculation::CALC_TOTAL_BASE:
            $this->_totalBaseCalculation($item, $taxRequest);
            break;
        default:
            break;
    }
    return $this;
}

So, check the function that is used in your case. Also you can search for this row:

$item->setRowTotalInclTax($taxSubtotal);
4
  • Can you tell me when this methods are called? When row total is calculated for a particular product? Commented Aug 2, 2017 at 13:09
  • This method is called when subtotal is calculated. During this calculation system go throw all items and also fill this values. Commented Aug 2, 2017 at 13:54
  • Thats what I want to know, when subtotal is calculated. I am facing an issue in which subtotal is showing original price in place of special price. I need to check why? Commented Aug 2, 2017 at 14:02
  • Sure, you can debug it in this place. Using xdebug for example Commented Aug 2, 2017 at 19:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.