From 8f1cc229b3a741ab94944c3c3f3caf247b9140a5 Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 20 Nov 2007 06:55:23 +0000 Subject: [PATCH] Fixed undefined index in objectGroup initialization. Added remove too, ogroup layer menu git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@7817 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/ogroups/class_divListOGroup.inc | 7 +++-- plugins/admin/ogroups/tabs_ogroups.inc | 28 +++++++++++-------- 2 files changed, 21 insertions(+), 14 deletions(-) diff --git a/plugins/admin/ogroups/class_divListOGroup.inc b/plugins/admin/ogroups/class_divListOGroup.inc index 720f7530f..c0e96a7c9 100755 --- a/plugins/admin/ogroups/class_divListOGroup.inc +++ b/plugins/admin/ogroups/class_divListOGroup.inc @@ -176,8 +176,11 @@ class divListOGroup extends MultiSelectWindow /* Multiple options */ $s.= "..|---|\n"; - $s.= "..|". - " "._("Edit")."|"."multiple_edit|\n"; +# $s.= "..|". +# " "._("Edit")."|"."multiple_edit|\n"; + + $s.= "..|". + " "._("Remove")."|"."remove_multiple_ogroups/|\n"; /* Add multiple copy & cut icons */ if(is_object($this->parent->CopyPasteHandler) && preg_match("/(c.*w|w.*c)/",$acl_all)){ diff --git a/plugins/admin/ogroups/tabs_ogroups.inc b/plugins/admin/ogroups/tabs_ogroups.inc index d820aa5b8..3485bb79f 100644 --- a/plugins/admin/ogroups/tabs_ogroups.inc +++ b/plugins/admin/ogroups/tabs_ogroups.inc @@ -14,10 +14,12 @@ class ogrouptabs extends tabs $usePhoneTab = false; foreach($this->by_object['ogroup']->memberList as $dn => $val){ - $obj = $this->by_object['ogroup']->objcache[$dn]; - if(isset($obj['objectClass'])){ - if(in_array("goFonAccount",$obj['objectClass'])){ - $usePhoneTab = true; + if(isset($this->by_object['ogroup']->objcache[$dn])){ + $obj = $this->by_object['ogroup']->objcache[$dn]; + if(isset($obj['objectClass'])){ + if(in_array("goFonAccount",$obj['objectClass'])){ + $usePhoneTab = true; + } } } } @@ -61,14 +63,16 @@ class ogrouptabs extends tabs if(!isset($this->by_object['phonequeue'])){ foreach($this->by_object['ogroup']->memberList as $dn => $val){ - $obj = $this->by_object['ogroup']->objcache[$dn]; - - if(isset($obj['objectClass'])){ - if(in_array("goFonAccount",$obj['objectClass'])){ - $this->by_name['phonequeue']= _("Phone queue"); - $this->by_object['phonequeue']= new phonequeue($this->config, $this->dn); - $this->by_object['phonequeue']->parent= &$this; - break; + if(isset($this->by_object['ogroup']->objcache[$dn])){ + $obj = $this->by_object['ogroup']->objcache[$dn]; + + if(isset($obj['objectClass'])){ + if(in_array("goFonAccount",$obj['objectClass'])){ + $this->by_name['phonequeue']= _("Phone queue"); + $this->by_object['phonequeue']= new phonequeue($this->config, $this->dn); + $this->by_object['phonequeue']->parent= &$this; + break; + } } } } -- 2.30.2