Code

Added support for comments in divlist
[gosa.git] / plugins / admin / systems / tabs_workstation.inc
index 4f59e1d5685e0f424a7d3aaca32240cb626af6da..4afdf8333840e5ed56a086f922ff74a80e8e2b58 100644 (file)
@@ -5,16 +5,30 @@ class worktabs extends tabs
 
   function worktabs($config, $data, $dn)
   {
-    tabs::tabs($config, $data, $dn);
+    /* Save dn */
+    $this->dn= $dn;
+    $this->config= $config;
+
+    foreach ($data as $tab){
+      if($tab['CLASS'] == "printgeneric"){
+        $this->by_name[$tab['CLASS']]= $tab['NAME'];
+        $this->by_object[$tab['CLASS']]= new $tab['CLASS']($this->config, $this->dn,$this);
+        $this->by_object[$tab['CLASS']]->parent= &$this;
+      }else{
+        $this->by_name[$tab['CLASS']]= $tab['NAME'];
+        $this->by_object[$tab['CLASS']]= new $tab['CLASS']($this->config, $this->dn);
+        $this->by_object[$tab['CLASS']]->parent= &$this;
+      }
+      /* Initialize current */
+      if ($this->current == ""){
+        $this->current= $tab['CLASS'];
+      }
+    }
   }
 
   function save_object($save_current= FALSE)
   {
     tabs::save_object($save_current);
-
-    /* Update reference, transfer variables */
-    $this->by_object['termstartup']->gotoTerminalPath=
-      $this->by_object['workgeneric']->gotoTerminalPath;
   }
 
 
@@ -35,6 +49,8 @@ class worktabs extends tabs
       $this->by_object['printgeneric']->remove_from_parent();
     }
 
+    /* Fix tagging if needed */
+    $baseobject->handle_object_tagging();
   }
 
 }