summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 980f5f8)
raw | patch | inline | side by side (parent: 980f5f8)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 19 May 2011 07:06:09 +0000 (07:06 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Thu, 19 May 2011 07:06:09 +0000 (07:06 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@20871 594d385d-05f5-0310-b6e9-bd551577e9d8
diff --git a/gosa-plugins/goto-ng/admin/newConfigManagement/class_ConfigManagement.inc b/gosa-plugins/goto-ng/admin/newConfigManagement/class_ConfigManagement.inc
index b474d4ece18718c502f6ab782426b34543e8d8fe..3f9a525955a9577d5fc5f2dc334c15e360273c92 100644 (file)
function updateDataModel()
{
// Recreate the data model, to have a clean and fresh instance.
- $this->dataModel = new ConfigManagementDataModel();
-
+ $this->dataModel = new ConfigManagementDataModel($this->config);
// Load templates from the backend and append them on the base
$rpc = $this->config->getRpcHandle();
{
$item = $this->dataModel->getItemByDn($ids[0]);
- if(!$item) return;
-
$release = $this->getReleasePart($item['path']);
$path = $this->getItemPath($item['path']);
$method = $this->cfgItemMap[$item['type']];
diff --git a/gosa-plugins/goto-ng/admin/newConfigManagement/class_ConfigManagementDataModel.inc b/gosa-plugins/goto-ng/admin/newConfigManagement/class_ConfigManagementDataModel.inc
index d73e35f06d0227c2b6ff655294e20fe0d6d9ac9e..b76c1746546196267432b5d387aa57fc3c037b7a 100644 (file)
public $typeToPath = array();
public $idToPath = array();
public $dnToPath = array();
+ public $config = NULL;
- function __construct()
+ function __construct($config)
{
+ $this->config = &$config;
$this->data = array();
$this->data['linear'] = array();
$this->data['recursive'] = array();
if($path == ""){
$parentItem = &$this->data['recursive'];
$parentId = NULL;
- $parentDn = "";
+ $parentDn = $this->config->current['BASE'];
}elseif(isset($this->data['linear'][$path])){
$parentItem = &$this->data['linear'][$path]['children'];
$parentId = $this->data['linear'][$path]['id'];
$this->data['linear'][$entryPath] = &$parentItem[$entryPath];
$this->idToPath[$entryId] = $entryPath;
- $this->idToPath[$entryDn] = $entryPath;
+ $this->dnToPath[$entryDn] = $entryPath;
+
$this->typeToPath[$type][$name] = $entryPath;
return($entryId);