Simplify dashboard to use new tasks list view

This commit is contained in:
Frederic Guillot
2017-03-12 21:36:52 -04:00
parent f6b42eb802
commit 9b34631135
31 changed files with 380 additions and 650 deletions

View File

@@ -2,8 +2,6 @@
namespace Kanboard\Api\Procedure;
use Kanboard\Model\SubtaskModel;
/**
* Me API controller
*
@@ -19,15 +17,12 @@ class MeProcedure extends BaseProcedure
public function getMyDashboard()
{
$user_id = $this->userSession->getId();
$projects = $this->projectModel->getQueryColumnStats($this->projectPermissionModel->getActiveProjectIds($user_id))->findAll();
$tasks = $this->taskFinderModel->getUserQuery($user_id)->findAll();
$userId = $this->userSession->getId();
return array(
'projects' => $this->formatProjects($projects),
'tasks' => $this->formatTasks($tasks),
'subtasks' => $this->subtaskModel->getUserQuery($user_id, array(SubtaskModel::STATUS_TODO, SubtaskModel::STATUS_INPROGRESS))->findAll(),
);
return $this->taskListSubtaskAssigneeFormatter
->withQuery($this->taskFinderModel->getUserQuery($userId))
->withUserId($userId)
->format();
}
public function getMyActivityStream()