summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f4e118a)
raw | patch | inline | side by side (parent: f4e118a)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 11 Apr 2006 05:44:24 +0000 (05:44 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Tue, 11 Apr 2006 05:44:24 +0000 (05:44 +0000) |
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@3024 594d385d-05f5-0310-b6e9-bd551577e9d8
plugins/admin/users/class_userManagement.inc | patch | blob | history |
diff --git a/plugins/admin/users/class_userManagement.inc b/plugins/admin/users/class_userManagement.inc
index 1a4d6ba7ce6b10fba69368e171c3e67e79a3d231..beab32aa7d4ad2ff418c19baa343a1a1e83f9707 100644 (file)
"sambausers" => "checked",
"faxusers" => "checked",
"functionalusers" => "checked",
- "depselect" => $base,
"regex" => "*");
$_SESSION["userfilter"] = $userfilter;
}
+ if(!isset($_SESSION['CurrentMainBase'])) {
+ $base= get_base_from_people($ui->dn);
+ $_SESSION['CurrentMainBase'] = $base;
+ }
}
function execute()
if(isset($_GET['act'])&&($_GET['act']=="dep_open")){
$s_action="open";
$s_entry = base64_decode($_GET['dep_id']);
- $userfilter['depselect']= "".$this->config->departments[trim($s_entry)];
+ $_SESSION['CurrentMainBase']= $this->config->departments[trim($s_entry)];
}
/* Test Posts */
};
/* Department changed? */
- if(isset($_POST['depselect']) && $_POST['depselect']){
- $userfilter['depselect']= $_POST['depselect'];
+ if(isset($_POST['CurrentMainBase']) && $_POST['CurrentMainBase']){
+ $_SESSION['CurrentMainBase']= $_POST['CurrentMainBase'];
}
/* Homebutton is posted */
if($s_action=="home"){
- $userfilter['depselect']=(preg_replace("/^[^,]+,/","",$this->ui->dn));
- $userfilter['depselect']=(preg_replace("/^[^,]+,/","",$userfilter['depselect']));
+ $_SESSION['CurrentMainBase']=(preg_replace("/^[^,]+,/","",$this->ui->dn));
+ $_SESSION['CurrentMainBase']=(preg_replace("/^[^,]+,/","",$_SESSION['CurrentMainBase']));
}
if($s_action=="root"){
- $userfilter['depselect']=($this->config->current['BASE']);
+ $_SESSION['CurrentMainBase']=($this->config->current['BASE']);
}
/* If Backbutton is Posted */
if($s_action=="back"){
- $base_back = preg_replace("/^[^,]+,/","",$userfilter['depselect']);
+ $base_back = preg_replace("/^[^,]+,/","", $_SESSION['CurrentMainBase']);
$base_back = convert_department_dn($base_back);
if(isset($this->config->departments[trim($base_back)])){
- $userfilter['depselect']= $this->config->departments[trim($base_back)];
+ $_SESSION['CurrentMainBase']= $this->config->departments[trim($base_back)];
}else{
- $userfilter['depselect']= $this->config->departments["/"];
+ $_SESSION['CurrentMainBase']= $this->config->departments["/"];
}
}
*/
if(($s_action == "editPaste") || ($this->CopyPasteHandler->stillOpen())){
$this->CopyPasteHandler->save_object();
- $this->CopyPasteHandler->SetVar("base",$userfilter['depselect']);
+ $this->CopyPasteHandler->SetVar("base",$_SESSION['CurrentMainBase']);
$ret = $this->CopyPasteHandler->execute(false);
if($ret) return($ret);
$this->reload();
$this->usertab= new usertabs($this->config,
$this->config->data['TABS']['USERTABS'], $this->dn);
$this->usertab->set_acl(array(':all'));
- $this->usertab->by_object['user']->base= $userfilter['depselect'];
+ $this->usertab->by_object['user']->base= $_SESSION['CurrentMainBase'];
/* Take care about templates */
if ($s_action=="new_tpl"){
}
if (isset($_POST['template_continue']) && ($_POST['template'] == 'none')){
- $this->usertab->by_object['user']->base= $userfilter['depselect'];
+ $this->usertab->by_object['user']->base= $_SESSION['CurrentMainBase'];
}
/* Show tab dialog if object is present */
/* Prepare departments */
$options= "";
foreach ($this->config->idepartments as $key => $value){
- if ($userfilter['depselect'] == $key){
+ if ($_SESSION['CurrentMainBase'] == $key){
$options.= "<option selected value='$key'>$value</option>";
} else {
$options.= "<option value='$key'>$value</option>";
" <input class='center' type='image' align='middle' src='images/list_new.png' title='"._("Create new template")."' alt='"._("New template")."' name='user_tplnew'> ".
$Copy_Paste.
" <img class='center' src='images/list_seperator.png' align='middle' alt='' height='16' width='1'> ".
- _("Base")." <select name='depselect' onChange='mainform.submit()' class='center'>$options</select>".
+ _("Base")." <select name='CurrentMainBase' onChange='mainform.submit()' class='center'>$options</select>".
" <input class='center' type='image' src='images/list_submit.png' align='middle' title='"._("Submit department")."' name='submit_department' alt='"._("Submit")."'> ".
"</div>";
$smarty->assign("infoimage", get_template_path('images/info.png'));
$smarty->assign("launchimage", get_template_path('images/launch.png'));
$smarty->assign("deplist", $this->config->idepartments);
- foreach( array("depselect", "functionalusers", "unixusers",
+ foreach( array("functionalusers", "unixusers",
"mailusers", "sambausers", "proxyusers",
"faxusers", "templates", "subsearch") as $type){
$smarty->assign("$type", $userfilter[$type]);
}
+ $smarty->assign("CurrentMainBase",$_SESSION['CurrentMainBase']);
$smarty->assign("regex", $userfilter["regex"]);
/* Extend if we are not using javascript */
$userfilter= get_global('userfilter');
/* Set base for all searches */
- $base= $userfilter['depselect'];
+ $base= $_SESSION['CurrentMainBase'];
/* Regex filter? */
if ($userfilter['regex'] != ""){