summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: ccb05fb)
raw | patch | inline | side by side (parent: ccb05fb)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 25 Feb 2008 09:37:04 +0000 (09:37 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 25 Feb 2008 09:37:04 +0000 (09:37 +0000) |
-Tagging works again.
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5-lhm@9098 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.5-lhm@9098 594d385d-05f5-0310-b6e9-bd551577e9d8
include/class_plugin.inc | patch | blob | history | |
plugins/admin/departments/class_departmentGeneric.inc | patch | blob | history |
index 9a25100ff3f3e3b25b20975f4325c4c02c8999aa..f3b6f2da34511a36be824bf07d519eeb54122397 100644 (file)
--- a/include/class_plugin.inc
+++ b/include/class_plugin.inc
/* Save unit tags */
var $gosaUnitTag= "";
+ var $skipTagging= FALSE;
/*!
\brief Used standard values
function tag_attrs($at, $dn= "", $tag= "", $show= false)
{
+ /* Skip tagging?
+ If this is called from departmentGeneric, we have to skip this
+ tagging procedure.
+ */
+ if($this->skipTagging){
+ return;
+ }
+
/* No dn? Self-operation... */
if ($dn == ""){
$dn= $this->dn;
diff --git a/plugins/admin/departments/class_departmentGeneric.inc b/plugins/admin/departments/class_departmentGeneric.inc
index 18f8db4abe4574ff700d5cf047b0269e92f22e02..0dc9495faec5c5be27cdf62351038a2ec8d65bbb 100644 (file)
var $orig_dn= "";
var $is_administrational_unit= false;
var $gosaUnitTag= "";
+ var $initially_was_tagged = FALSE;
var $rec_dst=false; // Destination for recursive move
var $rec_src=false; // Source for recursive move
/* Is administrational Unit? */
if ($dn != "new" && in_array_ics('gosaAdministrativeUnit', $this->attrs['objectClass'])){
$this->is_administrational_unit= true;
+ $this->initially_was_tagged = TRUE;
}
}
/* Add tag objects if needed */
if ($this->is_administrational_unit){
- if(!in_array_ics("gosaAdministrativeUnit",$this->objectclasses)){
+ if(!$this->initially_was_tagged){
$this->objectclasses[]= "gosaAdministrativeUnit";
$this->gosaUnitTag= "";
+ $this->initially_was_tagged = TRUE;
}
if ($this->gosaUnitTag == ""){
}
}
- plugin::save();
+ $this->skipTagging = TRUE;
+ plugin::save();
/* Remove tag information if needed */
if (!$this->is_administrational_unit){
}
}
$this->attrs['objectClass']= $tmp;
-
- if(!$has_unit_tag && isset($this->attrs['gosaUnitTag'])){
- $this->attrs['gosaUnitTag']= array();
- }
+ $this->attrs['gosaUnitTag']= array();
+ $this->gosaUnitTag = "";
}
/* Write back to ldap */