diff --git a/htdocs/product/class/html.formproduct.class.php b/htdocs/product/class/html.formproduct.class.php index 1d8eb4578cae4..9a8f6c1a94d80 100644 --- a/htdocs/product/class/html.formproduct.class.php +++ b/htdocs/product/class/html.formproduct.class.php @@ -117,6 +117,8 @@ function loadWarehouses($fk_product=0, $batch = '', $status=null, $sumStock = tr { $obj = $this->db->fetch_object($resql); if ($sumStock) $obj->stock = price2num($obj->stock,5); + $o = new Entrepot($this->db); + $o->fetch($obj->rowid); $this->cache_warehouses[$obj->rowid]['id'] =$obj->rowid; $this->cache_warehouses[$obj->rowid]['label']=$o->get_full_arbo(); $this->cache_warehouses[$obj->rowid]['description'] = $obj->description; diff --git a/htdocs/product/stock/card.php b/htdocs/product/stock/card.php index 5a3c5f7249b62..203288170c80d 100644 --- a/htdocs/product/stock/card.php +++ b/htdocs/product/stock/card.php @@ -646,7 +646,7 @@ // Parent entrepot print ''.$langs->trans("AddIn").''; - print $formproduct->selectWarehouses('', 'fk_parent', '', 1, 0, 0, '', 0, 0, array(), 'minwidth200', array($object->id)); + print $formproduct->selectWarehouses($object->fk_parent, 'fk_parent', '', 1, 0, 0, '', 0, 0, array(), 'minwidth200', array($object->id)); print ''; // Description diff --git a/htdocs/product/stock/class/entrepot.class.php b/htdocs/product/stock/class/entrepot.class.php index 539b714ec2e0b..0132ec68fab46 100644 --- a/htdocs/product/stock/class/entrepot.class.php +++ b/htdocs/product/stock/class/entrepot.class.php @@ -575,7 +575,7 @@ function getNomUrl($withpicto=0,$option='') $linkend=''; if ($withpicto) $result.=($link.img_object($label, 'stock', 'class="classfortooltip"').$linkend.' '); - $result.=$link.(empty($this->label)?$this->libelle:$this->label).$linkend; + $result.=$link.$this->get_full_arbo().$linkend; return $result; }