From 60a033458bf25d35a7f0319d8b686c1f87a76c79 Mon Sep 17 00:00:00 2001 From: Dany De Bontridder Date: Mon, 18 Feb 2019 22:02:38 +0100 Subject: [PATCH] =?UTF-8?q?Mantis=20#0001651:=20Probl=C3=A8me=20avec=20tot?= =?UTF-8?q?aux=20en=20CA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- html/js/anc_script.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/html/js/anc_script.js b/html/js/anc_script.js index 9e2b7a3fb..101470d1e 100644 --- a/html/js/anc_script.js +++ b/html/js/anc_script.js @@ -162,9 +162,8 @@ function verify_ca(div) } else { amount = Math.round(amount*100)/100; } - var diff = amount - total_amount; - - if (Math.round(diff, 2) != 0.0) + var diff = amount*100 - total_amount*100; + if (Math.round(diff/100) != 0.0) { g(table).style.backgroundColor = 'red'; amount_error++;