Passed
Push — master ( fa3542...0a3787 )
by Mihail
05:11
created

Comments::actionRead()   A

Complexity

Conditions 3
Paths 2

Size

Total Lines 11
Code Lines 5

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
eloc 5
dl 0
loc 11
rs 10
c 0
b 0
f 0
cc 3
nc 2
nop 1
1
<?php
2
3
namespace Apps\Controller\Admin;
4
5
use Apps\ActiveRecord\CommentPost;
6
use Apps\Model\Admin\Comments\FormSettings;
7
use Extend\Core\Arch\AdminController;
8
use Ffcms\Core\App;
9
use Ffcms\Core\Exception\NotFoundException;
10
11
/**
12
 * Class Comments. Admin controller for management user comments.
13
 * This class provide general admin implementation of control for user comments and its settings.
14
 * @package Apps\Controller\Admin
15
 */
16
class Comments extends AdminController
17
{
18
    const VERSION = '1.0.1';
19
    const ITEM_PER_PAGE = 10;
20
21
    const TYPE_COMMENT = 'comment';
22
    const TYPE_ANSWER = 'answer';
23
24
    public $type = 'widget';
25
26
    // heavy actions import
27
    use Comments\ActionIndex {
0 ignored issues
show
Bug introduced by
The trait Apps\Controller\Admin\Comments\ActionIndex requires the property $query which is not provided by Apps\Controller\Admin\Comments.
Loading history...
28
        index as actionIndex;
29
    }
30
31
    use Comments\ActionEdit {
32
        edit as actionEdit;
33
    }
34
35
    use Comments\ActionDelete {
0 ignored issues
show
Bug introduced by
The trait Apps\Controller\Admin\Comments\ActionDelete requires the property $query which is not provided by Apps\Controller\Admin\Comments.
Loading history...
36
        delete as actionDelete;
37
    }
38
39
    use Comments\ActionPublish {
0 ignored issues
show
Bug introduced by
The trait Apps\Controller\Admin\Comments\ActionPublish requires the property $query which is not provided by Apps\Controller\Admin\Comments.
Loading history...
40
        publish as actionPublish;
41
    }
42
43
    use Comments\ActionAnswerList {
0 ignored issues
show
Bug introduced by
The trait Apps\Controller\Admin\Comments\ActionAnswerList requires the property $query which is not provided by Apps\Controller\Admin\Comments.
Loading history...
44
        answerList as actionAnswerlist;
45
    }
46
47
    use Comments\ActionRead {
48
        read as actionRead;
49
    }
50
51
    use Comments\ActionDisplay {
52
        display as actionDisplay;
53
    }
54
55
    use Comments\ActionSettings {
56
        settings as actionSettings;
57
    }
58
}
59