[Koha-bugs] [Bug 13321] Tax and prices calculation need to be fixed

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Wed Feb 25 11:24:49 CET 2015


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13321

--- Comment #22 from Jonathan Druart <jonathan.druart at biblibre.com> ---
Very nice catch François :)

That comes from a commit on bug 13323:

commit b5e9c8a8821f950933c19b8524fe2af3a98d05d7
Author: Jonathan Druart <jonathan.druart at biblibre.com>
Date:   Wed Nov 19 17:01:17 2014 +0100

    Bug 13323: Tax rate can change on receiving

    This commit permits to update the tax rate on receiving.

diff --git a/acqui/invoice.pl b/acqui/invoice.pl
index 3a163c5..9fcef0e 100755
--- a/acqui/invoice.pl
+++ b/acqui/invoice.pl
@@ -126,7 +126,8 @@ foreach my $order (@$orders) {
-    $line->{tax_value} *= $line->{quantity};
+    $line->{tax_value} = $line->{tax_value_on_receiving};
+    $line->{tax_rate} = $line->{tax_rate_on_receiving};


It should have been:
-    $line->{tax_value} *= $line->{quantity};
+    $line->{tax_value} = $line->{tax_value_on_receiving} * $line->{quantity};
+    $line->{tax_rate} = $line->{tax_rate_on_receiving};

The quantity has been forgotten.
I updated the commit, the branch and the sandbox with this change.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list