From 97bf29a1ff2af9cf74ab1fbeab6e692c8b8b8275 Mon Sep 17 00:00:00 2001 From: hickert Date: Mon, 7 Aug 2006 06:00:31 +0000 Subject: [PATCH] Updated environment profile server list git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@4405 594d385d-05f5-0310-b6e9-bd551577e9d8 --- include/class_config.inc | 10 +++++++--- plugins/personal/environment/class_environment.inc | 3 +-- plugins/personal/environment/main.inc | 10 ++++------ 3 files changed, 12 insertions(+), 11 deletions(-) diff --git a/include/class_config.inc b/include/class_config.inc index 13c87c11d..169b576aa 100644 --- a/include/class_config.inc +++ b/include/class_config.inc @@ -664,14 +664,18 @@ class config { } /* This function returns all available ShareServer */ - function getShareServerList() + function getShareServerList($categories = "") { global $config; $return = array(); $ui = get_userinfo(); $base = $config->current['BASE']; -echo "Need to adapt share list loading
"; - $res= get_list("(&(objectClass=goShareServer)(goExportEntry=*))", "all", $base,array("goExportEntry","cn"),GL_SUBSEARCH); + + if(empty($categories)){ + echo "Need to adapt share list loading
"; + } + + $res= get_list("(&(objectClass=goShareServer)(goExportEntry=*))", $categories, $base,array("goExportEntry","cn"),GL_SUBSEARCH); foreach($res as $entry){ if(isset($entry['goExportEntry']['count'])){ unset($entry['goExportEntry']['count']); diff --git a/plugins/personal/environment/class_environment.inc b/plugins/personal/environment/class_environment.inc index 976ebd641..d551a3b7c 100644 --- a/plugins/personal/environment/class_environment.inc +++ b/plugins/personal/environment/class_environment.inc @@ -228,8 +228,7 @@ class environment extends plugin } } - - $this->gotoProfileServers= $config->getShareServerList() ; + $this->gotoProfileServers= $config->getShareServerList("server") ; $this->gotoShareSelections= $config->getShareList(true); $this->gotoAvailableShares= $config->getShareList(false); diff --git a/plugins/personal/environment/main.inc b/plugins/personal/environment/main.inc index 0af0fb11e..06b14f265 100644 --- a/plugins/personal/environment/main.inc +++ b/plugins/personal/environment/main.inc @@ -99,14 +99,12 @@ if (!$remove_lock){ "\"> ".$ui->dn." "; } else { $info= "\"\" ".$ui->dn." "; - # if (isset($editacl) && $editacl != "#none#"){ - $display .= "FIxme, only display edit button if there is at least one attribute writeable"; + "\"> ".$ui->dn." "; + if(preg_match("/w/",$ui->get_permissions($ui->dn,"users/environment"))){ $info.= "\"\" "._("Click the 'Edit' button below to change informations in this dialog"); + "\"> "._("Click the 'Edit' button below to change informations in this dialog"); $display.= "\n"; - # } - + } $display.= "\n"; } $display.= "

\n"; -- 2.30.2