Magento has a rich Sales module with a ton of options, and it's well-documented for high-level things, but I'm stuck when it comes to subtle distinctions. I'm trying to put together some order analytics software, but I haven't been able to figure out exactly how a Magento order's subtotal and baseSubtotal differ, nor have I been able to find API documentation to that level of detail.
The only thing I have been able to find is in the source code at app/code/core/Mage/Sales/Model
, but it would seem to indicate that the values are always the same.
Order/Creditmemo/Total/Subtotal.php: $creditmemo->setSubtotal($subtotal);
Order/Creditmemo/Total/Subtotal.php: $creditmemo->setBaseSubtotal($baseSubtotal);
Order/Invoice/Total/Subtotal.php: $invoice->setSubtotal($subtotal);
Order/Invoice/Total/Subtotal.php: $invoice->setBaseSubtotal($baseSubtotal);
Quote.php: $this->setSubtotal(0);
Quote.php: $this->setBaseSubtotal(0);
Quote.php: $address->setSubtotal(0);
Quote.php: $address->setBaseSubtotal(0);
Quote.php: $this->setSubtotal((float) $this->getSubtotal() + $address->getSubtotal());
Quote.php: $this->setBaseSubtotal((float) $this->getBaseSubtotal() + $address->getBaseSubtotal());
Recurring/Profile.php: ->setBaseSubtotal($billingAmount)
Recurring/Profile.php: ->setSubtotal($billingAmount)
Do they ever differ, and if so, how?