From ed3db2c39e10b295db0391096dd233c1aaa2b108 Mon Sep 17 00:00:00 2001 From: Joe Date: Sun, 17 Jul 2022 12:06:14 +0200 Subject: [PATCH] Rerun of Invoice not converting from DN due to float bug. Fixed. --- sales/customer_invoice.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sales/customer_invoice.php b/sales/customer_invoice.php index f6791c17..7b05aa2d 100644 --- a/sales/customer_invoice.php +++ b/sales/customer_invoice.php @@ -205,10 +205,10 @@ function check_quantities() } else { global $path_to_root; $min = 0; - include_once($path_to_root . "/inventory/includes/db/items_units_db.inc"); + // Fixing floating point problem in PHP. + include_once($path_to_root . "/inventory/includes/db/items_units_db.inc"); $max = round2($itm->quantity - $itm->qty_done, get_unit_dec($itm->stock_id)); } - dump($max); if (check_num('Line'.$line_no, $min, $max)) { $_SESSION['Items']->line_items[$line_no]->qty_dispatched = input_num('Line'.$line_no); -- 2.30.2