summaryrefslogtreecommitdiff
path: root/app/Controller/ProjectOverviewController.php
blob: 33bec07864e1c18dd59258adfc57965b3a90967b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
<?php

namespace Kanboard\Controller;

/**
 * Project Overview Controller
 *
 * @package  Kanboard\Controller
 * @author   Frederic Guillot
 */
class ProjectOverviewController extends BaseController
{
    /**
     * Show project overview
     */
    public function show()
    {
        $project = $this->getProject();
        $columns = $this->columnModel->getAllWithTasksCount($project['id']);

        $this->response->html($this->helper->layout->app('project_overview/show', array(
            'project'     => $project,
            'columns'     => $columns,
            'title'       => $project['name'],
            'description' => $this->helper->projectHeader->getDescription($project),
            'users'       => $this->projectUserRoleModel->getAllUsersGroupedByRole($project['id']),
            'roles'       => $this->projectRoleModel->getList($project['id']),
            'events'      => $this->helper->projectActivity->getProjectEvents($project['id'], 10),
            'images'      => $this->projectFileModel->getAllImages($project['id']),
            'files'       => $this->projectFileModel->getAllDocuments($project['id']),
        )));
    }
}