Merge pull request #16223 from ATM-Consulting/fix/12.0_order_addline_remove_warning

FIX: warning when adding a line if $remise_percent is an empty string
This commit is contained in:
Laurent Destailleur 2021-02-08 17:34:29 +01:00 committed by GitHub
commit 3b1143df91
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -672,6 +672,7 @@ if (empty($reshook))
$qty = price2num(GETPOST('qty'.$predef, 'alpha'));
$remise_percent = (GETPOSTISSET('remise_percent'.$predef) ? price2num(GETPOST('remise_percent'.$predef, 'alpha')) : 0);
if ($remise_percent === '') $remise_percent = 0;
// Extrafields
$extralabelsline = $extrafields->fetch_name_optionals_label($object->table_element_line);