summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: d46f234)
raw | patch | inline | side by side (parent: d46f234)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 11 Apr 2011 06:38:36 +0000 (06:38 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 11 Apr 2011 06:38:36 +0000 (06:38 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20670 594d385d-05f5-0310-b6e9-bd551577e9d8
diff --git a/gosa-plugins/goto-ng/admin/newConfigManagement/class_ConfigManagementDataModel.inc b/gosa-plugins/goto-ng/admin/newConfigManagement/class_ConfigManagementDataModel.inc
index 062d4681879094968d2d41a611cc6232e9cba6cd..16dd8fcc072272903fbacfae5867892d091f4aaa 100644 (file)
return($this->data);
}
+ function removeItem($path)
+ {
+ $item = &$this->data['linear'][$path];
+ $parent = &$this->data['linear'][$item['parentPath']];
+ unset($parent['children'][$path]);
+ unset($this->data['linear'][$path]);
+ }
function addItem($type, $path, $name, $values = array(), $status = "")
{
diff --git a/gosa-plugins/goto-ng/admin/newConfigManagement/class_newConfigManagement.inc b/gosa-plugins/goto-ng/admin/newConfigManagement/class_newConfigManagement.inc
index e146ea10d7c12d72913fc55aadc28fe6b7e7dd9a..5812db35ec426d46ef626063ec17b9e992e52d1c 100644 (file)
$path = $item['values']['__path'];
$rpc = $this->config->getRpcHandle();
$rpc->removeConfigItem($release, $path);
-
if(!$rpc->success()){
msg_dialog::display(_("Error"), sprintf(_("Failed to remove: %s"), $rpc->get_error()),ERROR_DIALOG);
return(NULL);
+ }else{
+ $this->dataModel->removeItem($item['path']);
}
}