diff --git a/ChangeLog b/ChangeLog index c784c2f4bf3..ef9dd78bb4c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -24,7 +24,7 @@ Following changes may create regressions for some external modules, but were nec * Field "total" renamed into "total_ttc" for table lx_propal, llx_supplier_proposal for better field name consistency * If your database is PostgreSql, you must use version 9.1.0 or more (Dolibarr need the SQL function CONCAT) * If your database is MySql or MariaDB, you need at least version 5.1 - +* Function set_price_level() has been renamed into setPriceLevel() to follow camelcase rules ***** ChangeLog for 13.0.2 compared to 13.0.1 ***** diff --git a/htdocs/comm/multiprix.php b/htdocs/comm/multiprix.php index a409a150778..98c44b3ad3f 100644 --- a/htdocs/comm/multiprix.php +++ b/htdocs/comm/multiprix.php @@ -56,7 +56,7 @@ $result = restrictedArea($user, 'societe', $id, '&societe', '', 'fk_soc', 'rowid if ($action == 'setpricelevel') { $soc = new Societe($db); $soc->fetch($id); - $soc->set_price_level(GETPOST("price_level"), $user); + $soc->setPriceLevel(GETPOST("price_level"), $user); header("Location: multiprix.php?id=".$id); exit; diff --git a/htdocs/societe/class/api_thirdparties.class.php b/htdocs/societe/class/api_thirdparties.class.php index 6fd5160d8a6..f5eae0be948 100644 --- a/htdocs/societe/class/api_thirdparties.class.php +++ b/htdocs/societe/class/api_thirdparties.class.php @@ -575,7 +575,7 @@ class Thirdparties extends DolibarrApi throw new RestException(401, 'Access to thirdparty '.$id.' not allowed for login '.DolibarrApiAccess::$user->login); } - $result = $this->company->set_price_level($priceLevel, DolibarrApiAccess::$user); + $result = $this->company->setPriceLevel($priceLevel, DolibarrApiAccess::$user); if ($result <= 0) { throw new RestException(500, 'Error setting new price level for thirdparty '.$id, array($this->company->db->lasterror())); } diff --git a/htdocs/societe/class/societe.class.php b/htdocs/societe/class/societe.class.php index 6874c4b3b2d..9d449922dd2 100644 --- a/htdocs/societe/class/societe.class.php +++ b/htdocs/societe/class/societe.class.php @@ -2272,7 +2272,6 @@ class Societe extends CommonObject } } - // phpcs:disable PEAR.NamingConventions.ValidFunctionName.ScopeNotCamelCaps /** * Set the price level * @@ -2280,9 +2279,8 @@ class Societe extends CommonObject * @param User $user Use making change * @return int <0 if KO, >0 if OK */ - public function set_price_level($price_level, User $user) + public function setPriceLevel($price_level, User $user) { - // phpcs:enable if ($this->id) { $now = dol_now();