X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=include%2Fclass_plugin.inc;h=92cd6ae7c7eb6db74caaf34bc6abed4fc41742f9;hb=c79e9f20056ebc7ee5872d2a072fc36bc5b097ca;hp=72793b3c75ef87e45c321b900f6129c13d6e94d5;hpb=2277cb2e30195dddd0dc2e918ff59dd3c6730a2a;p=gosa.git diff --git a/include/class_plugin.inc b/include/class_plugin.inc index 72793b3c7..92cd6ae7c 100644 --- a/include/class_plugin.inc +++ b/include/class_plugin.inc @@ -226,8 +226,9 @@ class plugin /* This one is empty currently. Fabian - please fill in the docu code */ $_SESSION['current_class_for_help'] = get_class($this); + /* Reset Lock message POST/GET check array, to prevent perg_match errors*/ - $_SESSION['LOCK_VARS_TO_USE'] =array(); + $_SESSION['LOCK_VARS_TO_USE'] = $_SESSION['LOCK_VARS_USED'] =array(); } /*! \brief execute plugin @@ -1128,14 +1129,9 @@ class plugin $ui = get_userinfo(); $old_dn = $this->dn; $this->dn = $dn; - - if($this->acl_is_removeable() && $this->acl_is_createable()){ - $ldap = $this->config->get_ldap_link(); - $ldap->cd($this->config->current['BASE']); - $ldap->rmdir_recursive($dn); - }else{ - print_red (_("You are not allowed to delete this snapshot!")); - } + $ldap = $this->config->get_ldap_link(); + $ldap->cd($this->config->current['BASE']); + $ldap->rmdir_recursive($dn); $this->dn = $old_dn; } @@ -1489,13 +1485,6 @@ class plugin $new = false; } - /* Add current base */ - if(isset($this->base) && isset($this->config->idepartments[$this->base])){ - $deps[$this->base] = $this->config->idepartments[$this->base]; - }else{ - echo "No default base found. ".$this->base."
"; - } - $cat_bases = $ui->get_module_departments(preg_replace("/\/.*$/","",$category)); foreach($this->config->idepartments as $dn => $name){ @@ -1510,6 +1499,14 @@ class plugin $deps[$dn] = $name; } } + + /* Add current base */ + if(isset($this->base) && isset($this->config->idepartments[$this->base])){ + $deps[$this->base] = $this->config->idepartments[$this->base]; + }else{ + echo "No default base found. ".$this->base."
"; + } + return($deps); }