From ea1c4cca06a9a1175f40c04a0ef9f1538f479840 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Charl=C3=A8ne=20Benke?= <1179011+defrance@users.noreply.github.com> Date: Wed, 13 Nov 2024 13:22:10 +0100 Subject: [PATCH] qty must be float (not int) (#31792) Co-authored-by: Laurent Destailleur --- htdocs/mrp/mo_production.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/mrp/mo_production.php b/htdocs/mrp/mo_production.php index 752dafff080d5..b7a0c189b5b53 100644 --- a/htdocs/mrp/mo_production.php +++ b/htdocs/mrp/mo_production.php @@ -188,7 +188,7 @@ // Line to produce $moline->fk_mo = $object->id; - $moline->qty = GETPOSTINT('qtytoadd'); + $moline->qty = GETPOSTFLOAT('qtytoadd'); $moline->fk_product = GETPOSTINT('productidtoadd'); if (GETPOST('addconsumelinebutton')) { $moline->role = 'toconsume'; @@ -484,7 +484,7 @@ $value = GETPOST('options_'.$key, 'alphanohtml'); $moline->array_options["options_".$key] = $value; } - $moline->qty = GETPOSTINT('qty_lineProduce'); + $moline->qty = GETPOSTFLOAT('qty_lineProduce'); $res = $moline->update($user); if ($res < 0) { setEventMessages($moline->error, $moline->errors, 'errors');