Completed
Push — master ( 1063d7...a7489f )
by Laurent
03:16
created

CompanyRepository   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 27
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Importance

Changes 0
Metric Value
wmc 2
c 0
b 0
f 0
lcom 0
cbo 3
dl 0
loc 27
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A getAllItems() 0 7 1
A getItems() 0 6 1
1
<?php
2
3
/**
4
 * Entité Company.
5
 *
6
 * PHP Version 5
7
 *
8
 * @author    Quétier Laurent <[email protected]>
9
 * @copyright 2014 Dev-Int GLSR
10
 * @license   http://opensource.org/licenses/gpl-license.php GNU Public License
11
 *
12
 * @version GIT: <git_id>
13
 *
14
 * @link https://github.com/Dev-Int/glsr
15
 */
16
namespace AppBundle\Repository\Settings;
17
18
use Doctrine\ORM\EntityRepository;
19
20
/**
21
 * CompanyRepository Entité Company.
22
 *
23
 * @category Entity
24
 */
25
class CompanyRepository extends EntityRepository
26
{
27
    /**
28
     * Affiche toutes les entreprises.
29
     *
30
     * @return QueryBuilder Requête DQL
31
     */
32
    public function getAllItems()
33
    {
34
        $query = $this->createQueryBuilder('t')
35
            ->getQuery()->getResult();
36
        
37
        return $query;
38
    }
39
40
    /**
41
     * Affiche les entreprises actives.
42
     *
43
     * @return QueryBuilder Requête DQL
44
     */
45
    public function getItems()
46
    {
47
        $query = $this->getAllItems();
48
49
        return $query;
50
    }
51
}
52