From bc954af404fc5e2d9c2e0cf481ba36867749c24c Mon Sep 17 00:00:00 2001 From: stickler-ci Date: Fri, 17 Feb 2023 09:32:05 +0000 Subject: [PATCH] Fixing style errors. --- .../product/stock/class/productlot.class.php | 120 +++++++++--------- 1 file changed, 60 insertions(+), 60 deletions(-) diff --git a/htdocs/product/stock/class/productlot.class.php b/htdocs/product/stock/class/productlot.class.php index 7f05796eeae..7d12acae368 100644 --- a/htdocs/product/stock/class/productlot.class.php +++ b/htdocs/product/stock/class/productlot.class.php @@ -571,7 +571,7 @@ class Productlot extends CommonObject $sql .= " FROM ".$this->db->prefix()."expeditiondet_batch as edb"; $sql .= " INNER JOIN ".$this->db->prefix()."expeditiondet as ed ON (ed.rowid = edb.fk_expeditiondet)"; $sql .= " INNER JOIN ".$this->db->prefix()."expedition as exp ON (exp.rowid = ed.fk_expedition)"; -// $sql .= ", ".$this->db->prefix()."societe as s"; + // $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid) { $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } @@ -597,25 +597,25 @@ class Productlot extends CommonObject // Virtual products can't be used with kits (see langs with key ErrorNoteAlsoThatSubProductCantBeFollowedByLot) // if it's a virtual product, maybe it is in invoice by extension -// if (!empty($conf->global->PRODUCT_STATS_WITH_PARENT_PROD_IF_INCDEC)) { -// $TFather = $this->getFather(); -// if (is_array($TFather) && !empty($TFather)) { -// foreach ($TFather as &$fatherData) { -// $pFather = new Product($this->db); -// $pFather->id = $fatherData['id']; -// $qtyCoef = $fatherData['qty']; -// -// if ($fatherData['incdec']) { -// $pFather->loadStatsExpedition($socid); -// -// $this->stats_expedition['customers'] += $pFather->stats_expedition['customers']; -// $this->stats_expedition['nb'] += $pFather->stats_expedition['nb']; -// $this->stats_expedition['rows'] += $pFather->stats_expedition['rows']; -// $this->stats_expedition['qty'] += $pFather->stats_expedition['qty'] * $qtyCoef; -// } -// } -// } -// } + // if (!empty($conf->global->PRODUCT_STATS_WITH_PARENT_PROD_IF_INCDEC)) { + // $TFather = $this->getFather(); + // if (is_array($TFather) && !empty($TFather)) { + // foreach ($TFather as &$fatherData) { + // $pFather = new Product($this->db); + // $pFather->id = $fatherData['id']; + // $qtyCoef = $fatherData['qty']; + // + // if ($fatherData['incdec']) { + // $pFather->loadStatsExpedition($socid); + // + // $this->stats_expedition['customers'] += $pFather->stats_expedition['customers']; + // $this->stats_expedition['nb'] += $pFather->stats_expedition['nb']; + // $this->stats_expedition['rows'] += $pFather->stats_expedition['rows']; + // $this->stats_expedition['qty'] += $pFather->stats_expedition['qty'] * $qtyCoef; + // } + // } + // } + // } $parameters = array('socid' => $socid); $reshook = $hookmanager->executeHooks('loadStatsLotExpedition', $parameters, $this, $action); @@ -646,7 +646,7 @@ class Productlot extends CommonObject $sql .= " FROM ".$this->db->prefix()."commande_fournisseur_dispatch as cfdi"; $sql .= " INNER JOIN ".$this->db->prefix()."commande_fournisseurdet as cfd ON (cfd.rowid = cfdi.fk_commandefourndet)"; $sql .= " INNER JOIN ".$this->db->prefix()."commande_fournisseur as cf ON (cf.rowid = cfd.fk_commande)"; -// $sql .= ", ".$this->db->prefix()."societe as s"; + // $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid) { $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } @@ -672,25 +672,25 @@ class Productlot extends CommonObject // Virtual products can't be used with kits (see langs with key ErrorNoteAlsoThatSubProductCantBeFollowedByLot) // if it's a virtual product, maybe it is in invoice by extension -// if (!empty($conf->global->PRODUCT_STATS_WITH_PARENT_PROD_IF_INCDEC)) { -// $TFather = $this->getFather(); -// if (is_array($TFather) && !empty($TFather)) { -// foreach ($TFather as &$fatherData) { -// $pFather = new Product($this->db); -// $pFather->id = $fatherData['id']; -// $qtyCoef = $fatherData['qty']; -// -// if ($fatherData['incdec']) { -// $pFather->stats_supplier_order($socid); -// -// $this->stats_supplier_order['customers'] += $pFather->stats_supplier_order['customers']; -// $this->stats_supplier_order['nb'] += $pFather->stats_supplier_order['nb']; -// $this->stats_supplier_order['rows'] += $pFather->stats_supplier_order['rows']; -// $this->stats_supplier_order['qty'] += $pFather->stats_supplier_order['qty'] * $qtyCoef; -// } -// } -// } -// } + // if (!empty($conf->global->PRODUCT_STATS_WITH_PARENT_PROD_IF_INCDEC)) { + // $TFather = $this->getFather(); + // if (is_array($TFather) && !empty($TFather)) { + // foreach ($TFather as &$fatherData) { + // $pFather = new Product($this->db); + // $pFather->id = $fatherData['id']; + // $qtyCoef = $fatherData['qty']; + // + // if ($fatherData['incdec']) { + // $pFather->stats_supplier_order($socid); + // + // $this->stats_supplier_order['customers'] += $pFather->stats_supplier_order['customers']; + // $this->stats_supplier_order['nb'] += $pFather->stats_supplier_order['nb']; + // $this->stats_supplier_order['rows'] += $pFather->stats_supplier_order['rows']; + // $this->stats_supplier_order['qty'] += $pFather->stats_supplier_order['qty'] * $qtyCoef; + // } + // } + // } + // } $parameters = array('socid' => $socid); $reshook = $hookmanager->executeHooks('loadStatsLotSupplierOrder', $parameters, $this, $action); @@ -720,7 +720,7 @@ class Productlot extends CommonObject $sql .= " COUNT(cfdi.rowid) as nb_rows, SUM(cfdi.qty) as qty"; $sql .= " FROM ".$this->db->prefix()."commande_fournisseur_dispatch as cfdi"; $sql .= " INNER JOIN ".$this->db->prefix()."reception as recep ON (recep.rowid = cfdi.fk_reception)"; -// $sql .= ", ".$this->db->prefix()."societe as s"; + // $sql .= ", ".$this->db->prefix()."societe as s"; if (empty($user->rights->societe->client->voir) && !$socid) { $sql .= ", ".$this->db->prefix()."societe_commerciaux as sc"; } @@ -746,25 +746,25 @@ class Productlot extends CommonObject // Virtual products can't be used with kits (see langs with key ErrorNoteAlsoThatSubProductCantBeFollowedByLot) // if it's a virtual product, maybe it is in invoice by extension -// if (!empty($conf->global->PRODUCT_STATS_WITH_PARENT_PROD_IF_INCDEC)) { -// $TFather = $this->getFather(); -// if (is_array($TFather) && !empty($TFather)) { -// foreach ($TFather as &$fatherData) { -// $pFather = new Product($this->db); -// $pFather->id = $fatherData['id']; -// $qtyCoef = $fatherData['qty']; -// -// if ($fatherData['incdec']) { -// $pFather->loadStatsReception($socid); -// -// $this->stats_expedition['customers'] += $pFather->stats_expedition['customers']; -// $this->stats_expedition['nb'] += $pFather->stats_expedition['nb']; -// $this->stats_expedition['rows'] += $pFather->stats_expedition['rows']; -// $this->stats_expedition['qty'] += $pFather->stats_expedition['qty'] * $qtyCoef; -// } -// } -// } -// } + // if (!empty($conf->global->PRODUCT_STATS_WITH_PARENT_PROD_IF_INCDEC)) { + // $TFather = $this->getFather(); + // if (is_array($TFather) && !empty($TFather)) { + // foreach ($TFather as &$fatherData) { + // $pFather = new Product($this->db); + // $pFather->id = $fatherData['id']; + // $qtyCoef = $fatherData['qty']; + // + // if ($fatherData['incdec']) { + // $pFather->loadStatsReception($socid); + // + // $this->stats_expedition['customers'] += $pFather->stats_expedition['customers']; + // $this->stats_expedition['nb'] += $pFather->stats_expedition['nb']; + // $this->stats_expedition['rows'] += $pFather->stats_expedition['rows']; + // $this->stats_expedition['qty'] += $pFather->stats_expedition['qty'] * $qtyCoef; + // } + // } + // } + // } $parameters = array('socid' => $socid); $reshook = $hookmanager->executeHooks('loadStatsLotReception', $parameters, $this, $action);