Merge pull request #11439 from atm-quentin/FIX_empty_product_use_units

FIX empty product_use_units in product configuration
This commit is contained in:
Laurent Destailleur 2019-07-04 10:38:15 +02:00 committed by GitHub
commit 5fde7da183
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -245,12 +245,12 @@ if ($action == 'set')
if (! $res > 0) $error++; if (! $res > 0) $error++;
} }
if ($action == 'other') //if ($action == 'other')
{ //{
$value = GETPOST('activate_units', 'alpha'); // $value = GETPOST('activate_units', 'alpha');
$res = dolibarr_set_const($db, "PRODUCT_USE_UNITS", $value, 'chaine', 0, '', $conf->entity); // $res = dolibarr_set_const($db, "PRODUCT_USE_UNITS", $value, 'chaine', 0, '', $conf->entity);
if (! $res > 0) $error++; // if (! $res > 0) $error++;
} //}
if ($action) if ($action)
{ {