Code Duplication    Length = 11-12 lines in 3 locations

src/controllers/AnswerController.php 1 location

@@ 20-31 (lines=12) @@
17
18
class AnswerController extends \hipanel\base\CrudController
19
{
20
    public function behaviors()
21
    {
22
        return array_merge(parent::behaviors(), [
23
            [
24
                'class' => EasyAccessControl::class,
25
                'actions' => [
26
                    'update' => 'ticket.answer',
27
                    '*' => 'ticket.read',
28
                ],
29
            ],
30
        ]);
31
    }
32
33
    public function actions()
34
    {

src/controllers/StatisticController.php 1 location

@@ 20-31 (lines=12) @@
17
18
class StatisticController extends \hipanel\base\CrudController
19
{
20
    public function behaviors()
21
    {
22
        return array_merge(parent::behaviors(), [
23
            [
24
                'class' => EasyAccessControl::class,
25
                'actions' => [
26
                    '*' => 'manage',
27
                ],
28
29
            ],
30
        ]);
31
    }
32
33
    /**
34
     * @return array

src/controllers/TemplateController.php 1 location

@@ 32-42 (lines=11) @@
29
30
class TemplateController extends \hipanel\base\CrudController
31
{
32
    public function behaviors()
33
    {
34
        return array_merge(parent::behaviors(), [
35
            [
36
                'class' => EasyAccessControl::class,
37
                'actions' => [
38
                    '*' => 'support',
39
                ],
40
            ],
41
        ]);
42
    }
43
44
    public function actions()
45
    {