Remove column default_project_id for users because it's useless now

This commit is contained in:
Frederic Guillot
2015-06-27 15:14:04 -04:00
parent e6e286be83
commit 6c772de184
14 changed files with 16 additions and 104 deletions

View File

@@ -44,35 +44,6 @@ class Board extends Base
)));
}
/**
* Redirect the user to the default project
*
* @access public
*/
public function index()
{
$last_seen_project_id = $this->userSession->getLastSeenProjectId();
$favorite_project_id = $this->userSession->getFavoriteProjectId();
$project_id = $last_seen_project_id ?: $favorite_project_id;
if (! $project_id) {
$projects = $this->projectPermission->getAllowedProjects($this->userSession->getId());
if (empty($projects)) {
if ($this->userSession->isAdmin()) {
$this->redirectNoProject();
}
$this->forbidden();
}
$project_id = key($projects);
}
$this->show($project_id);
}
/**
* Show a board for a given project
*
@@ -87,8 +58,6 @@ class Board extends Base
$board_selector = $projects;
unset($board_selector[$project['id']]);
$this->userSession->storeLastSeenProjectId($project['id']);
list($categories_listing, $categories_description) = $this->category->getBoardCategories($project['id']);
$this->response->html($this->template->layout('board/index', array(