diff --git a/Controller/BackendController.php b/Controller/BackendController.php index dc8edc4..afa343e 100755 --- a/Controller/BackendController.php +++ b/Controller/BackendController.php @@ -112,6 +112,21 @@ final class BackendController extends Controller implements DashboardElementInte $view->data['open'] = $open; + // given + // @todo: this should also include forwarded tasks + /** @var \Modules\Tasks\Models\Task[] $given */ + $given = TaskMapper::getAll() + ->with('createdBy') + ->with('tags') + ->with('tags/title') + ->where('tags/title/language', $response->header->l11n->language) + ->where('status', TaskStatus::OPEN) + ->where('createdBy', $response->header->account, '=') + ->sort('createdAt', OrderType::DESC) + ->execute(); + + $view->data['given'] = $given; + /** @var \Modules\Tasks\Models\TaskSeen[] $unread */ $unread = TaskSeenMapper::getAll() ->where('task', \array_keys($open), 'in') diff --git a/Theme/Backend/task-dashboard.tpl.php b/Theme/Backend/task-dashboard.tpl.php index 70d5e9b..38c4e39 100755 --- a/Theme/Backend/task-dashboard.tpl.php +++ b/Theme/Backend/task-dashboard.tpl.php @@ -98,7 +98,7 @@ echo $this->data['nav']->render(); ?>