Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
agallavardin
fusiondirectory-plugins
Commits
54cfb283
Commit
54cfb283
authored
Jun 22, 2015
by
Côme Bernigaud
Committed by
Benoit Mortier
Jun 22, 2015
Browse files
Fixes
#3890
Vacation range should be disabled on mail methods as none implements it
parent
a86da769
Changes
5
Hide whitespace changes
Inline
Side-by-side
cyrus/personal/mail/mail-methods/class_mail-methods-cyrus.inc
View file @
54cfb283
...
...
@@ -38,7 +38,7 @@ class mailMethodCyrus extends mailMethod
protected
$enableDomainSelection
=
FALSE
;
protected
$enableQuota
=
TRUE
;
protected
$enableVacationRange
=
TRU
E
;
protected
$enableVacationRange
=
FALS
E
;
protected
$enableFolderTypes
=
FALSE
;
protected
function
init
()
...
...
kolab/personal/mail/kolab/class_mail-methods-kolab.inc
View file @
54cfb283
...
...
@@ -34,7 +34,7 @@ class mailMethodKolab extends mailMethodCyrus
/* Enabled mail domain selection. If enabled getMailDomains must the domain parts */
protected
$enableDomainSelection
=
FALSE
;
protected
$enableQuota
=
TRUE
;
protected
$enableVacationRange
=
TRU
E
;
protected
$enableVacationRange
=
FALS
E
;
protected
$enableFolderTypes
=
TRUE
;
protected
$attributes
=
array
(
...
...
kolab/personal/mail/kolab/class_mail-methods-kolab22.inc
View file @
54cfb283
...
...
@@ -32,7 +32,7 @@ class mailMethodKolab22 extends mailMethodKolab
/* Enabled mail domain selection. If enabled getMailDomains must the domain parts */
protected
$enableDomainSelection
=
TRUE
;
protected
$enableQuota
=
TRUE
;
protected
$enableVacationRange
=
TRU
E
;
protected
$enableVacationRange
=
FALS
E
;
protected
$enableFolderTypes
=
TRUE
;
protected
$userObjectClasses
=
array
(
"kolabInetOrgPerson"
);
...
...
mail/personal/mail/class_mail-methods.inc
View file @
54cfb283
...
...
@@ -22,7 +22,6 @@
class
mailMethod
{
/* Allow modification of account_ids for existing mail accounts */
protected
$modifyableMail
=
TRUE
;
...
...
@@ -76,7 +75,7 @@ class mailMethod
*/
protected
$enableDomainSelection
=
FALSE
;
protected
$enableQuota
=
TRUE
;
protected
$enableVacationRange
=
TRU
E
;
protected
$enableVacationRange
=
FALS
E
;
protected
$enableFolderTypes
=
FALSE
;
/* Default values */
...
...
mail/personal/mail/class_mailAccount.inc
View file @
54cfb283
...
...
@@ -278,8 +278,33 @@ class mailAccount extends simplePlugin
$this
->
attributesAccess
[
'flag_sieveownscript'
]
->
setInLdap
(
FALSE
);
if
(
!
$this
->
mailMethod
->
vacationRangeEnabled
())
{
unset
(
$this
->
attributesAccess
[
'gosaVacationStart'
]);
unset
(
$this
->
attributesAccess
[
'gosaVacationStop'
]);
$this
->
attributesAccess
[
'gosaVacationStart'
]
->
setDisabled
(
TRUE
);
$this
->
attributesAccess
[
'gosaVacationStart'
]
->
setVisible
(
FALSE
);
$this
->
attributesAccess
[
'gosaVacationStop'
]
->
setDisabled
(
TRUE
);
$this
->
attributesAccess
[
'gosaVacationStop'
]
->
setVisible
(
FALSE
);
$this
->
attributesAccess
[
'flag_vacation'
]
->
setManagedAttributes
(
array
(
'erase'
=>
array
(
FALSE
=>
array
(
'gosaVacationMessage'
)
)
)
);
$this
->
attributesAccess
[
'flag_sieveownscript'
]
->
setManagedAttributes
(
array
(
'erase'
=>
array
(
TRUE
=>
array
(
'flag_vacation'
,
'gosaVacationMessage'
,
'flag_spamlevel'
,
'flag_spamsize'
,
'gosaMailMaxSize'
,
'gosaSpamMailbox'
,
'gosaSpamSortLevel'
,
'flag_ownmailbox'
,
'flag_localonly'
)
)
)
);
}
else
{
$this
->
attributesAccess
[
'flag_vacation'
]
->
setManagedAttributes
(
array
(
...
...
@@ -290,6 +315,20 @@ class mailAccount extends simplePlugin
)
)
);
$this
->
attributesAccess
[
'flag_sieveownscript'
]
->
setManagedAttributes
(
array
(
'erase'
=>
array
(
TRUE
=>
array
(
'flag_vacation'
,
'gosaVacationStart'
,
'gosaVacationStop'
,
'gosaVacationMessage'
,
'flag_spamlevel'
,
'flag_spamsize'
,
'gosaMailMaxSize'
,
'gosaSpamMailbox'
,
'gosaSpamSortLevel'
,
'flag_ownmailbox'
,
'flag_localonly'
)
)
)
);
}
$this
->
attributesAccess
[
'flag_spamlevel'
]
->
setManagedAttributes
(
...
...
@@ -309,20 +348,6 @@ class mailAccount extends simplePlugin
)
);
$this
->
attributesAccess
[
'flag_sieveownscript'
]
->
setManagedAttributes
(
array
(
'erase'
=>
array
(
TRUE
=>
array
(
'flag_vacation'
,
'gosaVacationStart'
,
'gosaVacationStop'
,
'gosaVacationMessage'
,
'flag_spamlevel'
,
'flag_spamsize'
,
'gosaMailMaxSize'
,
'gosaSpamMailbox'
,
'gosaSpamSortLevel'
,
'flag_ownmailbox'
,
'flag_localonly'
)
)
)
);
/* sieve submit the form so that managed attributes are correctly updated */
$this
->
attributesAccess
[
'flag_sieveownscript'
]
->
setSubmitForm
(
TRUE
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment