From: cajus Date: Wed, 9 Dec 2009 09:37:38 +0000 (+0000) Subject: Added opsi function to retrieve full host product information X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=79edbbdf2499826f59792d5adf5052f65ed5e078;p=gosa.git Added opsi function to retrieve full host product information git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@14886 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-plugins/opsi/admin/opsi/class_opsi.inc b/gosa-plugins/opsi/admin/opsi/class_opsi.inc index b0ea92bdf..ebbf46c21 100644 --- a/gosa-plugins/opsi/admin/opsi/class_opsi.inc +++ b/gosa-plugins/opsi/admin/opsi/class_opsi.inc @@ -282,6 +282,33 @@ class opsi extends gosaSupportDaemon } + /*! \brief Returns a list of netboot products. + @param + @return + */ + public function get_full_product_host_information($host = "") + { + /* Append host attribute to query data + */ + $data = array(); + if(!empty($host)){ + $data['hostId'] = trim($host); + } + + $res = $this->send_data("gosa_opsi_get_full_product_host_information",$this->target,$data,TRUE); + print_a($res); + $items = array(); + if(isset($res['XML'][0]['ITEM'])){ + foreach($res['XML'][0]['ITEM'] as $entry){ + $e = array("DESC" => $entry['DESCRIPTION'][0]['VALUE'], + "NAME" => $entry['PRODUCTID'][0]['VALUE']); + $items[$entry['PRODUCTID'][0]['VALUE']] = $e; + } + } + return($items); + } + + /*! \brief Returns a list of all product properties. \ . Additionally you can specify the host parameter to \ . get host specific product properties