-
- Downloads
Fix: bug #6653 situation invoice miscalculation
Bug (#6653) In price.lib.php (htdocs\core\lib\price.lib.php), the function calcul_price_total() is defined (line 76). The 7th parameter is **$remise_percent_global**. However, this function is called on facture.class.php (htdocs\compta\facture\class\facture.class.php) and the 7th parameter used is **$line->product_type**. Consequently, invoice situation is correct when user sells a product (product_type = 0) and is wrong when user sells a service (product_type = 1). Effectively, in the latter case, the total situation invoice will be wrong by 1%. In order to correct this, we can add 0 as the 7th parameter and move **$line->product_type** to the 10th parameter.
Please register or sign in to comment