From 6a4905965e51858ba17ad997284e7d65f8c02606 Mon Sep 17 00:00:00 2001 From: hickert Date: Fri, 11 Apr 2008 10:23:59 +0000 Subject: [PATCH] Fixed saving for existing entries git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10354 594d385d-05f5-0310-b6e9-bd551577e9d8 --- gosa-plugins/fai/admin/fai/class_FAI.inc | 4 +++- gosa-plugins/fai/admin/fai/class_faiHook.inc | 4 ++++ gosa-plugins/fai/admin/fai/class_faiPackage.inc | 4 ++++ gosa-plugins/fai/admin/fai/class_faiPartitionTable.inc | 4 ++++ gosa-plugins/fai/admin/fai/class_faiScript.inc | 6 ++++++ gosa-plugins/fai/admin/fai/class_faiTemplate.inc | 4 ++++ gosa-plugins/fai/admin/fai/class_faiVariable.inc | 4 ++++ 7 files changed, 29 insertions(+), 1 deletion(-) diff --git a/gosa-plugins/fai/admin/fai/class_FAI.inc b/gosa-plugins/fai/admin/fai/class_FAI.inc index 1fef153b6..fc4f5c185 100644 --- a/gosa-plugins/fai/admin/fai/class_FAI.inc +++ b/gosa-plugins/fai/admin/fai/class_FAI.inc @@ -170,7 +170,9 @@ class FAI /* Dont't try to modify non FAIclasses */ if(!preg_match("/[^,]+,".normalizePreg(get_ou("faiou"))."/",$obj_dn)){ - echo "PLEASE check fai class handling in ".__LINE__." -> ".__FILE__; + trigger_error("PLEASE check fai class handling in ".__LINE__." -> ".__FILE__); + echo "
-->".$Current_DN."
"; + echo "
-->".$obj_dn."
"; }else{ /* Get source object and check if it is a base FAIclass diff --git a/gosa-plugins/fai/admin/fai/class_faiHook.inc b/gosa-plugins/fai/admin/fai/class_faiHook.inc index 849643276..746282057 100644 --- a/gosa-plugins/fai/admin/fai/class_faiHook.inc +++ b/gosa-plugins/fai/admin/fai/class_faiHook.inc @@ -79,6 +79,10 @@ class faiHook extends plugin $this->SubObjects[$objects['cn']] = $objects; } } + $this->is_new = FALSE; + if($this->dn == "new"){ + $this->is_new =TRUE; + } $this->ui = get_userinfo(); } diff --git a/gosa-plugins/fai/admin/fai/class_faiPackage.inc b/gosa-plugins/fai/admin/fai/class_faiPackage.inc index fe7989ea1..a44ffd345 100644 --- a/gosa-plugins/fai/admin/fai/class_faiPackage.inc +++ b/gosa-plugins/fai/admin/fai/class_faiPackage.inc @@ -158,6 +158,10 @@ class faiPackage extends plugin if ($this->dn != "new"){ $this->newDialogShown= true; } + $this->is_new = FALSE; + if($this->dn == "new"){ + $this->is_new =TRUE; + } } diff --git a/gosa-plugins/fai/admin/fai/class_faiPartitionTable.inc b/gosa-plugins/fai/admin/fai/class_faiPartitionTable.inc index a3ed119a8..c721a8ed7 100644 --- a/gosa-plugins/fai/admin/fai/class_faiPartitionTable.inc +++ b/gosa-plugins/fai/admin/fai/class_faiPartitionTable.inc @@ -96,6 +96,10 @@ class faiPartitionTable extends plugin } } } + $this->is_new = FALSE; + if($this->dn == "new"){ + $this->is_new =TRUE; + } ksort($this->disks); } diff --git a/gosa-plugins/fai/admin/fai/class_faiScript.inc b/gosa-plugins/fai/admin/fai/class_faiScript.inc index d94b760c2..c94c49d58 100644 --- a/gosa-plugins/fai/admin/fai/class_faiScript.inc +++ b/gosa-plugins/fai/admin/fai/class_faiScript.inc @@ -86,6 +86,12 @@ class faiScript extends plugin } } + + $this->is_new = FALSE; + if($this->dn == "new"){ + $this->is_new =TRUE; + } + $this->ui = get_userinfo(); } diff --git a/gosa-plugins/fai/admin/fai/class_faiTemplate.inc b/gosa-plugins/fai/admin/fai/class_faiTemplate.inc index ab20b94bb..018d8596c 100644 --- a/gosa-plugins/fai/admin/fai/class_faiTemplate.inc +++ b/gosa-plugins/fai/admin/fai/class_faiTemplate.inc @@ -82,6 +82,10 @@ class faiTemplate extends plugin $this->SubObjects[$objects['cn']] = $objects; } } + $this->is_new = FALSE; + if($this->dn == "new"){ + $this->is_new =TRUE; + } $this->ui = get_userinfo(); } diff --git a/gosa-plugins/fai/admin/fai/class_faiVariable.inc b/gosa-plugins/fai/admin/fai/class_faiVariable.inc index 21722813e..af021e7df 100644 --- a/gosa-plugins/fai/admin/fai/class_faiVariable.inc +++ b/gosa-plugins/fai/admin/fai/class_faiVariable.inc @@ -82,6 +82,10 @@ class faiVariable extends plugin } } + $this->is_new = FALSE; + if($this->dn == "new"){ + $this->is_new =TRUE; + } $this->ui = get_userinfo(); } -- 2.30.2