-
- Micks

-
Total Posts: 14
Joined: 2009-09-20
Amsterdam, The Netherlands
|
Hi there,
I’m having an issue with the way the subtotal on invoices is calculated.
On every invoice the shipping tax amount is added to the subtotal.
This is ONLY the case with the invoices. The subtotal in the cart, at checkout and on the order information is correct.
Any help would be greatly appreciated.
Thanks so much.
Image Attachments

Click thumbnail to see full-size image
|
| |
-
- Posted: June 25 2011
-
| top
-
|
 |
 |
 |
|
|
-
- kenx

-
Total Posts: 2
Joined: 2010-07-30
|
Hi I have the same issue and couldn’t get around of the glitch. Any advices would be very much appreciated!
|
| |
-
- Posted: August 9 2011
-
| top
| # 1
-
|
 |
 |
 |
|
|
-
- ryukyufire

-
Total Posts: 21
Joined: 2010-07-02
Melbourne, Australia
|
I have the same issue.
Magento 1.5.1.
|
| |
-
- Posted: August 12 2011
-
| top
| # 2
-
|
 |
 |
 |
|
|
-
- ryukyufire

-
Total Posts: 21
Joined: 2010-07-02
Melbourne, Australia
|
I found the fix! See this bug post.
http://www.magentocommerce.com/bug-tracking/issue/?issue=11300
Thanks, toruben!
|
| |
-
- Posted: August 12 2011
-
| top
| # 3
-
|
 |
 |
 |
|
|
-
- kenx

-
Total Posts: 2
Joined: 2010-07-30
|
Thanks for this update! But I found it’s still wrong amount in subtotal when customers used discount coupons…
|
| |
-
- Posted: August 14 2011
-
| top
| # 4
-
|
 |
 |
 |
|
|
-
- Micks

-
Total Posts: 14
Joined: 2009-09-20
Amsterdam, The Netherlands
|
After weeks of trying all sorts of things I finally gave up on this whole invoice thing.
I disabled the invoices in the back end and I’m now doing them by hand.
|
| |
-
- Posted: August 15 2011
-
| top
| # 5
-
|
 |
 |
 |
|
|
-
- Tizzalicious

-
Total Posts: 42
Joined: 2011-05-28
|
I am having the same problem.
The invoices are a mess, and they were one of the reasons I wanted a better system for my shop, it takes me way too much time to do them all by hand. I hope someone has a solution for this? I use discount codes a lot, so that part would have to be fixed too.
|
| |
-
- Posted: September 5 2011
-
| top
| # 6
-
|
 |
 |
 |
|
|
-
- mark_logicspot

-
Total Posts: 21
Joined: 2010-04-14
|
Does anyone know if this is fixed in 1.6 release?
I\’ve got a client who uses invoices and discounts and this is just terrible. The code fix only goes half way and discounted invoices are still screwed.
Mark
|
| |
-
- Posted: September 21 2011
-
| top
| # 7
-
|
 |
 |
 |
|
|
|
|
-
- gibbon

-
Total Posts: 5
Joined: 2011-01-23
|
This bug is ridiculous, I couldn’t believe it would be display the wrong numbers.
It is fixed if you make the change in the link above (changes to tax.php and subtotal.php)
or apparently if you upgrade to magento 1.6.1 (October 19 2011)
|
| |
-
- Posted: October 21 2011
-
| top
| # 9
-
|
 |
 |
 |
|
|
-
- Munich

-
Total Posts: 6
Joined: 2010-10-27
|
gibbon - 20 October 2011 07:39 PM This bug is ridiculous, I couldn’t believe it would be display the wrong numbers.
It is fixed if you make the change in the link above (changes to tax.php and subtotal.php)
or apparently if you upgrade to magento 1.6.1 (October 19 2011)
@gibbon: Did it fix the “discount” issue or only the other one?
|
| |
-
- Posted: October 28 2011
-
| top
| # 10
-
|
 |
 |
 |
|
|
-
- Munich

-
Total Posts: 6
Joined: 2010-10-27
|
This German thread fixes the issue:
http://www.magentocommerce.com/boards/viewthread/230901/#t343734
$allowedSubtotal = $order->getSubtotal() - $order->getSubtotalInvoiced(); $baseAllowedSubtotal = $order->getBaseSubtotal() -$order->getBaseSubtotalInvoiced(); $allowedSubtotalInclTax = $allowedSubtotal + $order->getTaxAmount() - $order->getTaxInvoiced(); $baseAllowedSubtotalInclTax = $baseAllowedSubtotal + $order->getBaseTaxAmount() - $order->getBaseTaxInvoiced(); if ($invoice->isLast()) { $subtotal = $allowedSubtotal; $baseSubtotal = $baseAllowedSubtotal; /* $subtotalInclTax = $allowedSubtotalInclTax; */ $baseSubtotalInclTax = $baseAllowedSubtotalInclTax; } else { $subtotal = min($allowedSubtotal, $subtotal); $baseSubtotal = min($baseAllowedSubtotal, $baseSubtotal); $subtotalInclTax = min($allowedSubtotalInclTax, $subtotalInclTax); $baseSubtotalInclTax = min($baseAllowedSubtotalInclTax, $baseSubtotalInclTax); }
Ich habe nur die Zeile $subtotalInclTax = $allowedSubtotalInclTax; deaktiviert, nun stimmen die Summen wieder!
(Mit der Änderung von Andreas funktioniert es auch)
ACHTUNG: schon gespeicherte Rechnungen werden nicht neu berechnet (der Wert wird in Tabelle: sales_flat_order im Feld subtotal_incl_tax gespeichert und könnte dort angepasst werden)
Für die, die es evtl. auch benötigen, habe ich die Datei zum entpacken (incl. Pfade) angehängt.
Es wird in app/code/local/Mage/Sales/Model/Order/Invoice/Total/ entpackt, damit wird die Originaldatei nicht geändert.
|
| |
-
- Posted: October 28 2011
-
| top
| # 11
-
|
 |
 |
 |
|
|
-
- daveloodts

-
Total Posts: 67
Joined: 2009-01-05
Belgium
|
i can confirm that the discount-bug in 1.6 is gone.
However, i either don’t like to upgrade Magento for such a minor thing. And having a big chance of messing up a live-shop.
That’s why you can only copy the following map out of 1.6; and paste it in your 1.5.
Mage - Sale - Model - Order - Invoice - Total.
okay, i’m not recommending doing any upgrades as it should. But this is a minor fault; just a wrong calculation code.
Bigger upgrades are always recommended, even if you must go throught hell to finish a magento upgrade without problems.
|
| |
-
- Posted: November 3 2011
-
| top
| # 12
-
|
 |
 |
 |
|
|
-
- Micks

-
Total Posts: 14
Joined: 2009-09-20
Amsterdam, The Netherlands
|
- i can confirm that the discount-bug in 1.6 is gone.
However, i either don\’t like to upgrade Magento for such a minor thing. And having a big chance of messing up a live-shop.
That\’s why you can only copy the following map out of 1.6; and paste it in your 1.5.
Mage - Sale - Model - Order - Invoice - Total.
okay, i\’m not recommending doing any upgrades as it should. But this is a minor fault; just a wrong calculation code.
Bigger upgrades are always recommended, even if you must go throught hell to finish a magento upgrade without problems.
Thank you all so much for your replies.
I went for the solution above.
Replaced all the files in Mage-Sales-Model-Order-Invoice-Total with the ones from 1.6.
And...it works perfectly!
Thanks Dave!
|
| |
-
- Posted: November 13 2011
-
| top
| # 13
-
|
 |
 |
 |
|
|
|
|
-
- Prikje

-
Total Posts: 1
Joined: 2010-12-09
|
BTW wordt nu goed geplaats nadat ik uit de map van magento 1.6 naar magento 1.5 alles heb gekopieerd.
Mage - Sale - Model - Order - Invoice - Total.
Image Attachments
Click thumbnail to see full-size image
|
| |
|
 |
 |
 |
|
|