Code

Updated ogroups
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 17 Mar 2008 07:10:41 +0000 (07:10 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Mon, 17 Mar 2008 07:10:41 +0000 (07:10 +0000)
-Added macAddress to object cache, to be able to send DaemonEvents for all member objects.

git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@9887 594d385d-05f5-0310-b6e9-bd551577e9d8

gosa-core/plugins/admin/ogroups/class_ogroup.inc

index 127948767ca4ee4eb83bdd5682e0107cc6e8104d..b833a9186d5db04e62c5b92414c98e845fa4113d 100644 (file)
@@ -501,7 +501,7 @@ class ogroup extends plugin
          it seams that this entry was removed 
        */ 
       /* Try to resolv the entry again, if it still fails, display error msg */
-      $ldap->cat($dn, array("cn", "sn", "givenName", "ou", "description", "objectClass"));
+      $ldap->cat($dn, array("cn", "sn", "givenName", "ou", "description", "objectClass", "macAddress"));
 
       /* It has failed, add entry with type flag I (Invalid)*/
       if (!$ldap->success()){
@@ -525,6 +525,13 @@ class ogroup extends plugin
           $this->objcache[$attrs["dn"]]= array("text" => "$name", "type" => "$type");
         }
         $this->objcache[$attrs["dn"]]['objectClass']  = $attrs['objectClass'];
+
+        if(isset($attrs['macAddress'][0])){
+          $this->objcache[$attrs["dn"]]['macAddress']  = $attrs['macAddress'][0];
+        }else{
+          $this->objcache[$attrs["dn"]]['macAddress']  = "";
+        }
+
         if(isset($attrs['uid'])){
           $this->objcache[$attrs["dn"]]['uid']          = $attrs['uid'];
         }