Passed
Push — master ( bf42cc...349842 )
by Peter
05:57
created

ContactForm   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 39
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
eloc 14
c 1
b 0
f 0
dl 0
loc 39
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A __construct() 0 17 1
1
<?php
2
3
declare(strict_types=1);
4
5
namespace AbterPhp\Contact\Http\Controllers\Admin\Grid;
6
7
use AbterPhp\Contact\Service\RepoGrid\Form as RepoGrid;
8
use AbterPhp\Framework\Assets\AssetManager;
9
use AbterPhp\Framework\Http\Controllers\Admin\GridAbstract;
10
use AbterPhp\Framework\I18n\ITranslator;
11
use AbterPhp\Framework\Session\FlashService;
12
use Opulence\Events\Dispatchers\IEventDispatcher;
13
use Opulence\Routing\Urls\UrlGenerator;
14
use Psr\Log\LoggerInterface;
15
16
class ContactForm extends GridAbstract
17
{
18
    const ENTITY_SINGULAR = 'contactForm';
19
    const ENTITY_PLURAL   = 'contactForms';
20
21
    const ENTITY_TITLE_SINGULAR = 'contact:contactForm';
22
    const ENTITY_TITLE_PLURAL   = 'contact:contactForms';
23
24
    /** @var string */
25
    protected $resource = 'contactforms';
26
27
    /**
28
     * Form constructor.
29
     *
30
     * @param FlashService     $flashService
31
     * @param ITranslator      $translator
32
     * @param UrlGenerator     $urlGenerator
33
     * @param LoggerInterface  $logger
34
     * @param AssetManager     $assets
35
     * @param RepoGrid         $repoGrid
36
     * @param IEventDispatcher $eventDispatcher
37
     */
38
    public function __construct(
39
        FlashService $flashService,
40
        ITranslator $translator,
41
        UrlGenerator $urlGenerator,
42
        LoggerInterface $logger,
43
        AssetManager $assets,
44
        RepoGrid $repoGrid,
45
        IEventDispatcher $eventDispatcher
46
    ) {
47
        parent::__construct(
48
            $flashService,
49
            $translator,
50
            $urlGenerator,
51
            $logger,
52
            $assets,
53
            $repoGrid,
54
            $eventDispatcher
55
        );
56
    }
57
}
58