summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 8da5400)
raw | patch | inline | side by side (parent: 8da5400)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Fri, 23 Apr 2010 06:39:51 +0000 (06:39 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Fri, 23 Apr 2010 06:39:51 +0000 (06:39 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/branches/2.6@17804 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-plugins/gofax/gofax/faxaccount/class_gofaxAccount.inc | patch | blob | history | |
gosa-plugins/mail/personal/mail/class_mailAccount.inc | patch | blob | history |
diff --git a/gosa-plugins/gofax/gofax/faxaccount/class_gofaxAccount.inc b/gosa-plugins/gofax/gofax/faxaccount/class_gofaxAccount.inc
index f7d814e474842d338ef959b327a4e20e34e841e6..35121299af835ee1dc84e9eedfe3c75418942050 100644 (file)
$message[]= msgPool::invalid(_("Fax number"),$this->facsimileTelephoneNumber,"/[0-9]/");
}
- /* IF mail is specified (which is only the case if there's no mail account
- present), check if it's valid.. */
- if (@isset($this->parent->by_object['mailAccount']) &&
- $this->goFaxDeliveryMode & 32){
+ // check for a valid Mail-Address in case of 'delivery to mailbox'
+ $mailAccount = (isset($this->parent->by_object['mailAccount']) && $this->parent->by_object['mailAccount']->is_account);
+ if(!$mailAccount && $this->goFaxDeliveryMode & 32){
if ($this->mail == ""){
$message[]= _("Mail delivery is requested without target address!");
} elseif (!tests::is_email($this->mail)){
diff --git a/gosa-plugins/mail/personal/mail/class_mailAccount.inc b/gosa-plugins/mail/personal/mail/class_mailAccount.inc
index 12755e1c2e9699177d84edb52d9af6a7132bd64f..79428a6f43f70831bdc8c0ca89bd76f448a03788 100644 (file)
}
}
+ // Do NOT remove the mail attribute while it is used in the Fax Account.
+ if(isset($this->parent->by_object['gofaxAccount'])){
+ $fax = $this->parent->by_object['gofaxAccount'];
+
+ // Fax delivery to the mail account is activated, keep the mail attribute.
+ if($fax->goFaxDeliveryMode & 32){
+ $this->attributes = array_remove_entries(array('mail'), $this->attributes) ;
+ }
+ }
+
/* Remove GOsa attributes */
plugin::remove_from_parent();