Code

Updated system management
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 14 Oct 2008 08:55:23 +0000 (08:55 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Tue, 14 Oct 2008 08:55:23 +0000 (08:55 +0000)
-After adding "ieee802Device" to winstations they were detected as Components. Updated the checks.

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

gosa-plugins/systems/admin/systems/class_systemManagement.inc

index 21f1032075e89b22e177d762bcf91b760c1e9b47..c9b4996aaa30116bafdebd5f94834e1899ba9b0a 100644 (file)
@@ -1326,8 +1326,9 @@ class systems extends plugin
           $terminal['type']   = "Q";
           $terminal['is_new'] = $add;
         }
-      } elseif (in_array_ics('ieee802Device', $value["objectClass"])){
-
+      } elseif (in_array_ics('ieee802Device', $value["objectClass"]) && 
+        !( in_array_ics('sambaAccount', $value["objectClass"]) || in_array_ics('sambaSamAccount', $value["objectClass"]))){
+        $type= "winstation";
         $acl = $ui->get_permissions($value['dn'],"component/componentGeneric");
         if($add != "" || preg_match("/r/",$acl)) {
 
@@ -1495,6 +1496,9 @@ class systems extends plugin
     $type= "";
     if (in_array_ics('gosa_opsi_client', $classes)){
       $type= "opsi_client";
+    }elseif (in_array_ics('sambaAccount', $classes) ||
+        in_array_ics('sambaSamAccount', $classes)){
+      $type= "winstation";
     }elseif (in_array_ics('ieee802Device', $classes)){
       $type= "component";
     }elseif (in_array_ics('gotoTerminal', $classes)){
@@ -1511,9 +1515,6 @@ class systems extends plugin
       $type= "ArpNewDevice";
     }elseif (in_array_ics('GOhard', $classes)){
       $type= "NewDevice";
-    }elseif (in_array_ics('sambaAccount', $classes) ||
-        in_array_ics('sambaSamAccount', $classes)){
-      $type= "winstation";
     }
     return ($type);
   }