Skip to content

Commit be8697b

Browse files
author
Till Brehm
committed
Merge branch 'forward_via_postfix' into 'stable-3.1'
Forward via postfix Closes #5670 See merge request ispconfig/ispconfig3!1111
2 parents 6c4eb9b + ec11409 commit be8697b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+158
-27
lines changed

install/sql/incremental/upd_dev_collection.sql

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -76,3 +76,7 @@ ALTER TABLE `dns_soa` CHANGE `dnssec_algo` `dnssec_algo` SET('NSEC3RSASHA1','ECD
7676
ALTER TABLE `client_template` CHANGE `ssh_chroot` `ssh_chroot` VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '';
7777
ALTER TABLE `client_template` CHANGE `web_php_options` `web_php_options` VARCHAR(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '';
7878

79+
-- add option to forward in lda, default to forward in mta except for existing forwards
80+
ALTER TABLE `mail_user` ADD `forward_in_lda` enum('n','y') NOT NULL default 'n' AFTER `cc`;
81+
UPDATE `mail_user` set `forward_in_lda` = 'y' where `cc` != '';
82+

install/sql/ispconfig3.sql

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1041,6 +1041,7 @@ CREATE TABLE `mail_user` (
10411041
`maildir_format` varchar(255) NOT NULL default 'maildir',
10421042
`quota` bigint(20) NOT NULL default '-1',
10431043
`cc` text,
1044+
`forward_in_lda` enum('n','y') NOT NULL default 'n',
10441045
`sender_cc` varchar(255) NOT NULL default '',
10451046
`homedir` varchar(255) NOT NULL default '',
10461047
`autoresponder` enum('n','y') NOT NULL default 'n',

install/tpl/mysql-virtual_email2email.cf.master

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,4 @@ user = {mysql_server_ispconfig_user}
22
password = {mysql_server_ispconfig_password}
33
dbname = {mysql_server_database}
44
hosts = {mysql_server_ip}
5-
query = SELECT email FROM mail_user WHERE email = '%s' AND postfix = 'y' AND disabledeliver = 'n' AND server_id = {server_id}
6-
UNION
7-
SELECT cc AS email FROM mail_user WHERE email = '%s' AND postfix = 'y' AND disabledeliver = 'y' AND server_id = {server_id}
5+
query = SELECT cc AS email FROM mail_user WHERE email = '%s' AND cc != '' AND (forward_in_lda = 'n' OR disabledeliver = 'y') AND postfix = 'y' AND server_id = {server_id}

install/tpl/mysql-virtual_mailboxes.cf.master

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ user = {mysql_server_ispconfig_user}
22
password = {mysql_server_ispconfig_password}
33
dbname = {mysql_server_database}
44
hosts = {mysql_server_ip}
5-
query = select CONCAT(SUBSTRING_INDEX(email,'@',-1),'/',SUBSTRING_INDEX(email,'@',1),'/') from mail_user where login = '%s' and postfix = 'y' and server_id = {server_id}
5+
query = select CONCAT(SUBSTRING_INDEX(email,'@',-1),'/',SUBSTRING_INDEX(email,'@',1),'/') from mail_user where login = '%s' and postfix = 'y' and disabledeliver = 'n' and server_id = {server_id}

interface/web/mail/form/mail_user.tform.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,12 @@
189189
'width' => '30',
190190
'maxlength' => '65535'
191191
),
192+
'forward_in_lda' => array (
193+
'datatype' => 'VARCHAR',
194+
'formtype' => 'CHECKBOX',
195+
'default' => 'n',
196+
'value' => array(0 => 'n', 1 => 'y')
197+
),
192198
'sender_cc' => array (
193199
'datatype' => 'VARCHAR',
194200
'formtype' => 'TEXT',

interface/web/mail/lib/lang/ar_mail_user.lng

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ $wb['name_optional_txt'] = '(Optional)';
4040
$wb['autoresponder_active'] = 'Enable the autoresponder';
4141
$wb['cc_txt'] = 'Send copy to';
4242
$wb['cc_error_isemail'] = 'The Send copy to field does not conatin a valid email address';
43+
$wb['forward_in_lda_txt'] = 'Copy during delivery';
44+
$wb['tooltip_forward_in_lda_txt'] = 'Controls if mail copy is forwarded before or during delivery to mailbox.';
4345
$wb['domain_txt'] = 'Domain';
4446
$wb['now_txt'] = 'Now';
4547
$wb['login_error_unique'] = 'Login is already taken.';

interface/web/mail/lib/lang/bg_mail_user.lng

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ $wb['name_optional_txt'] = '(По желание)';
4040
$wb['autoresponder_active'] = 'Разреши автоматичен отговор';
4141
$wb['cc_txt'] = 'Изпрати копие до:';
4242
$wb['cc_error_isemail'] = 'Полето с Изпрати копие до: не съдържа валиден емайл адрес';
43+
$wb['forward_in_lda_txt'] = 'Copy during delivery';
44+
$wb['tooltip_forward_in_lda_txt'] = 'Controls if mail copy is forwarded before or during delivery to mailbox.';
4345
$wb['domain_txt'] = 'Домейн';
4446
$wb['now_txt'] = 'Сега';
4547
$wb['login_error_unique'] = 'Login is already taken.';

interface/web/mail/lib/lang/br_mail_user.lng

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,10 @@ $wb['name_txt'] = 'Nome';
4646
$wb['name_optional_txt'] = '(Opcional)';
4747
$wb['autoresponder_active'] = 'Habilitar auto-resposta';
4848
$wb['cc_txt'] = 'Enviar cópia para';
49-
$wb['sender_cc_txt'] = 'Enviar cópia oculta (BCC) para';
5049
$wb['cc_error_isemail'] = 'O campo "Enviar cópia para" contém um endereço de e-mail inválido.';
50+
$wb['forward_in_lda_txt'] = 'Copy during delivery';
51+
$wb['tooltip_forward_in_lda_txt'] = 'Controls if mail copy is forwarded before or during delivery to mailbox.';
52+
$wb['sender_cc_txt'] = 'Enviar cópia oculta (BCC) para';
5153
$wb['sender_cc_error_isemail'] = 'O campo "Enviar cópia oculta para" contém um endereço de e-mail inválido.';
5254
$wb['domain_txt'] = 'Domínio';
5355
$wb['now_txt'] = 'Agora';

interface/web/mail/lib/lang/ca_mail_user.lng

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ $wb['name_optional_txt'] = '(Optionnel)';
3939
$wb['autoresponder_active'] = 'Activer le répondeur automatique';
4040
$wb['cc_txt'] = 'Envoyer une copie à';
4141
$wb['cc_error_isemail'] = 'Le champ Envoyer une copie ne contient pas une adresse courriel valide';
42+
$wb['forward_in_lda_txt'] = 'Copy during delivery';
43+
$wb['tooltip_forward_in_lda_txt'] = 'Controls if mail copy is forwarded before or during delivery to mailbox.';
4244
$wb['domain_txt'] = 'Domaine';
4345
$wb['now_txt'] = 'Maintenant';
4446
$wb['login_error_unique'] = 'Ce nom d\'utilisateur est déjà pris.';

interface/web/mail/lib/lang/cz_mail_user.lng

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ $wb['name_optional_txt'] = '(volitelné)';
3939
$wb['autoresponder_active'] = 'Povolit automatický odpovídač';
4040
$wb['cc_txt'] = 'Odeslat příchozí kopii na';
4141
$wb['cc_error_isemail'] = 'Adresa uvedená v poli zaslat kopii na je neplatná';
42+
$wb['forward_in_lda_txt'] = 'Copy during delivery';
43+
$wb['tooltip_forward_in_lda_txt'] = 'Controls if mail copy is forwarded before or during delivery to mailbox.';
4244
$wb['domain_txt'] = 'Doména';
4345
$wb['now_txt'] = 'Nyní';
4446
$wb['login_error_unique'] = 'Přihlášovací jméno je již obsazeno.';

0 commit comments

Comments
 (0)