There’s a strange bug that exists in version 1.5 of Magento that not a lot of people would have noticed – basically when you have an order and you to invoice it – you will see a subtle change in the subtotal. This only happens when you have your tax settings set to display everything including and excluding tax.

As you can see the shipping tax gets added onto the subtotal.
Now within Magento 1.6 they have fixed this – and I’ve isolated the problem to possibly just the one function. So it might be possible to replace a few lines of code in your 1.5 core files.
Open up your app>code>core>Mage>Sales>Model>Order>Invoice>Total>Subtotal.php
look for the following lines starting at around 62 and replace so it looks like this:
$allowedSubtotal = $order->getSubtotal() - $order->getSubtotalInvoiced();$baseAllowedSubtotal = $order->getBaseSubtotal() -$order->getBaseSubtotalInvoiced();$allowedSubtotalInclTax = $allowedSubtotal + $order->getHiddenTaxAmount()+ $order->getTaxAmount() - $order->getTaxInvoiced() - $order->getShippingTaxAmount();$baseAllowedSubtotalInclTax = $baseAllowedSubtotal + $order->getBaseHiddenTaxAmount()+ $order->getBaseTaxAmount() - $order->getBaseTaxInvoiced() - $order->getBaseShippingTaxAmount();As you can tell – the shipping gets deducted from the subtotal amount. As this is a bug I’d say update the core files as it shouldn’t have been broken any way
.
Thanks for visiting the Magento Blog here at e-commerce web design, home of the Magento Fox!
Robert Kent Author Page
Không có nhận xét nào:
Đăng nhận xét