Rename hidden constant for a better understanding

This commit is contained in:
ldestailleur
2025-09-27 02:20:40 +02:00
parent a43bf46a75
commit 7e77994cec

View File

@@ -663,7 +663,7 @@ class MouvementStock extends CommonObject
}
// Add movement for sub products (recursive call)
if (!$error && getDolGlobalString('PRODUIT_SOUSPRODUITS') && !getDolGlobalString('INDEPENDANT_SUBPRODUCT_STOCK') && empty($disablestockchangeforsubproduct)) {
if (!$error && getDolGlobalString('PRODUIT_SOUSPRODUITS') && !getDolGlobalString('PRODUIT_SOUSPRODUITS_ALWAYS_DISABLE_CHILDREN_STOCK_MOVE') && empty($disablestockchangeforsubproduct)) {
$error = $this->_createSubProduct($user, $fk_product, $entrepot_id, $qty, $type, 0, $label, $inventorycode, $datem); // we use 0 as price, because AWP must not change for subproduct
}
@@ -1170,7 +1170,7 @@ class MouvementStock extends CommonObject
*/
public function getNomUrl($withpicto = 0, $option = '', $notooltip = 0, $maxlen = 24, $morecss = '')
{
global $langs, $conf, $db;
global $langs;
$result = '';
@@ -1263,7 +1263,7 @@ class MouvementStock extends CommonObject
*/
public function generateDocument($modele, $outputlangs, $hidedetails = 0, $hidedesc = 0, $hideref = 0)
{
global $conf, $user, $langs;
global $langs;
$langs->load("stocks");
$outputlangs->load("products");