Code

fixed conference acls
authorhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 2 Dec 2005 12:05:42 +0000 (12:05 +0000)
committerhickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8>
Fri, 2 Dec 2005 12:05:42 +0000 (12:05 +0000)
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@2205 594d385d-05f5-0310-b6e9-bd551577e9d8

plugins/gofon/conference/class_phoneConferenceGeneric.inc
plugins/gofon/conference/class_phoneConferenceManagment.inc

index 961650e37a091935b86aba0f127327b3c987266f..f56e30a1a71751dc53814d8785f962be20eb8f78 100644 (file)
@@ -82,8 +82,9 @@ class conference extends plugin
       $this->base= preg_replace ("/^[^,]+,/", "", $this->dn);
     }
 
-    $acl= get_permissions ($this->dn, $this->ui->subtreeACL);
-    $this->acl= get_module_permission($acl, "conference", $this->dn);
+    $ui= get_userinfo();
+    $acl= get_permissions ($ui->dn, $this->ui->subtreeACL);
+    $this->acl= get_module_permission($acl, "conference", $ui->dn);
     $this->goFonConferenceOwner=$this->ui->dn;
 
     /* Parse Options ... 
@@ -148,7 +149,7 @@ class conference extends plugin
 
   function remove_from_parent()
   {
-     $this->SQL_remove_me(true); 
+    $this->SQL_remove_me(true); 
 
     $ldap= $this->config->get_ldap_link();
     $ldap->cd ($this->dn);
index bbde58faf9930dae3bb43f03acfa4e1347498206..9c3229d60a500c76bc8387707f2d23723f655b2b 100644 (file)
@@ -189,9 +189,7 @@ class phoneConferenceManagment extends plugin
      * Finally delete department
      */
     if (isset($_POST['delete_department_confirm'])){
-      $acl= get_permissions ($this->dn, $this->ui->subtreeACL);
-      $acl= get_module_permission($acl, "conference", $this->dn);
-      if (chkacl($acl, "all") == ""){
+      if (chkacl($this->acl, "delete") == ""){
         $this->remove_from_parent();
         gosa_log ("Department object'".$this->dn."' has been removed");
         $this->reload ();
@@ -434,6 +432,7 @@ class phoneConferenceManagment extends plugin
   function remove_from_parent()
   {
     $cfg = new conference($this->config, $this->dn);
+
     $cfg->remove_from_parent();
     $ldap= $this->config->get_ldap_link();
     $ldap->cd ($this->dn);