diff --git a/plugins/admin/groups/class_groupApplication.inc b/plugins/admin/groups/class_groupApplication.inc
index 9f3d02d436af3a4cca562031dfa76ff67fa8bbe7..c899f0bff70e22847d848ea9c76660fc57f26132 100644 (file)
plugin::execute();
if((isset($_GET['act']))&&($_GET['act']=="depopen")){
- print $_GET['id'];
- $dep = base64_decode($_GET['id']);
+ $dep = base64_decode($_GET['depid']);
if(isset($this->config->idepartments[$dep])){
$this->curbase =$dep;
}
$this->reload();
+ $only_once = false;
foreach($_POST as $name => $value){
- if(preg_match("/AddSep_/",$name)){
- $this->AddSeperator($value);
+ if((preg_match("/AddSep_/",$name))&&(!$only_once)){
+ $only_once = true;
+ $n = preg_replace("/AddSep_/","",$name);
+ $val= preg_replace("/_.*$/","",$n);
+ $this->AddSeperator($val);
}
-
- if(preg_match("/DelApp_/",$name)){
- $app = $value;
+ if((preg_match("/DelApp_/",$name))&&(!$only_once)){
+ $only_once = true;
+
+
+ if(preg_match("/DelApp___SEPARATOR__/",$name)) {
+ $n= preg_replace("/DelApp___SEPARATOR__/","",$name);
+ $val= "__SEPARATOR__".preg_replace("/_.*$/","",$n);
+ }else{
+ $n = preg_replace("/DelApp_/","",$name);
+ $val= preg_replace("/_.*$/","",$n);
+ }
+
foreach($this->gosaMemberApplication as $key => $cat){
foreach($cat as $key2 => $app){
- if($app['App'] == $value){
+ if($app['App'] == $val){
unset($this->gosaMemberApplication[$key][$key2]);
- if(isset($this->used_apps[$value])){
- unset($this->used_apps[$value]);
+ if(isset($this->used_apps[$val])){
+ unset($this->used_apps[$val]);
}
}
}
}
}
-
+
if(preg_match("/DelCat_/",$name)){
$n = preg_replace("/DelCat_/","",$name);
$app = base64_decode( preg_replace("/_.*$/","",$n));
}
}
- if(preg_match("/EdiApp_/",$name)){
+ if((preg_match("/EdiApp_/",$name))&&(!$only_once)){
+
+ $only_once = true;
$appname = $value;
+ $appname = preg_replace("/EdiApp_/","",$name);
+ $appname = preg_replace("/_.*$/","",$appname);
/* We've got the appname, get parameters from ldap */
$ldap= $this->config->get_ldap_link();
$ldap->cd($this->config->current['BASE']);
for($i = 0 ; $i < ($cnt -1 ) ; $i++){
$bbk .= $tmp[$i];
}
- $div2 ->AddEntry(array(array("string"=>sprintf($linkopen,$bbk,"..")),array("string"=>" ","attach"=>"style='border-right:0px;'")));
+ $div2 ->AddEntry(array(array("string"=>sprintf($linkopen,base64_encode($bbk),"..")),array("string"=>" ","attach"=>"style='border-right:0px;'")));
}
$this->GetSubdirs($this->curCatDir);