From 3b9ae54b2e71fcbf4fc8b50f59b0bd2a55ff72c7 Mon Sep 17 00:00:00 2001 From: "Michael J. Rubinsky" Date: Wed, 12 May 2010 19:01:30 -0400 Subject: [PATCH] Add activesync page to admin menu, render tree nodes closed by default --- horde/admin/activesync.php | 2 +- horde/lib/Api.php | 12 +++++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/horde/admin/activesync.php b/horde/admin/activesync.php index 21bf97dcd..f748349b1 100644 --- a/horde/admin/activesync.php +++ b/horde/admin/activesync.php @@ -92,7 +92,7 @@ foreach ($devices as $device) { $node_params = array(); if (array_search($device['device_user'], $users) === false) { $users[] = $device['device_user']; - $tree->addNode($device['device_user'], 'root', $device['device_user'], 0, true, $user_node); + $tree->addNode($device['device_user'], 'root', $device['device_user'], 0, false, $user_node); } /* Load this device */ diff --git a/horde/lib/Api.php b/horde/lib/Api.php index 0204a417c..b9f3d9637 100644 --- a/horde/lib/Api.php +++ b/horde/lib/Api.php @@ -14,7 +14,7 @@ class Horde_Api extends Horde_Registry_Api */ public function admin_list() { - return array( + $admin = array( 'configuration' => array( 'link' => '%application%/admin/setup/', 'name' => _("_Setup"), @@ -66,6 +66,16 @@ class Horde_Api extends Horde_Registry_Api 'icon' => 'shell.png' ) ); + + if (!empty($GLOBALS['conf']['activesync']['enabled'])) { + $admin['activesync'] = array( + 'link' => '%application%/admin/activesync.php', + 'name' => _("ActiveSync Devices"), + 'icon' => 'mobile.png' + ); + } + + return $admin; } /** -- 2.11.0