summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 7a4350c)
raw | patch | inline | side by side (parent: 7a4350c)
author | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 7 Apr 2008 08:33:12 +0000 (08:33 +0000) | ||
committer | hickert <hickert@594d385d-05f5-0310-b6e9-bd551577e9d8> | |
Mon, 7 Apr 2008 08:33:12 +0000 (08:33 +0000) |
-Updated list handling
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10222 594d385d-05f5-0310-b6e9-bd551577e9d8
git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@10222 594d385d-05f5-0310-b6e9-bd551577e9d8
gosa-plugins/sudo/admin/sudo/class_sudoGeneric.inc | patch | blob | history | |
gosa-plugins/sudo/admin/sudo/class_target_list_systems.inc | patch | blob | history |
diff --git a/gosa-plugins/sudo/admin/sudo/class_sudoGeneric.inc b/gosa-plugins/sudo/admin/sudo/class_sudoGeneric.inc
index 4c19b95b9e39a9d0ba2e4ce59b75e5012d1fed62..16e0c5b5e04003b6261c7e11a91557fc3174820d 100644 (file)
/* Add selected hosts to the sudoUser list */
if(isset($_POST['SaveMultiSelectWindow']) && $this->dialog instanceof target_list_users){
- foreach($this->dialog->list_get_selected_items() as $id){
- $cn = trim($this->dialog->list[$id]['uid'][0]);
+ foreach($this->dialog->save() as $entry){
+ $cn = trim($entry['uid'][0]);
if(!in_array($cn,$this->sudoUser) && !in_array("!".$cn,$this->sudoUser)){
$this->sudoUser[] = $cn;
}
/* Add selected hosts to the sudoHost list */
if(isset($_POST['SaveMultiSelectWindow']) && $this->dialog instanceof target_list_systems){
- foreach($this->dialog->list_get_selected_items() as $id){
- $cn = trim($this->dialog->list[$id]['cn'][0]);
+ foreach($this->dialog->save() as $entry){
+ $cn = trim($entry['cn'][0]);
if(!in_array($cn,$this->sudoHost) && !in_array("!".$cn,$this->sudoHost)){
$this->sudoHost[] = $cn;
}
diff --git a/gosa-plugins/sudo/admin/sudo/class_target_list_systems.inc b/gosa-plugins/sudo/admin/sudo/class_target_list_systems.inc
index 0bfd3defe6a2821c7126bd12f6ac536a6243a0ec..2437da5fb47cf6644050270173b0bdb1d90764ec 100644 (file)
var $Regex = "*";
/* CheckBoxes, to change default values modify $this->AddCheckBox */
- var $ogroups ;
var $servers ;
var $workstations ;
- var $incoming ;
+ var $terminals ;
/* Subsearch checkbox */
var $SubSearch ;
- var $IPMatch ;
var $parent ;
var $ui ;
}
/* Load possible departments */
- $ui= get_userinfo();
- $tdeps= $ui->get_module_departments("ogroups");
+ $tdeps= $ui->get_module_departments(array("server","terminal","workstation"));
$ids = $this->config->idepartments;
$first = "";
$found = FALSE;
$this->selectedBase = $first;
}
- /* Get copy & paste icon */
- $acls = $ui->get_permissions($this->selectedBase,"ogroups/ogroup");
- $acl_all= $ui->has_complete_category_acls($this->selectedBase,"ogroups");
-
/* Add default header */
$listhead = MultiSelectWindow::get_default_header();
$ui = get_userinfo();
- // Assigning ogroups
+ // Assigning systems
foreach($list as $key => $val){
if(in_array($val['cn'][0],$this->Targets_used) ||
}else{
$desc = " - [ ".$val['description'][0]." ]";
}
- if(!isset($val['ipHostNumber'][0])){
- $desc.= "";
- }else{
- $desc.= " - ".$val['ipHostNumber'][0]."";
- }
-
- $img ="Hmm";
+ $img ="?";
if(in_array("goServer",$val['objectClass'])){
$img = "<img src='images/select_server.png' alt='"._("Server")."' ".$title.">";
}elseif(in_array("gotoWorkstation",$val['objectClass'])){
$img = "<img src='images/select_workstation.png' alt='"._("Workstation")."' ".$title.">";
}elseif(in_array("gotoTerminal",$val['objectClass'])){
$img = "<img src='images/select_terminal.png' alt='"._("Terminal")."' ".$title.">";
- }else{
- print_a($val);
}
/* Create each field */
if($this->SubSearch){
$res= get_list($filter, array("terminal","workstation","server"), $base,
- array("cn","objectClass","gosaGroupObjects","ipHostNumber","description"), GL_SIZELIMIT | GL_SUBSEARCH);
+ array("cn","objectClass","gosaGroupObjects","description"), GL_SIZELIMIT | GL_SUBSEARCH);
}else{
$res= get_list($filter, "terminal", get_ou('terminalou').$base,
array("cn","objectClass","description"), GL_SIZELIMIT );