From: hickert Date: Thu, 20 May 2010 06:59:21 +0000 (+0000) Subject: Updated server service X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=af1c62bbb12810af54a5c695cb5f27945ac54b1e;p=gosa.git Updated server service -Sorted menu entries. git-svn-id: https://oss.gonicus.de/repositories/gosa/trunk@18564 594d385d-05f5-0310-b6e9-bd551577e9d8 --- diff --git a/gosa-plugins/systems/admin/systems/class_serverService.inc b/gosa-plugins/systems/admin/systems/class_serverService.inc index 7cb9b9683..1256d1be8 100644 --- a/gosa-plugins/systems/admin/systems/class_serverService.inc +++ b/gosa-plugins/systems/admin/systems/class_serverService.inc @@ -104,11 +104,21 @@ class ServerService extends management "; $serviceList = ""; - foreach($this->getAllUnusedServices() as $name => $desc){ + + // Sort entries by alphabet + $list = array(); + $services = $this->getAllUnusedServices(); + foreach($services as $name => $desc){ + $list[_($desc).$name] = $name; + } + ksort($list); + + // Create menu entries -> create -> services[] + foreach($list as $name){ + $desc = $services[$name]; $serviceList.= sprintf($template, $name,_($desc)); } $contents = preg_replace("/%SERVICES%/",$serviceList, $contents); - $headpage = new listing($contents,TRUE); $headpage->registerElementFilter("filterServiceStatus", "ServerService::filterServiceStatus"); $headpage->setFilter($filter);