Code

Updated Server copy & paste
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 15 Jun 2007 06:16:20 +0000 (06:16 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 15 Jun 2007 06:16:20 +0000 (06:16 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@6596 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/admin/systems/class_goMailServer.inc
plugins/admin/systems/class_goShareServer.inc
plugins/admin/systems/class_workstationStartup.inc

index 2d1f08c500a2394cd91723945f4423f00b35ef8d..b97c3955d9b48435e0e57f0677a120e1b66e1cec 100644 (file)
@@ -690,7 +690,7 @@ class goMailServer extends goService{
     plugin::PrepareForCopyPaste($source);
 
     $source_o = new goMailServer($this->config,$source['dn']);
-    foreach(array("postfixMyNetworks","postfixTransportTable","postfixSenderRestrictions","postfixRecipientRestrictions","postfixMyDestinations") as $attr){
+    foreach(array("postfixMyDomain","postfixMyhostname","postfixMyNetworks","postfixTransportTable","postfixSenderRestrictions","postfixRecipientRestrictions","postfixMyDestinations") as $attr){
       $this->$attr = $source_o->$attr;
     }
   }
index 64b6944577873b429940110bdf308b76908e0d9c..6b7f39aa382c514633f11ddc96f9bfc75fe96d00 100644 (file)
@@ -362,6 +362,24 @@ class goShareServer extends goService{
   }
 
 
+  function PrepareForCopyPaste($source)
+  {
+    plugin::PrepareForCopyPaste($source);
+
+    $tmp =array();
+    if(isset($source['goExportEntry'])){
+      if(isset($source['goExportEntry']['count'])){
+        for($i= 0; $i<$source['goExportEntry']['count']; $i++){
+          $entry= $source['goExportEntry'][$i];
+          $tmp[preg_replace('/\|.*$/', '', $entry)]= $entry;
+        }
+      }
+    }
+    $this->goExportEntryList = $tmp;
+    $this->goExportEntry = $tmp;
+  }
+
+
   /* Return plugin informations for acl handling */
   function plInfo()
   {
index ab20b1b9e2a624e8cbabebdf1d923ddfb6f657bd..a0f6199070612e57ac007ed79b109691cdaa5c94 100644 (file)
@@ -1161,8 +1161,12 @@ class workstartup extends plugin
 
   function PrepareForCopyPaste($source)
   {
-      /* Get arrays */
-    foreach (array("gotoModules", "gotoAutoFs", "gotoFilesystem") as $val){
+    plugin::PrepareForCopyPaste($source);    
+
+
+    /* Get arrays */
+    foreach (array("gotoModules", "gotoAutoFs", "gotoFilesystem","gotoKernelParameters") as $val){  
+      $this->$val = array();
       if (isset($source["$val"]["count"])){
         for ($i= 0; $i<$source["count"]; $i++){
           if (isset($source["$val"][$i])){
@@ -1174,6 +1178,18 @@ class workstartup extends plugin
       $this->$val= array_unique($this->$val);
     }
 
+        /* Prepare Shares */
+    if((isset($source['gotoShare']))&&(is_array($source['gotoShare']))){
+      unset($source['gotoShare']['count']);
+      foreach($source['gotoShare'] as $share){
+        $tmp = $tmp2 = array();
+        $tmp = split("\|",$share);
+        $tmp2['server']      =$tmp[0];
+        $tmp2['name']        =$tmp[1];
+        $tmp2['mountPoint']  =$tmp[2];
+        $this->gotoShares[$tmp[1]."|".$tmp[0]]=$tmp2;
+      }
+    }
   }
 
   /* Return plugin informations for acl handling */