summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f603e16)
raw | patch | inline | side by side (parent: f603e16)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 5 Apr 2006 08:53:57 +0000 (08:53 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 5 Apr 2006 08:53:57 +0000 (08:53 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2986 594d385d-05f5-0310-b6e9-bd551577e9d8
include/class_CopyPasteHandler.inc | patch | blob | history | |
include/class_plugin.inc | patch | blob | history |
index d8fb89ab3acf6febd495f617cc521ab4b3f70aa5..37e9a2e951c02c3c9d4acbbfd6295318a2c687e6 100644 (file)
$this->objectdn = $obj->dn;
$this->current = $emptyObj;
foreach($obj->by_object as $name => $obj){
- foreach($obj->attributes as $attr){
- $this->current->by_object[$name]->$attr = $obj->$attr;
- }
- if(isset($obj->CopyPasteVars)){
- foreach($obj->CopyPasteVars as $attr){
- $this->current->by_object[$name]->$attr = $obj->$attr;
- }
- }
+
+ $this->current->by_object[$name]->PrepareForCopyPaste($obj);
+
foreach(array("is_account") as $attr){
if(isset($obj->$attr)){
$this->current->by_object[$name]->$attr = $obj->$attr;
index 1e6b5ba215374a72be520cf78f83e245dbc945ff..dc24a4b173747018dd277431e17cdded32e52fef 100644 (file)
--- a/include/class_plugin.inc
+++ b/include/class_plugin.inc
return(array("string"=>"","status"=>""));
}
+ function PrepareForCopyPaste($source){
+ $todo = $this->attributes;
+ if(isset($this->CopyPasteVars)){
+ $todo = array_merge($todo,$this->CopyPasteVars);
+ }
+
+ foreach($todo as $var){
+ $this->$var = $source->$var;
+ }
+ }
+
}
// vim:tabstop=2:expandtab:shiftwidth=2:filetype=php:syntax:ruler:
?>