summaryrefslogtreecommitdiff
path: root/app/Api/Procedure/BoardProcedure.php
blob: 69daaf09bfaedc72790d954f6af0708c165854a0 (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
<?php

namespace Kanboard\Api\Procedure;

use Kanboard\Api\Authorization\ProjectAuthorization;

/**
 * Board API controller
 *
 * @package  Kanboard\Api\Procedure
 * @author   Frederic Guillot
 */
class BoardProcedure extends BaseProcedure
{
    public function getBoard($project_id)
    {
        ProjectAuthorization::getInstance($this->container)->check($this->getClassName(), 'getBoard', $project_id);
        
        return $this->boardFormatter
            ->withProjectId($project_id)
            ->withQuery($this->taskFinderModel->getExtendedQuery())
            ->format();
    }
}