summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 1ebc7ac)
raw | patch | inline | side by side (parent: 1ebc7ac)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 16 May 2007 09:47:38 +0000 (09:47 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Wed, 16 May 2007 09:47:38 +0000 (09:47 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@6392 594d385d-05f5-0310-b6e9-bd551577e9d8
diff --git a/plugins/admin/departments/class_departmentGeneric.inc b/plugins/admin/departments/class_departmentGeneric.inc
index da4c101b7beeccfc97adc50480725de7ff16889c..9f96a555aeb09652d543a93690cac61b3d7d7728 100644 (file)
$this->is_administrational_unit= true;
$this->initially_was_tagged = true;
}
+
+ if($this->is_account && $dn != "new"){
+ @log::log("view","department/".get_class($this),$this->dn);
+ }
}
function execute()
$ldap= $this->config->get_ldap_link();
$ldap->cd ($this->dn);
$ldap->recursive_remove();
+ @log::log("remove","department/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
show_ldap_error($ldap->get_error(), sprintf(_("Removing of department with dn '%s' failed."),$this->dn));
/* Optionally execute a command after we're done */
$a= $ldap->fetch();
$ldap->cd($this->dn);
+ print_a(debug_backtrace());
+
if (count($a)){
$this->cleanup();
$ldap->modify ($this->attrs);
-
+ @log::log("modify","department/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
$this->handle_post_events('modify');
} else {
$ldap->add($this->attrs);
$this->handle_post_events('add');
+ @log::log("create","department/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
}
show_ldap_error($ldap->get_error(), sprintf(_("Saving of department with dn '%s' failed."),$this->dn));
diff --git a/plugins/admin/departments/class_departmentManagement.inc b/plugins/admin/departments/class_departmentManagement.inc
index 3524b15f436149ef3227832f29e8d77312255f9a..a6e2fd9027d6ec572dfb80ede7dfbc57d7ec1ec1 100644 (file)
} else {
add_lock ($this->dn, $this->ui->dn);
$smarty->assign("info", sprintf(_("You're about to delete the whole LDAP subtree placed under '%s'."), @LDAP::fix($this->dn)));
+ $smarty->assign("multiple", false);
$display.= $smarty->fetch (get_template_path('remove.tpl', TRUE));
return ($display);
}
diff --git a/plugins/admin/groups/class_groupApplication.inc b/plugins/admin/groups/class_groupApplication.inc
index e883208da6b3dc2cc3fcef5e3f264cd4a85d2f60..b66f40e85ddb5c5ea2e86062735be8bc845e06d0 100644 (file)
$this->InitialFAIrelease = $this->FAIrelease;
$this->Releases = $this->getReleases();
}
+
+ if($this->is_account){
+ @log::log("view","groups/".get_class($this),$this->dn);
+ }
}
$this->cleanup();
$ldap->modify ($this->attrs);
-
+ @log::log("remove","group/".get_class($this),$use_dn,array_keys($this->attrs),$ldap->get_error());
show_ldap_error($ldap->get_error(), sprintf(_("Removing of groups/applications with dn '%s' failed."),$this->dn));
/* Optionally execute a command after we're done */
$this->cleanup();
$ldap->modify ($this->attrs);
+ if($this->initially_was_account){
+ @log::log("modify","group/".get_class($this),$use_dn,array_keys($this->attrs),$ldap->get_error());
+ }else{
+ @log::log("create","group/".get_class($this),$use_dn,array_keys($this->attrs),$ldap->get_error());
+ }
+
show_ldap_error($ldap->get_error(), sprintf(_("Saving of groups/applications with dn '%s' failed."),$this->dn));
/* Optionally execute a command after we're done */
diff --git a/plugins/admin/groups/class_groupGeneric.inc b/plugins/admin/groups/class_groupGeneric.inc
index 1d2bc1b75ccb96c2efc81d154ecad30755b44c49..aa5ed9884a639f4df59d1188a36a8f49eee1bfb9 100644 (file)
$this->base =preg_replace ("/^[^,]+,".normalizePreg(get_groups_ou())."/","",$this->dn);
}
+ if($this->dn != "new"){
+ @log::log("view","groups/".get_class($this),$this->dn);
+ }
+
/* This is always an account */
$this->is_account= TRUE;
$this->reload();
$ldap->rmdir($this->dn);
show_ldap_error($ldap->get_error(), sprintf(_("Removing of groups/generic with dn '%s' failed."),$this->dn));
+ @log::log("remove","groups/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+
/* Delete references to object groups */
$ldap->cd ($this->config->current['BASE']);
$ldap->search ("(&(objectClass=gosaGroupOfNames)(member=".$this->dn."))", array("cn"));
$this->cleanup();
$ldap->$mode($this->attrs);
+ if($this->initially_was_account){
+ @log::log("modify","groups/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+ }else{
+ @log::log("create","groups/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+ }
+
$ret= 0;
if ( show_ldap_error($ldap->get_error(), sprintf(_("Removing of groups/generic with dn '%s' failed."),$this->dn))){
$ret= 1;
index a3c43e5d5a1a20046d93b715f34a770e86798c98..3c9b0feffb369c1ad201a6771a7b58cd39a4edf0 100644 (file)
$this->perms["lrswipcd"]= _("write");
$this->perms["lrswipcda"]= _("admin");
$this->perms[""]= _("none");
+
+ if($this->is_account){
+ @log::log("view","groups/".get_class($this),$this->dn);
+ }
}
function execute()
/* remove object from parent */
function remove_from_parent()
{
+ if(!$this->initially_was_account){
+ return;
+ }
+
/* Added these ObjectClass and Attributes, because they were not
removed correctly, only in case of kolab ...
*/
$ldap->modify ($this->attrs);
show_ldap_error($ldap->get_error(), sprintf(_("Removing of groups/mail with dn '%s' failed."),$this->dn));
+
+ @log::log("remove","groups/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+
/* Optionally execute a command after we're done */
$this->handle_post_events("remove");
}
$this->cleanup();
$ldap->modify ($this->attrs);
show_ldap_error($ldap->get_error(), sprintf(_("Saving of groups/mail with dn '%s' failed."),$this->dn));
+
+ if($this->initially_was_account){
+ @log::log("modify","groups/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+ }else{
+ @log::log("create","groups/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+ }
+
/* Optionally execute a command after we're done */
if ($this->initially_was_account == $this->is_account){
diff --git a/plugins/personal/environment/class_environment.inc b/plugins/personal/environment/class_environment.inc
index f8ad1f0b1127c2654d30b16d5112bbec8519d13a..7c18c08ef1408d46254791dac8c6d4b90302679e 100644 (file)
{
plugin::plugin ($config, $dn);
- if($this->is_account){
- @log::log("view","users/environment",$this->dn);
- }
-
-
/* Setting uid to default */
if(isset($this->attrs['uid'][0])){
$this->uid = $this->attrs['uid'][0];
$this->gotoShareSelections= $config->getShareList(true);
$this->gotoAvailableShares= $config->getShareList(false);
+ if($this->is_account){
+
+ if(in_array("gosaAccount",$this->attrs['objectClass'])){
+ @log::log("view","users/".get_class($this),$this->dn);
+ }else{
+ @log::log("view","groups/".get_class($this),$this->dn);
+ }
+ }
}
$this->cleanup();
$ldap->modify ($this->attrs);
- @log::log("remove","users/environment",$this->dn,array_keys($this->attrs),$ldap->get_error());
+ if($this->is_group){
+ @log::log("remove","groups/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+ }else{
+ @log::log("remove","users/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
+ }
+
show_ldap_error($ldap->get_error(), sprintf(_("Removing of user/environment account with dn '%s' failed."),$this->dn));
/* Optionally execute a command after we're done */
$this->cleanup();
$ldap->$mode($this->attrs);
+ $cat = "users";
+ if($this->is_group){
+ $cat = "groups";
+ }
+
/* Log last action */
if($this->initially_was_account){
- @log::log("modify","users/environment",$this->dn,array_keys($this->attrs),$ldap->get_error());
+ @log::log("modify",$cat."/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
}else{
- @log::log("create","users/environment",$this->dn,array_keys($this->attrs),$ldap->get_error());
+ @log::log("create",$cat."/".get_class($this),$this->dn,array_keys($this->attrs),$ldap->get_error());
}
show_ldap_error($ldap->get_error(), sprintf(_("Saving of user/environment account with dn '%s' failed."),$this->dn));