Completed
Pull Request — 4.0 (#4440)
by
unknown
05:13
created

MailTemplateRepository::getList()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 3
CRAP Score 1.0156

Importance

Changes 0
Metric Value
cc 1
nc 1
nop 0
dl 0
loc 8
ccs 3
cts 4
cp 0.75
crap 1.0156
rs 10
c 0
b 0
f 0
1
<?php
2
3
/*
4
 * This file is part of EC-CUBE
5
 *
6
 * Copyright(c) EC-CUBE CO.,LTD. All Rights Reserved.
7
 *
8
 * http://www.ec-cube.co.jp/
9
 *
10
 * For the full copyright and license information, please view the LICENSE
11
 * file that was distributed with this source code.
12
 */
13
14
namespace Eccube\Repository;
15
16
use Eccube\Entity\MailTemplate;
17
use Symfony\Bridge\Doctrine\RegistryInterface;
18
19
/**
20
 * MailTemplateRepository
21
 *
22
 * This class was generated by the Doctrine ORM. Add your own custom
23
 * repository methods below.
24
 */
25
class MailTemplateRepository extends AbstractRepository
26
{
27 149
    public function __construct(RegistryInterface $registry)
28
    {
29 149
        parent::__construct($registry, MailTemplate::class);
30
    }
31
32
    /**
33
     * getList
34
     *
35
     * @return array|null
36
     */
37
    public function getList()
38
    {
39 2
        $qb = $this->createQueryBuilder('m')
40
            ->orderBy('m.id');
41 2
42 2
        return $qb->getQuery()
43
            ->getResult();
44
    }
45
}
46