Code

Fixed copy & paste for environment.
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 10 Oct 2007 07:18:55 +0000 (07:18 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Wed, 10 Oct 2007 07:18:55 +0000 (07:18 +0000)
Some attributes werent copied.

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

plugins/personal/environment/class_environment.inc

index b569454ab3f8f8bd40d817401e67f4bfcc3747e0..8fb251c5145653bb53c0d5d21a6dcb1b4975f8e3 100644 (file)
@@ -52,8 +52,8 @@ class environment extends plugin
   /* Kiosk profile */
   var $kiosk_enabled      = FALSE;
   var $gotoKioskProfile   = "";     // The selected Kiosk Profile
-  var $gotoKioskiProfile_Server    = "";     // The selected Kiosk Profile
-  var $gotoKioskiProfile_Profile   = "";     // The selected Kiosk Profile
+  var $gotoKioskProfile_Server    = "";     // The selected Kiosk Profile
+  var $gotoKioskProfile_Profile   = "";     // The selected Kiosk Profile
   var $gotoKioskProfiles  = array();// All available Kiosk profiles
 
   /* Hotplug Devices */
@@ -67,7 +67,7 @@ class environment extends plugin
   /* general settings */
   // Sets the attributes which will kept on page reload, which will be saved, ...
 
-  var $CopyPasteVars      = array("gotoHotplugDevices","gotoAvailableShares","gotoShareSelections","gotoPrinterSel","gotoProfileFlagL","gotoXResolutions","gotoProfileFlagC","gotoProfileServers","useProfile","is_group","in_dialog","OrigCn");
+  var $CopyPasteVars      = array("gotoHotplugDevices","gotoAvailableShares","gotoShareSelections","gotoPrinterSel","gotoProfileFlagL","gotoXResolutions","gotoProfileFlagC","gotoProfileServers","useProfile","is_group","in_dialog","OrigCn","gotoKioskProfile_Server","gotoKioskProfile_Profile");
 
   var $attributes         = array("uid","gotoProfileServer","gotoProfileFlags","gotoHotplugDeviceDN",
       "gotoXResolution","gotoProfileQuota",
@@ -1283,6 +1283,18 @@ class environment extends plugin
   }
 
 
+  function PrepareForCopyPaste($source)
+  {
+    plugin::PrepareForCopyPaste($source);
+
+    $class= get_class($this);
+    $o_source = new $class($this->config,$source['dn']);
+    foreach($this->CopyPasteVars as $attr){
+      $this->$attr = $o_source->$attr;  
+    }
+  }
+
+
   function saveCopyDialog()
   {
     if(isset($_POST['cn'])){