From eee7e804c226a942a84d325c6c65546a3f8fbc9e Mon Sep 17 00:00:00 2001 From: hickert Date: Tue, 21 Mar 2006 07:38:04 +0000 Subject: [PATCH] Fixed group copy & paste git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2870 594d385d-05f5-0310-b6e9-bd551577e9d8 --- plugins/admin/groups/class_groupGeneric.inc | 3 ++- plugins/admin/groups/class_groupMail.inc | 26 +++++++++---------- .../admin/groups/class_groupManagement.inc | 11 +++++++- 3 files changed, 25 insertions(+), 15 deletions(-) diff --git a/plugins/admin/groups/class_groupGeneric.inc b/plugins/admin/groups/class_groupGeneric.inc index 63fc8f760..9659a7042 100644 --- a/plugins/admin/groups/class_groupGeneric.inc +++ b/plugins/admin/groups/class_groupGeneric.inc @@ -821,7 +821,8 @@ class group extends plugin $dis = " disabled "; } - $str =" + $str ="

"._("Group settings")."

+
". _("Group name"). diff --git a/plugins/admin/groups/class_groupMail.inc b/plugins/admin/groups/class_groupMail.inc index 0076c7317..533347dda 100644 --- a/plugins/admin/groups/class_groupMail.inc +++ b/plugins/admin/groups/class_groupMail.inc @@ -789,6 +789,9 @@ I: Only insider delivery */ $ldap= $this->config->get_ldap_link(); $message= array(); + if(!$this->is_account) return array(); + + //$message[] = $str; /* must: mail */ if ($this->mail == ""){ @@ -941,24 +944,21 @@ I: Only insider delivery */ { if(!$this->is_account) return(""); - $str =" - - - - -
". - _("Primary mail address"). - " - -
"; - return($str); + $smarty = get_smarty(); + $smarty->assign("gosaMailAlternateAddress",$this->gosaMailAlternateAddress); + $smarty->assign("gosaMailForwardingAddress",$this->gosaMailForwardingAddress); + $smarty->assign("mail",$this->mail); + $display= $smarty->fetch (get_template_path('paste_mail.tpl', TRUE)); + return($display); } function saveCopyDialog() { if(!$this->is_account) return; + + /* Perform ADD / REMOVE ... for mail alternate / mail forwarding addresses + */ + $this->execute(); if(isset($_POST['mail'])){ $this->mail = $_POST['mail']; } diff --git a/plugins/admin/groups/class_groupManagement.inc b/plugins/admin/groups/class_groupManagement.inc index 0636d6c44..a3d90a0df 100644 --- a/plugins/admin/groups/class_groupManagement.inc +++ b/plugins/admin/groups/class_groupManagement.inc @@ -219,8 +219,17 @@ class groupManagement extends plugin $objNew = new grouptabs($this->config,$this->config->data['TABS']['GROUPTABS'], "new"); $obj->set_acl($acl); $objNew->set_acl($acl); - $this->CopyPasteHandler->Copy($obj,$objNew); + + foreach($this->CopyPasteHandler->current->by_object as $name => $obj){ + foreach(array('is_account','gotoHotplugDevices','gotoLogonScripts', + 'gotoProfileServers','gotoProfileFlag_C','gotoProfileFlag_L', + 'gotoPrinter','useProfile','OrigCn','Categories') as $attr){ + if(isset($obj->$attr)){ + $this->CopyPasteHandler->current->by_object[$name]->$attr = $obj->$attr; + } + } + } } -- 2.30.2