Provide the backend with the tasks to be displayed when generating the
authorGunnar Wrobel <p@rdus.de>
Wed, 10 Mar 2010 08:33:42 +0000 (09:33 +0100)
committerGunnar Wrobel <p@rdus.de>
Wed, 10 Mar 2010 08:33:42 +0000 (09:33 +0100)
URL to redirect to.

This allows to use tasks that redirect to their own specific handler.

framework/LoginTasks/lib/Horde/LoginTasks.php
framework/LoginTasks/lib/Horde/LoginTasks/Backend.php
framework/LoginTasks/lib/Horde/LoginTasks/Backend/Horde.php

index b2ab005..38d1fce 100644 (file)
@@ -274,7 +274,7 @@ class Horde_LoginTasks
      */
     public function getLoginTasksUrl()
     {
-        return $this->_backend->getLoginTasksUrl();
+        return $this->_backend->getLoginTasksUrl($this->_tasklist->needDisplay());
     }
 
     /**
index 93dc64e..3fa7c8b 100644 (file)
@@ -92,7 +92,9 @@ abstract class Horde_LoginTasks_Backend
     /**
      * Return the URL of the login tasks view.
      *
+     * @param array $tasks The tasks to be displayed next.
+     *
      * @return string The URL of the login tasks view
      */
-    abstract public function getLoginTasksUrl();
+    abstract public function getLoginTasksUrl(array $tasks = null);
 }
\ No newline at end of file
index 2fa88a8..1ec6eee 100644 (file)
@@ -184,9 +184,11 @@ extends Horde_LoginTasks_Backend
     /**
      * Return the URL of the login tasks view.
      *
+     * @param array $tasks The tasks to be displayed next.
+     *
      * @return string The URL of the login tasks view
      */
-    public function getLoginTasksUrl()
+    public function getLoginTasksUrl(array $tasks = null)
     {
         return Horde::url(Horde_Util::addParameter($this->_registry->get('webroot', 'horde') . '/services/logintasks.php', array('app' => $this->_app)), true);
     }