summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 0ac9063)
raw | patch | inline | side by side (parent: 0ac9063)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 5 Dec 2007 08:55:39 +0000 (08:55 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 5 Dec 2007 08:55:39 +0000 (08:55 +0000) |
- Not testet yet.
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8005 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@8005 594d385d-05f5-0310-b6e9-bd551577e9d8
include/class_plugin.inc | patch | blob | history |
index b71e576ca9b205b107d7e07509c0d45aefa6d54d..528de883ff48e7046125bc6fe0847a81867a1759 100644 (file)
--- a/include/class_plugin.inc
+++ b/include/class_plugin.inc
/* This can be set to render the tabulators in another stylesheet */
var $pl_notify= FALSE;
+ /* The entries CSN value, if available */
+ var $entryCSN = "";
/* This variable indicates that this class can handle multiple dns at once. */
var $multiple_support = FALSE;
$ldap= $this->config->get_ldap_link();
if ($dn !== NULL){
+ /* Try to get entry CSN for save checks later */
+ $ldap->cat($dn,array("entryCSN"));
+ $csn = $ldap->fetch();
+ if(isset($csn['entryCSN'][0])){
+ $this->entryCSN = $csn['entryCSN'][0];
+ }
+
/* Load data to 'attrs' and save 'dn' */
if ($parent !== NULL){
$this->attrs= $parent->attrs;
}
+ /* Check if entry CSN has changed */
+ $ldap = $this->config->get_ldap_link();
+ $ldap->cat($this->dn,array("entryCSN"));
+ $csn = $ldap->fetch();
+ if(isset($csn['entryCSN'][0]) && !empty($this->entryCSN) && $this->entryCSN != $csn['entryCSN'][0]){
+ $this->entryCSN = $csn['entryCSN'][0];
+ $message[] = _("The object has changed since opened in GOsa. Please ensure that nobody has done serious changes that may get lost if you save this entry.");
+ }
+
return ($message);
}