From: hickert Date: Wed, 6 Apr 2011 13:41:38 +0000 (+0000) Subject: Updated listing of config items X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=4f285005f04a1839779560d0ed3534fc039edffe;p=gosa.git Updated listing of config items git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20659 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-plugins/goto-ng/admin/newConfigManagement/class_newConfigManagement.inc b/gosa-plugins/goto-ng/admin/newConfigManagement/class_newConfigManagement.inc index f0b75b544..6910f6559 100644 --- a/gosa-plugins/goto-ng/admin/newConfigManagement/class_newConfigManagement.inc +++ b/gosa-plugins/goto-ng/admin/newConfigManagement/class_newConfigManagement.inc @@ -170,10 +170,13 @@ class newConfigManagement extends plugin // Walk through each entry and then try to add it to the model foreach($sLen as $unused => $itemPath){ + // Do not add the root element '/' + if($itemPath == "/") continue; + $type = $res[$itemPath]; // Root installation objects do not have a name, so we use 'root' here. - $targetPath = trim($path."/root/".$itemPath); + $targetPath = trim($path."/".$itemPath); // Remove trailing and duplicated slashes $targetPath = rtrim($targetPath, '/'); @@ -207,7 +210,6 @@ class newConfigManagement extends plugin */ function setCurrentContainer($cont) { - $this->selectedContainer = $cont; // Update list of items within the selected container. @@ -317,6 +319,7 @@ class newConfigManagement extends plugin return; } $this->installationMethods = $res; + if(!count($this->installationMethods)){ $this->errorMessage = _("No selectable install methods returned!"); msg_dialog::display(_("Setup"), $this->errorMessage , ERROR_DIALOG); @@ -327,6 +330,13 @@ class newConfigManagement extends plugin foreach($this->installationMethods as $method => $items){ foreach($items['items'] as $itemName => $item){ $this->cfgItemMap[$itemName] = $method; + + // This enables us to create the first level of config items when + // a release is selected. + if($item['name'] == "/"){ + $this->installationMethods[$method]['items']['Release'] = + &$this->installationMethods[$method]['items'][$itemName]; + } } } }