Code

Updated get_ou it receives values from the config registry now.
[gosa.git] / gosa-plugins / goto / admin / systems / goto / class_terminalService.inc
index 28846fd5049d62352e1918fbde38063deb774000..a7d91c1ddb742433f16dea36b118433a3a0fd924 100644 (file)
@@ -198,7 +198,7 @@ class termservice extends plugin
 
     /* Load phone hardware list 
      */
-    $tmp = get_sub_list("(objectClass=goFonHardware)","",array(get_ou("phoneRDN")), 
+    $tmp = get_sub_list("(objectClass=goFonHardware)","",array(get_ou("group", "ogroupRDN") ), 
                   $this->config->current['BASE'],array("cn","description"), GL_NO_ACL_CHECK);
     foreach($tmp as $attrs){
       $cn= $attrs['cn'][0];
@@ -216,13 +216,13 @@ class termservice extends plugin
      */
     $deps_a = array(
         get_people_ou(),
-        get_ou("ogroupRDN"),
-        get_ou("serverRDN"),
-        get_ou("terminalRDN"),
-        get_ou("workstationRDN"),
-        get_ou("printerRDN"),
-        get_ou("componentRDN"),
-        get_ou("phoneRDN"));
+        get_ou("group", "ogroupRDN") ,
+        get_ou("group", "ogroupRDN") ,
+        get_ou("group", "ogroupRDN") ,
+        get_ou("group", "ogroupRDN") ,
+        get_ou("group", "ogroupRDN") ,
+        get_ou("group", "ogroupRDN") ,
+        get_ou("group", "ogroupRDN") );
 
     $tmp = get_sub_list("(goFonHardware=*)","",$deps_a,$this->config->current['BASE'],
         array('cn','dn','goFonHardware'),GL_NO_ACL_CHECK);
@@ -650,7 +650,7 @@ class termservice extends plugin
            */
           $p = $this->parent->by_object['ogroup'];
           foreach($p->memberList as $dn => $obj){
-            if(preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/",$dn)) continue;
+            if(preg_match("/".preg_quote(get_ou("group", "ogroupRDN") , '/')."/",$dn)) continue;
             if(isset($p->objcache[$dn]['macAddress']) && !empty($p->objcache[$dn]['macAddress'])){
               $macs[] = $p->objcache[$dn]['macAddress'];
             }
@@ -660,7 +660,7 @@ class termservice extends plugin
           /* We are a workstation. Add current mac.
            */
           $mac = $this->parent->by_object['workgeneric']->netConfigDNS->macAddress;
-          if(!empty($mac) && !preg_match("/".preg_quote(get_ou("systemIncomingRDN"), '/')."/",$this->orig_dn)){
+          if(!empty($mac) && !preg_match("/".preg_quote(get_ou("group", "ogroupRDN") , '/')."/",$this->orig_dn)){
             $macs[] = $mac;
           }
         }