Skip to content
GitLab
Explore
Projects
Groups
Topics
Snippets
Projects
Groups
Topics
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
fusiondirectory
fusiondirectory-plugins
Commits
db2639b0
Commit
db2639b0
authored
7 years ago
by
Côme Chilliet
Browse files
Options
Download
Patches
Plain Diff
fix(mail) Fix mail server cache reset for forein keys
issue #5808
parent
6598424a
dev
6104-mail-methods-refactor
6231-give-the-ability-to-the-webservice-to-notice-if-an-attribute-is-monovalued-or-multivalued
6237-add-requiredattrs-array-to-the-webservice-informations
6245-adapt-the-ci-to-the-reorganisation-of-the-dev-tools-and-fixing-the-trigger-downstream-pipelines
6250-supann-configuration-backend-requires-account-life-cycle-section
6280-plugins-update-plugins-to-take-into-consideration-the-new-directory-of-core-structure
6310-tasks-reminder-error-in-the-schema-duplicate-attribute-id
6311-put-the-version-1-5-in-all-yaml-for-fusiondirectory-1-5
6322-template-issue-when-creating-a-template-with-empty-password-error-message-should-not-be-seen-2
6332-zimbra-allows-update-of-data-for-unknown-domain-name-for-specific-individual-aliases
6337-webservice-issue-with-archiving-post-request-not-responding-but-successfully-archiving-user
6341-supann-extract-resources-states-sub-states-from-backend-configuration-to-their-own-objects
master
fusiondirectory-1.5
fusiondirectory-1.4
fusiondirectory-1.3.1
fusiondirectory-1.3
No related merge requests found
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
cyrus/admin/systems/services/cyrus/class_serviceCyrus.inc
+1
-13
cyrus/admin/systems/services/cyrus/class_serviceCyrus.inc
dovecot/admin/systems/services/dovecot/class_serviceDovecot.inc
+1
-13
...t/admin/systems/services/dovecot/class_serviceDovecot.inc
mail/admin/systems/services/imap/class_serviceIMAP.inc
+26
-13
mail/admin/systems/services/imap/class_serviceIMAP.inc
mail/personal/mail/class_mailAccount.inc
+9
-0
mail/personal/mail/class_mailAccount.inc
renater-partage/admin/systems/services/renater-partage/class_serviceRenaterPartage.inc
+1
-13
.../services/renater-partage/class_serviceRenaterPartage.inc
with
38 additions
and
52 deletions
+38
-52
cyrus/admin/systems/services/cyrus/class_serviceCyrus.inc
+
1
−
13
View file @
db2639b0
...
@@ -19,7 +19,7 @@
...
@@ -19,7 +19,7 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/
*/
class
serviceCyrus
extends
simpleService
class
serviceCyrus
extends
simple
MailMethod
Service
{
{
var
$objectclasses
=
array
(
'fdCyrusServer'
);
var
$objectclasses
=
array
(
'fdCyrusServer'
);
...
@@ -111,17 +111,5 @@ class serviceCyrus extends simpleService
...
@@ -111,17 +111,5 @@ class serviceCyrus extends simpleService
)
)
);
);
}
}
protected
function
post_save
()
{
parent
::
post_save
();
mailMethod
::
resetMailServersCache
();
}
protected
function
post_remove
()
{
parent
::
post_remove
();
mailMethod
::
resetMailServersCache
();
}
}
}
?>
?>
This diff is collapsed.
Click to expand it.
dovecot/admin/systems/services/dovecot/class_serviceDovecot.inc
+
1
−
13
View file @
db2639b0
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/
*/
class
serviceDovecot
extends
simpleService
class
serviceDovecot
extends
simple
MailMethod
Service
{
{
var
$objectclasses
=
array
(
'fdDovecotServer'
);
var
$objectclasses
=
array
(
'fdDovecotServer'
);
...
@@ -102,17 +102,5 @@ class serviceDovecot extends simpleService
...
@@ -102,17 +102,5 @@ class serviceDovecot extends simpleService
)
)
);
);
}
}
protected
function
post_save
()
{
parent
::
post_save
();
mailMethod
::
resetMailServersCache
();
}
protected
function
post_remove
()
{
parent
::
post_remove
();
mailMethod
::
resetMailServersCache
();
}
}
}
?>
?>
This diff is collapsed.
Click to expand it.
mail/admin/systems/services/imap/class_serviceIMAP.inc
+
26
−
13
View file @
db2639b0
...
@@ -20,7 +20,32 @@
...
@@ -20,7 +20,32 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/
*/
class
serviceIMAP
extends
simpleService
class
simpleMailMethodService
extends
simpleService
{
protected
function
prepare_save
()
{
if
(
!
$this
->
shouldSave
())
{
// Reset mail server cache now as post_save won’t be called
mailMethod
::
resetMailServersCache
();
}
return
parent
::
prepare_save
();
}
protected
function
post_save
()
{
parent
::
post_save
();
mailMethod
::
resetMailServersCache
();
}
protected
function
post_remove
()
{
parent
::
post_remove
();
mailMethod
::
resetMailServersCache
();
}
}
class
serviceIMAP
extends
simpleMailMethodService
{
{
/* This plugin only writes its objectClass */
/* This plugin only writes its objectClass */
var
$objectclasses
=
array
(
'fdImapServer'
);
var
$objectclasses
=
array
(
'fdImapServer'
);
...
@@ -49,17 +74,5 @@ class serviceIMAP extends simpleService
...
@@ -49,17 +74,5 @@ class serviceIMAP extends simpleService
{
{
return
'<b>This server runs an IMAP or POP3 server</b>'
.
parent
::
execute
();
return
'<b>This server runs an IMAP or POP3 server</b>'
.
parent
::
execute
();
}
}
protected
function
post_save
()
{
parent
::
post_save
();
mailMethod
::
resetMailServersCache
();
}
protected
function
post_remove
()
{
parent
::
post_remove
();
mailMethod
::
resetMailServersCache
();
}
}
}
?>
?>
This diff is collapsed.
Click to expand it.
mail/personal/mail/class_mailAccount.inc
+
9
−
0
View file @
db2639b0
...
@@ -231,6 +231,15 @@ class mailAccount extends simplePlugin
...
@@ -231,6 +231,15 @@ class mailAccount extends simplePlugin
}
}
}
}
function
foreignKeyUpdate
(
$field
,
$oldvalue
,
$newvalue
,
$source
)
{
if
(
$field
==
'gosaMailServer'
)
{
mailMethod
::
resetMailServersCache
();
$this
->
attributesAccess
[
'gosaMailServer'
]
->
setChoices
(
array_keys
(
mailMethod
::
getMailServers
()));
}
parent
::
foreignKeyUpdate
(
$field
,
$oldvalue
,
$newvalue
,
$source
);
}
public
function
mailServerChanged
()
public
function
mailServerChanged
()
{
{
/* Intialize the used mailMethod */
/* Intialize the used mailMethod */
...
...
This diff is collapsed.
Click to expand it.
renater-partage/admin/systems/services/renater-partage/class_serviceRenaterPartage.inc
+
1
−
13
View file @
db2639b0
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA.
*/
*/
class
serviceRenaterPartage
extends
simpleService
class
serviceRenaterPartage
extends
simple
MailMethod
Service
{
{
var
$objectclasses
=
array
(
'fdRenaterPartageServer'
);
var
$objectclasses
=
array
(
'fdRenaterPartageServer'
);
...
@@ -96,17 +96,5 @@ class serviceRenaterPartage extends simpleService
...
@@ -96,17 +96,5 @@ class serviceRenaterPartage extends simpleService
parent
::
__construct
(
$dn
,
$parent
);
parent
::
__construct
(
$dn
,
$parent
);
$this
->
attributesAccess
[
'fdRenaterPartageServerMailDomain'
]
->
setLinearRendering
(
FALSE
);
$this
->
attributesAccess
[
'fdRenaterPartageServerMailDomain'
]
->
setLinearRendering
(
FALSE
);
}
}
protected
function
post_save
()
{
parent
::
post_save
();
mailMethod
::
resetMailServersCache
();
}
protected
function
post_remove
()
{
parent
::
post_remove
();
mailMethod
::
resetMailServersCache
();
}
}
}
?>
?>
This diff is collapsed.
Click to expand it.
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment
Menu
Explore
Projects
Groups
Topics
Snippets