https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35114
--- Comment #13 from Thibaud Guillot <[email protected]> --- Hello everyone, I've adjusted the rounding functions and their calculation. According to the OrderPriceRounding system preference, when the get_rounded_price function was called, the prices were adjusted at the wrong time. (Note: without this patch, which corrects the use of unit price in calculations, the system preference has no effect, as the unit price is retrieved beforehand and modified in JS to round it off). Lines were rounded one by one and then the total was rounded... This can lead to problems: example: - 13.44567 -> rounded to 13.45 - 2.44567 -> rounded to 2.45 total 13.44567 + 2.44567 = 15.89134 rounded to 15.89 total 13.45 + 2.45 = 15.90 so I've kept this rounding behavior on each of the lines, but I've added a total that I calculate without rounding, and then pass the corresponding roundings to the view. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
