From: cajus Date: Sat, 8 Mar 2008 17:37:09 +0000 (+0000) Subject: Fixed conversation errors X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=f7f1e11d587a4d7e64565b05033dc2f04948b03e;p=gosa.git Fixed conversation errors git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@9469 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-plugins/goto/admin/ogroups/goto/class_termgroup.inc b/gosa-plugins/goto/admin/ogroups/goto/class_termgroup.inc index 2299d1adf..40bd1a987 100644 --- a/gosa-plugins/goto/admin/ogroups/goto/class_termgroup.inc +++ b/gosa-plugins/goto/admin/ogroups/goto/class_termgroup.inc @@ -211,37 +211,40 @@ class termgroup extends plugin if ($_POST['saction'] != "wake"){ foreach($member as $dn => $object){ - /* Get object */ - $ldap->cat($dn,array("objectClass")); - $res = $ldap->fetch(); - $attrs = array(); - - /* Add FAI state */ - $attrs['FAIstate'] = ""; - if(isset($this->mapActions[$_POST['saction']])){ - $attrs['FAIstate'] = $this->mapActions[$_POST ['saction']]; - } - - /* Fix objectClass index */ - for($i = 0; $i < $res['objectClass']['count'] ; $i ++){ - $attrs['objectClass'][] = $res['objectClass'][$i]; - } - - /* Check if we must add the objectClass */ - if(($attrs['FAIstate'] != "") && (!in_array("FAIobject",$attrs['objectClass']))){ - $attrs['objectClass'][] = "FAIobject"; - } - - if($attrs['FAIstate'] == ""){ - $attrs['FAIstate'] = array(); - } - - $ldap->cd($dn); - $ldap->modify($attrs); - if (!$ldap->success()){ - msg_dialog::display(_("LDAP error"), msgPool::ldaperror($ldap->get_error(), $dn, LDAP_MOD, get_class())); + /* Get object */ + $ldap->cat($dn,array("objectClass")); + $res = $ldap->fetch(); + $attrs = array(); + + /* Add FAI state */ + $attrs['FAIstate'] = ""; + if(isset($this->mapActions[$_POST['saction']])){ + $attrs['FAIstate'] = $this->mapActions[$_POST ['saction']]; + } + + /* Fix objectClass index */ + for($i = 0; $i < $res['objectClass']['count'] ; $i ++){ + $attrs['objectClass'][] = $res['objectClass'][$i]; + } + + /* Check if we must add the objectClass */ + if(($attrs['FAIstate'] != "") && (!in_array("FAIobject",$attrs['objectClass']))){ + $attrs['objectClass'][] = "FAIobject"; + } + + if($attrs['FAIstate'] == ""){ + $attrs['FAIstate'] = array(); + } + + $ldap->cd($dn); + $ldap->modify($attrs); + + if (!$ldap->success()){ + msg_dialog::display(_("LDAP error"), msgPool::ldaperror($ldap->get_error(), $dn, LDAP_MOD, get_class())); + } } } + } @@ -310,6 +313,7 @@ class termgroup extends plugin return ($smarty->fetch (get_template_path('termgroup.tpl', TRUE, dirname(__FILE__)))); } + function save_object() { plugin::save_object(); @@ -373,8 +377,8 @@ class termgroup extends plugin if (!$ldap->success()){ msg_dialog::display(_("LDAP error"), msgPool::ldaperror($ldap->get_error(), $this->dn, LDAP_MOD, get_class())); } - } + static function plInfo() { diff --git a/gosa-plugins/netatalk/personal/netatalk/class_netatalk.inc b/gosa-plugins/netatalk/personal/netatalk/class_netatalk.inc index d4298095b..5de5b9d01 100644 --- a/gosa-plugins/netatalk/personal/netatalk/class_netatalk.inc +++ b/gosa-plugins/netatalk/personal/netatalk/class_netatalk.inc @@ -187,7 +187,6 @@ class netatalk extends plugin { } else { $display = $this->show_enable_header(msgPool::addFeaturesButton(_("netatalk")), msgPool::featuresDisabled(_("netatalk")), TRUE); } - } return ($display); } }