Add Task CSV export and Kanboard CLI

This commit is contained in:
Frédéric Guillot
2014-07-19 22:08:07 -02:30
parent 42ca8390d4
commit 833bd3f8a9
25 changed files with 555 additions and 89 deletions

View File

@@ -246,4 +246,25 @@ abstract class Base
return $task;
}
/**
* Common method to get a project
*
* @access protected
* @return array
*/
protected function getProject()
{
$project_id = $this->request->getIntegerParam('project_id');
$project = $this->project->getById($project_id);
if (! $project) {
$this->session->flashError(t('Project not found.'));
$this->response->redirect('?controller=project');
}
$this->checkProjectPermissions($project['id']);
return $project;
}
}