From 2e0de15f958116f083950881231cc1d49345080d Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 24 Oct 2018 11:26:50 +0200 Subject: [PATCH] Add public --- htdocs/product/class/product.class.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/htdocs/product/class/product.class.php b/htdocs/product/class/product.class.php index 49d4d9a290c..6748ecdef69 100644 --- a/htdocs/product/class/product.class.php +++ b/htdocs/product/class/product.class.php @@ -3488,7 +3488,7 @@ class Product extends CommonObject * * @return int Nb of father + child */ - function hasFatherOrChild() + public function hasFatherOrChild() { $nb = 0; @@ -3514,7 +3514,7 @@ class Product extends CommonObject * * @return int Number of variants */ - function hasVariants() + public function hasVariants() { $nb = 0; $sql = "SELECT count(rowid) as nb FROM ".MAIN_DB_PREFIX."product_attribute_combination WHERE fk_product_parent = ".$this->id; @@ -3535,7 +3535,7 @@ class Product extends CommonObject * * @return int */ - function isVariant() + public function isVariant() { global $conf; if (!empty($conf->variants->enabled)) { @@ -3563,7 +3563,7 @@ class Product extends CommonObject * * @return array Array of product */ - function getFather() + public function getFather() { $sql = "SELECT p.rowid, p.label as label, p.ref as ref, pa.fk_product_pere as id, p.fk_product_type, pa.qty, pa.incdec, p.entity"; $sql.= " FROM ".MAIN_DB_PREFIX."product_association as pa,"; @@ -3604,7 +3604,7 @@ class Product extends CommonObject * @param int $level Level of recursing call (start to 1) * @return array Return array(prodid=>array(0=prodid, 1=>qty, 2=> ...) */ - function getChildsArbo($id, $firstlevelonly=0, $level=1) + public function getChildsArbo($id, $firstlevelonly=0, $level=1) { global $alreadyfound; @@ -3692,7 +3692,7 @@ class Product extends CommonObject * @param int $save_lastsearch_value -1=Auto, 0=No save of lastsearch_values when clicking, 1=Save lastsearch_values whenclicking * @return string String with URL */ - function getNomUrl($withpicto=0, $option='', $maxlength=0, $save_lastsearch_value=-1) + public function getNomUrl($withpicto=0, $option='', $maxlength=0, $save_lastsearch_value=-1) { global $conf, $langs, $hookmanager; include_once DOL_DOCUMENT_ROOT.'/core/lib/product.lib.php'; @@ -3848,7 +3848,7 @@ class Product extends CommonObject * @param int $type 0=Sell, 1=Buy, 2=Batch Number management * @return string Label of status */ - function getLibStatut($mode=0, $type=0) + public function getLibStatut($mode=0, $type=0) { switch ($type) {