diff --git a/htdocs/core/lib/functions2.lib.php b/htdocs/core/lib/functions2.lib.php index 7fcc3107b2e..555ff9da63b 100644 --- a/htdocs/core/lib/functions2.lib.php +++ b/htdocs/core/lib/functions2.lib.php @@ -973,7 +973,7 @@ function get_next_value($db, $mask, $table, $field, $where = '', $objsoc = '', $ if (!is_object($objsoc)) { $valueforccc = $objsoc; - } elseif ($table == "commande_fournisseur" || $table == "facture_fourn") { + } elseif ($table == "commande_fournisseur" || $table == "facture_fourn" || $table == "paiementfourn") { $valueforccc = dol_string_unaccent($objsoc->code_fournisseur); } else { $valueforccc = dol_string_unaccent($objsoc->code_client);