From d85dd69184595ae29daef0a6e1bfd713924fa30a Mon Sep 17 00:00:00 2001 From: gauthier Date: Thu, 20 Oct 2016 13:14:28 +0200 Subject: [PATCH] NEW : get_full_arbo() & get_children_warehouses() functions documentation --- htdocs/product/stock/class/entrepot.class.php | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/htdocs/product/stock/class/entrepot.class.php b/htdocs/product/stock/class/entrepot.class.php index 452d9a59b692b..109460cfa1a53 100644 --- a/htdocs/product/stock/class/entrepot.class.php +++ b/htdocs/product/stock/class/entrepot.class.php @@ -616,7 +616,12 @@ function initAsSpecimen() $this->country_id=1; $this->country_code='FR'; } - + + /** + * Return full path to current warehouse + * + * @return string String full path to current warehouse separated by " >> " + */ function get_full_arbo() { global $user,$langs,$conf; @@ -645,6 +650,13 @@ function get_full_arbo() { } + /** + * Return array of children warehouses ids from $id warehouse (recursive function) + * + * @param int $id id parent warehouse + * @param array() $TChildWarehouses array which will contain all children (param by reference) + * @return array() $TChildWarehouses array which will contain all children + */ function get_children_warehouses($id, &$TChildWarehouses) { $sql = 'SELECT rowid