From f438b2c85670201c39e3697860518609765f389a Mon Sep 17 00:00:00 2001 From: Jan Schneider Date: Wed, 24 Feb 2010 00:36:23 +0100 Subject: [PATCH] Add option to not automatically show all available shares. --- horde/config/conf.xml | 4 +++ horde/docs/CHANGES | 1 + kronolith/data.php | 22 +++++++++++++++++ kronolith/lib/Api.php | 5 ++++ kronolith/lib/Application.php | 6 ++--- kronolith/lib/Block/month.php | 5 ++++ kronolith/lib/Block/monthlist.php | 5 ++++ kronolith/lib/Block/prevmonthlist.php | 5 ++++ kronolith/lib/Block/summary.php | 5 ++++ kronolith/lib/Kronolith.php | 28 +++++++++++++++------ kronolith/lib/View/EditEvent.php | 11 ++++++++- kronolith/new.php | 12 ++++++++- kronolith/search.php | 8 ++++++ kronolith/templates/data/export.inc | 4 +-- kronolith/templates/data/import.inc | 4 +-- kronolith/templates/panel.inc | 41 ++++++++++++++++++++++--------- kronolith/templates/prefs/shareselect.inc | 15 ++++++++--- nag/data.php | 22 +++++++++++++++++ nag/lib/Api.php | 11 ++++++--- nag/lib/Application.php | 5 ++-- nag/lib/Block/summary.php | 5 ++++ nag/lib/Block/tree_menu.php | 5 ++++ nag/lib/Forms/task.php | 11 ++++++--- nag/templates/data/export.inc | 4 +-- nag/templates/data/import.inc | 4 +-- nag/templates/panel.inc | 4 +++ nag/templates/prefs/tasklistselect.inc | 11 ++++++++- 27 files changed, 219 insertions(+), 44 deletions(-) diff --git a/horde/config/conf.xml b/horde/config/conf.xml index 505b02fdf..53063edda 100644 --- a/horde/config/conf.xml +++ b/horde/config/conf.xml @@ -1065,6 +1065,10 @@ regardless of whether or not they are a member. If you disable it, users will only be able to share their resources with groups they are members of.">false + false Share Caching Enabling share caching improves performance because the share backend will only be queried once per session. But it also increases diff --git a/horde/docs/CHANGES b/horde/docs/CHANGES index ccf96e04e..4ecbe06aa 100644 --- a/horde/docs/CHANGES +++ b/horde/docs/CHANGES @@ -2,6 +2,7 @@ v4.0-cvs -------- +[jan] Add option to not automatically show all available shares. [jan] Add option to disallow world permissions for user shares. [mms] Allow Mozilla DNS prefetching to be turned off when displaying untrusted content (Ticket #8836). diff --git a/kronolith/data.php b/kronolith/data.php index 006a4289d..62f525b68 100644 --- a/kronolith/data.php +++ b/kronolith/data.php @@ -296,6 +296,28 @@ if (is_array($next_step)) { $next_step = $data->cleanup(); } +$import_calendars = $export_calendars = array(); +if (Horde_Auth::getAuth()) { + $calendars = Kronolith::listCalendars(false, Horde_Perms::EDIT); + foreach ($calendars as $id => $calendar) { + if ($calendar->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($calendar->getName(), $GLOBALS['display_calendars'])) { + continue; + } + $import_calendars[$id] = $calendar; + } +} +$calendars = Kronolith::listCalendars(false, Horde_Perms::READ); +foreach ($calendars as $id => $calendar) { + if ($calendar->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($calendar->getName(), $GLOBALS['display_calendars'])) { + continue; + } + $export_calendars[$id] = $calendar; +} + $title = _("Import/Export Calendar"); require KRONOLITH_TEMPLATES . '/common-header.inc'; require KRONOLITH_TEMPLATES . '/menu.inc'; diff --git a/kronolith/lib/Api.php b/kronolith/lib/Api.php index 473f1a193..24c8d4c18 100644 --- a/kronolith/lib/Api.php +++ b/kronolith/lib/Api.php @@ -75,6 +75,11 @@ class Kronolith_Api extends Horde_Registry_Api $calendars = Kronolith::listCalendars(false, Horde_Perms::READ); $owners = array(); foreach ($calendars as $calendar) { + if ($calendar->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($calendar->getName(), $GLOBALS['display_calendars'])) { + continue; + } $owners[$calendar->get('owner')] = true; } diff --git a/kronolith/lib/Application.php b/kronolith/lib/Application.php index 188e2dd3c..7dba3212f 100644 --- a/kronolith/lib/Application.php +++ b/kronolith/lib/Application.php @@ -257,8 +257,9 @@ class Kronolith_Application extends Horde_Registry_Application $default_share = Horde_Util::getFormData('default_share'); if (!is_null($default_share)) { $sharelist = Kronolith::listCalendars(); - if ((is_array($sharelist)) > 0 && - isset($sharelist[$default_share])) { + if (isset($sharelist[$default_share]) && + ($sharelist[$default_share]->get('owner') == Horde_Auth::getAuth() || + in_array($default_share, $GLOBALS['display_calendars']))) { $GLOBALS['prefs']->setValue('default_share', $default_share); return true; } @@ -293,7 +294,6 @@ class Kronolith_Application extends Horde_Registry_Application protected function _prefsFbCalsSelect() { $fb_calsSelected = Horde_Util::getFormData('fb_cals'); - $fb_cals = Kronolith::listCalendars(); $fb_calsFiltered = array(); if (isset($fb_calsSelected) && is_array($fb_calsSelected)) { diff --git a/kronolith/lib/Block/month.php b/kronolith/lib/Block/month.php index ba8420d8d..ff81f7849 100644 --- a/kronolith/lib/Block/month.php +++ b/kronolith/lib/Block/month.php @@ -20,6 +20,11 @@ class Horde_Block_Kronolith_month extends Horde_Block { 'default' => '__all')); $params['calendar']['values']['__all'] = _("All Visible"); foreach (Kronolith::listCalendars() as $id => $cal) { + if ($cal->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($cal->getName(), $GLOBALS['display_calendars'])) { + continue; + } $params['calendar']['values'][$id] = $cal->get('name'); } diff --git a/kronolith/lib/Block/monthlist.php b/kronolith/lib/Block/monthlist.php index 639cb9c28..2cffa5f43 100644 --- a/kronolith/lib/Block/monthlist.php +++ b/kronolith/lib/Block/monthlist.php @@ -28,6 +28,11 @@ class Horde_Block_Kronolith_monthlist extends Horde_Block { 'default' => 0)); $params['calendar']['values']['__all'] = _("All Visible"); foreach (Kronolith::listCalendars() as $id => $cal) { + if ($cal->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($cal->getName(), $GLOBALS['display_calendars'])) { + continue; + } $params['calendar']['values'][$id] = $cal->get('name'); } diff --git a/kronolith/lib/Block/prevmonthlist.php b/kronolith/lib/Block/prevmonthlist.php index 31f27ccac..f9164b0e9 100644 --- a/kronolith/lib/Block/prevmonthlist.php +++ b/kronolith/lib/Block/prevmonthlist.php @@ -25,6 +25,11 @@ class Horde_Block_Kronolith_prevmonthlist extends Horde_Block { 'default' => 0)); $params['calendar']['values']['__all'] = _("All Visible"); foreach (Kronolith::listCalendars() as $id => $cal) { + if ($cal->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($cal->getName(), $GLOBALS['display_calendars'])) { + continue; + } $params['calendar']['values'][$id] = $cal->get('name'); } diff --git a/kronolith/lib/Block/summary.php b/kronolith/lib/Block/summary.php index 9de246882..310e2c08a 100644 --- a/kronolith/lib/Block/summary.php +++ b/kronolith/lib/Block/summary.php @@ -46,6 +46,11 @@ class Horde_Block_Kronolith_summary extends Horde_Block { 'default' => 0)); $params['calendar']['values']['__all'] = _("All Visible"); foreach (Kronolith::listCalendars() as $id => $cal) { + if ($cal->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($cal->getName(), $GLOBALS['display_calendars'])) { + continue; + } $params['calendar']['values'][$id] = $cal->get('name'); } diff --git a/kronolith/lib/Kronolith.php b/kronolith/lib/Kronolith.php index 8d003f5fe..488897378 100644 --- a/kronolith/lib/Kronolith.php +++ b/kronolith/lib/Kronolith.php @@ -169,16 +169,16 @@ class Kronolith */ public static function includeJSVars() { - global $browser, $conf, $prefs, $registry; + global $prefs, $registry; $kronolith_webroot = $registry->get('webroot'); $horde_webroot = $registry->get('webroot', 'horde'); - $has_tasks = $GLOBALS['registry']->hasInterface('tasks'); + $has_tasks = $registry->hasInterface('tasks'); $app_urls = array(); if (isset($GLOBALS['conf']['menu']['apps']) && is_array($GLOBALS['conf']['menu']['apps'])) { foreach ($GLOBALS['conf']['menu']['apps'] as $app) { - $app_urls[$app] = (string) Horde::url($GLOBALS['registry']->getInitialPage($app), true); + $app_urls[$app] = (string) Horde::url($registry->getInitialPage($app), true); } } @@ -195,7 +195,7 @@ class Kronolith 'app_urls' => $app_urls, 'name' => $registry->get('name'), 'has_tasks' => $has_tasks, - 'is_ie6' => ($browser->isBrowser('msie') && ($browser->getMajor() < 7)), + 'is_ie6' => ($GLOBALS['browser']->isBrowser('msie') && ($GLOBALS['browser']->getMajor() < 7)), 'login_view' => $prefs->getValue('defaultview'), 'default_calendar' => 'internal|' . self::getDefaultCalendar(Horde_Perms::EDIT), 'week_start' => (int)$prefs->getValue('week_start_monday'), @@ -225,12 +225,17 @@ class Kronolith ); if ($has_tasks) { - $code['conf']['tasks'] = $GLOBALS['registry']->tasks->ajaxDefaults(); + $code['conf']['tasks'] = $registry->tasks->ajaxDefaults(); } // Calendars foreach (array(true, false) as $my) { foreach ($GLOBALS['all_calendars'] as $id => $calendar) { + if ($calendar->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($calendar->getName(), $GLOBALS['display_calendars'])) { + continue; + } $owner = Horde_Auth::getAuth() && $calendar->get('owner') == Horde_Auth::getAuth(); if (($my && $owner) || (!$my && !$owner)) { @@ -250,7 +255,12 @@ class Kronolith if (!$has_tasks) { continue; } - foreach ($GLOBALS['registry']->tasks->listTasklists($my, Horde_Perms::SHOW) as $id => $tasklist) { + foreach ($registry->tasks->listTasklists($my, Horde_Perms::SHOW) as $id => $tasklist) { + if ($tasklist->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array('tasks/' . $id, $GLOBALS['display_external_calendars'])) { + continue; + } $owner = Horde_Auth::getAuth() && $tasklist->get('owner') == Horde_Auth::getAuth(); if (($my && $owner) || (!$my && !$owner)) { @@ -273,12 +283,16 @@ class Kronolith if ($api == 'tasks') { continue; } + if (!empty($GLOBALS['conf']['share']['hidden']) && + !in_array($api . '/' . $id, $GLOBALS['display_external_calendars'])) { + continue; + } $calendar = $api . '/' . $id; $code['conf']['calendars']['external'][$calendar] = array( 'name' => $name, 'fg' => '#000', 'bg' => '#ddd', - 'api' => $GLOBALS['registry']->get('name', $GLOBALS['registry']->hasInterface($api)), + 'api' => $registry->get('name', $registry->hasInterface($api)), 'show' => in_array($calendar, $GLOBALS['display_external_calendars'])); } } diff --git a/kronolith/lib/View/EditEvent.php b/kronolith/lib/View/EditEvent.php index dddef579c..06e4049b7 100644 --- a/kronolith/lib/View/EditEvent.php +++ b/kronolith/lib/View/EditEvent.php @@ -74,7 +74,16 @@ class Kronolith_View_EditEvent { if ($this->event->creator == Horde_Auth::getAuth()) { $perms |= Kronolith::PERMS_DELEGATE; } - $calendars = Kronolith::listCalendars(false, $perms); + $all_calendars = Kronolith::listCalendars(false, $perms); + $calendars = array(); + foreach ($all_calendars as $id => $calendar) { + if ($calendar->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($calendar->getName(), $GLOBALS['display_calendars'])) { + continue; + } + $calendars[$id] = $calendar; + } $buttons = array(); if (!$this->event->hasPermission(Horde_Perms::EDIT) && diff --git a/kronolith/new.php b/kronolith/new.php index 06425ed09..b5a11a589 100644 --- a/kronolith/new.php +++ b/kronolith/new.php @@ -64,8 +64,18 @@ if (isset($url)) { $cancelurl = Horde::applicationUrl('month.php', true)->add('month', $month); } +$all_calendars = Kronolith::listCalendars(false, Horde_Perms::EDIT | Kronolith::PERMS_DELEGATE); +$calendars = array(); +foreach ($all_calendars as $id => $calendar) { + if ($calendar->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($calendar->getName(), $GLOBALS['display_calendars'])) { + continue; + } + $calendars[$id] = $calendar; +} + $title = _("Add a new event"); -$calendars = Kronolith::listCalendars(false, Horde_Perms::EDIT | Kronolith::PERMS_DELEGATE); Horde::addScriptFile('new.js', 'kronolith'); Horde::addScriptFile('popup.js', 'horde'); require KRONOLITH_TEMPLATES . '/common-header.inc'; diff --git a/kronolith/search.php b/kronolith/search.php index 387b53f1c..cebd69a58 100644 --- a/kronolith/search.php +++ b/kronolith/search.php @@ -71,12 +71,20 @@ if ($search_mode == 'basic') { if ($cal->get('owner') && $cal->get('owner') == $current_user) { $calendars[_("My Calendars:")]['|' . $id] = $cal->get('name'); } else { + if (!empty($GLOBALS['conf']['share']['hidden']) && + !in_array($cal->getName(), $GLOBALS['display_calendars'])) { + continue; + } $calendars[_("Shared Calendars:")]['|' . $id] = $cal->get('name'); } } foreach ($GLOBALS['all_external_calendars'] as $api => $categories) { $app = $GLOBALS['registry']->get('name', $GLOBALS['registry']->hasInterface($api)); foreach ($categories as $id => $name) { + if (!empty($GLOBALS['conf']['share']['hidden']) && + !in_array($api . '/' . $id, $GLOBALS['display_external_calendars'])) { + continue; + } $calendars[$app . ':']['Horde|external_' . $api . '/' . $id] = $name; } } diff --git a/kronolith/templates/data/export.inc b/kronolith/templates/data/export.inc index 279ed57bc..3e89317e3 100644 --- a/kronolith/templates/data/export.inc +++ b/kronolith/templates/data/export.inc @@ -15,10 +15,10 @@

- 1): ?> + 1): ?>


diff --git a/kronolith/templates/data/import.inc b/kronolith/templates/data/import.inc index 141c7a3eb..747f71aea 100644 --- a/kronolith/templates/data/import.inc +++ b/kronolith/templates/data/import.inc @@ -14,10 +14,10 @@
- isLocked('default_share') && count($calendars = Kronolith::listCalendars(false, Horde_Perms::EDIT)) > 1): ?> + isLocked('default_share') && count($import_calendars ) > 1): ?>


diff --git a/kronolith/templates/panel.inc b/kronolith/templates/panel.inc index a79e2baec..64aa186e2 100644 --- a/kronolith/templates/panel.inc +++ b/kronolith/templates/panel.inc @@ -20,10 +20,29 @@ foreach (Kronolith::listCalendars() as $id => $cal) { if ($cal->get('owner') && $cal->get('owner') == $current_user) { $my_calendars[$id] = $cal; } else { + if (!empty($conf['share']['hidden']) && + !in_array($cal->getName(), $display_calendars)) { + continue; + } $shared_calendars[$id] = $cal; } } +$externals = array(); +foreach ($all_external_calendars as $api => $categories) { + if (count($categories)) { + $app = $registry->get('name', $registry->hasInterface($api)); + $externals[$app] = array(); + foreach ($categories as $id => $name) { + if (!empty($conf['share']['hidden']) && + !in_array($api . '/' . $id, $display_external_calendars)) { + continue; + } + $externals[$app][$api . '/' . $id] = $name; + } + } +} + $tagger = Kronolith::getTagger(); ?>
@@ -113,33 +132,33 @@ $ta->attach(); - +

    - $categories): ?> + $categories): ?> -
  • get('name', $GLOBALS['registry']->hasInterface($api))) ?>
  • - $name): ?> -
  • - +
  • + $name): ?> +
  • + - +
- +

    - $cal): ?> + $cal): ?> >
- +

    - + >
diff --git a/kronolith/templates/prefs/shareselect.inc b/kronolith/templates/prefs/shareselect.inc index cf9979c35..6e23c5696 100644 --- a/kronolith/templates/prefs/shareselect.inc +++ b/kronolith/templates/prefs/shareselect.inc @@ -1,6 +1,15 @@ isLocked('default_share')): - $sharelist = Kronolith::listCalendars(); + $all_shares = Kronolith::listCalendars(); + $sharelist = array(); + foreach ($all_shares as $id => $share) { + if ($share->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($share->getName(), $GLOBALS['display_calendars'])) { + continue; + } + $sharelist[$id] = $share; + } if (($default_share = $prefs->getValue('default_share')) == null || !isset($sharelist[$default_share])) { $default_share = Horde_Auth::getAuth(); @@ -9,8 +18,8 @@ if (!$prefs->isLocked('default_share')):
diff --git a/nag/data.php b/nag/data.php index d6162f988..69c2ff547 100644 --- a/nag/data.php +++ b/nag/data.php @@ -223,6 +223,28 @@ if (is_array($next_step)) { $next_step = $data->cleanup(); } +$import_tasklists = $export_tasklists = array(); +if (Horde_Auth::getAuth()) { + $tasklists = Nag::listTasklists(false, Horde_Perms::EDIT); + foreach ($tasklists as $id => $tasklist) { + if ($tasklist->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($tasklist->getName(), $GLOBALS['display_tasklists'])) { + continue; + } + $import_tasklists[$id] = $tasklist; + } +} +$tasklists = Nag::listTasklists(false, Horde_Perms::READ); +foreach ($tasklists as $id => $tasklist) { + if ($tasklist->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($tasklist->getName(), $GLOBALS['display_tasklists'])) { + continue; + } + $export_tasklists[$id] = $tasklist; +} + $title = _("Import/Export Tasks"); require NAG_TEMPLATES . '/common-header.inc'; require NAG_TEMPLATES . '/menu.inc'; diff --git a/nag/lib/Api.php b/nag/lib/Api.php index 8ef354d91..93c6632bf 100644 --- a/nag/lib/Api.php +++ b/nag/lib/Api.php @@ -195,13 +195,16 @@ class Nag_Api extends Horde_Registry_Api $parts = explode('/', $path); if (empty($path)) { - // - // This request is for a list of all users who have tasklists visible - // to the requesting user. - // + // This request is for a list of all users who have tasklists + // visible to the requesting user. $tasklists = Nag::listTasklists(false, Horde_Perms::READ); $owners = array(); foreach ($tasklists as $tasklist) { + if ($tasklist->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($tasklist->getName(), $GLOBALS['display_tasklists'])) { + continue; + } $owners[$tasklist->get('owner') ? $tasklist->get('owner') : '-system-'] = true; } diff --git a/nag/lib/Application.php b/nag/lib/Application.php index f05ce13e8..cceefa3d3 100644 --- a/nag/lib/Application.php +++ b/nag/lib/Application.php @@ -106,8 +106,9 @@ class Nag_Application extends Horde_Registry_Application $default_tasklist = Horde_Util::getFormData('default_tasklist'); if (!is_null($default_tasklist)) { $tasklists = Nag::listTasklists(); - if (is_array($tasklists) && - isset($tasklists[$default_tasklist])) { + if (isset($tasklists[$default_tasklist]) && + ($tasklists[$default_tasklist]->get('owner') == Horde_Auth::getAuth() || + in_array($default_tasklist, $GLOBALS['display_tasklists']))) { $GLOBALS['prefs']->setValue('default_tasklist', $default_tasklist); return true; } diff --git a/nag/lib/Block/summary.php b/nag/lib/Block/summary.php index b9a5d263b..b7b20a999 100644 --- a/nag/lib/Block/summary.php +++ b/nag/lib/Block/summary.php @@ -32,6 +32,11 @@ class Horde_Block_nag_summary extends Horde_Block { $tasklists = array(); foreach (Nag::listTasklists() as $id => $tasklist) { + if ($tasklist->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($tasklist->getName(), $GLOBALS['display_tasklists'])) { + continue; + } $tasklists[$id] = $tasklist->get('name'); } diff --git a/nag/lib/Block/tree_menu.php b/nag/lib/Block/tree_menu.php index b5b2bd6d1..844b66708 100644 --- a/nag/lib/Block/tree_menu.php +++ b/nag/lib/Block/tree_menu.php @@ -27,6 +27,11 @@ class Horde_Block_nag_tree_menu extends Horde_Block { 'url' => $add)); foreach (Nag::listTasklists() as $name => $tasklist) { + if ($tasklist->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($tasklist->getName(), $GLOBALS['display_tasklists'])) { + continue; + } $tree->addNode($parent . $name . '__new', $parent . '__new', sprintf(_("in %s"), $tasklist->get('name')), diff --git a/nag/lib/Forms/task.php b/nag/lib/Forms/task.php index 94202b78f..15cb0d7fa 100644 --- a/nag/lib/Forms/task.php +++ b/nag/lib/Forms/task.php @@ -26,13 +26,18 @@ class Nag_TaskForm extends Horde_Form { $tasklists = Nag::listTasklists(false, Horde_Perms::EDIT); $tasklist_enums = array(); foreach ($tasklists as $tl_id => $tl) { + if ($tl->get('owner') != Horde_Auth::getAuth() && + !empty($GLOBALS['conf']['share']['hidden']) && + !in_array($tl->getName(), $GLOBALS['display_tasklists'])) { + continue; + } $tasklist_enums[$tl_id] = $tl->get('name'); } $tasklist = $vars->get('tasklist_id'); if (empty($tasklist)) { - reset($tasklists); - $tasklist = key($tasklists); + reset($tasklist_enums); + $tasklist = key($tasklist_enums); } $tasks = Nag::listTasks(null, null, null, array($tasklist), Nag::VIEW_FUTURE_INCOMPLETE); $task_enums = array('' => _("No parent task")); @@ -74,7 +79,7 @@ class Nag_TaskForm extends Horde_Form { $this->addVariable(_("Name"), 'name', 'text', true); if (!$GLOBALS['prefs']->isLocked('default_tasklist') && - count($tasklists) > 1) { + count($tasklist_enums) > 1) { $v = &$this->addVariable(_("Task List"), 'tasklist_id', 'enum', true, false, false, array($tasklist_enums)); $v->setAction(Horde_Form_Action::factory('reload')); } diff --git a/nag/templates/data/export.inc b/nag/templates/data/export.inc index 1e9cbf7de..ff17bd677 100644 --- a/nag/templates/data/export.inc +++ b/nag/templates/data/export.inc @@ -15,11 +15,11 @@

- 1): ?> + 1): ?>


diff --git a/nag/templates/data/import.inc b/nag/templates/data/import.inc index 182f5ac78..bb45abdc5 100644 --- a/nag/templates/data/import.inc +++ b/nag/templates/data/import.inc @@ -16,13 +16,13 @@

-isLocked('default_tasklist') && count($tasklists = Nag::listTasklists(false, Horde_Perms::EDIT)) > 1): ?> +isLocked('default_tasklist') && count($import_tasklists) > 1): ?>