--- /tmp/dsg/dolibarr/htdocs/core/modules/commande/github_mod_commande_marbre.php +++ /tmp/dsg/dolibarr/htdocs/core/modules/commande/client_mod_commande_marbre.php @@ -129,7 +129,9 @@ $obj = $db->fetch_object($resql); if ($obj) $max = intval($obj->max); else $max = 0; - } else { + } + else + { dol_syslog("mod_commande_marbre::getNextValue", LOG_DEBUG); return -1; } --- /tmp/dsg/dolibarr/htdocs/core/modules/commande/github_mod_commande_saphir.php +++ /tmp/dsg/dolibarr/htdocs/core/modules/commande/client_mod_commande_saphir.php @@ -35,9 +35,9 @@ class mod_commande_saphir extends ModeleNumRefCommandes { /** - * Dolibarr version of the loaded document - * @var string - */ + * Dolibarr version of the loaded document + * @var string + */ public $version = 'dolibarr'; // 'development', 'experimental', 'dolibarr' /** @@ -51,14 +51,14 @@ public $name = 'Saphir'; - /** - * Returns the description of the numbering model - * - * @return string Texte descripif - */ - public function info() - { - global $conf, $langs, $db; + /** + * Returns the description of the numbering model + * + * @return string Texte descripif + */ + public function info() + { + global $conf, $langs, $db; $langs->load("bills"); @@ -89,22 +89,22 @@ $texte .= ''; return $texte; - } + } - /** - * Return an example of numbering - * - * @return string Example - */ - public function getExample() - { - global $conf, $langs, $mysoc; + /** + * Return an example of numbering + * + * @return string Example + */ + public function getExample() + { + global $conf, $langs, $mysoc; - $old_code_client = $mysoc->code_client; - $old_code_type = $mysoc->typent_code; - $mysoc->code_client = 'CCCCCCCCCC'; - $mysoc->typent_code = 'TTTTTTTTTT'; - $numExample = $this->getNextValue($mysoc, ''); + $old_code_client = $mysoc->code_client; + $old_code_type = $mysoc->typent_code; + $mysoc->code_client = 'CCCCCCCCCC'; + $mysoc->typent_code = 'TTTTTTTTTT'; + $numExample = $this->getNextValue($mysoc, ''); $mysoc->code_client = $old_code_client; $mysoc->typent_code = $old_code_type; @@ -113,7 +113,7 @@ $numExample = $langs->trans('NotConfigured'); } return $numExample; - } + } /** * Return next free value @@ -122,8 +122,8 @@ * @param Object $object Object we need next value for * @return string Value if KO, <0 if KO */ - public function getNextValue($objsoc, $object) - { + public function getNextValue($objsoc, $object) + { global $db, $conf; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; @@ -148,17 +148,17 @@ } - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps + // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps /** * Return next free value * * @param Societe $objsoc Object third party * @param string $objforref Object for number to search * @return string Next free value - */ - public function commande_get_num($objsoc, $objforref) - { - // phpcs:enable - return $this->getNextValue($objsoc, $objforref); - } + */ + public function commande_get_num($objsoc, $objforref) + { + // phpcs:enable + return $this->getNextValue($objsoc, $objforref); + } }