1 | <?php |
||
10 | class Comment extends Model |
||
11 | { |
||
12 | use CommentApproval, |
||
13 | IsAuthorable; |
||
14 | |||
15 | protected $table = 'comments'; |
||
16 | |||
17 | protected $primaryKey = 'id'; |
||
18 | |||
19 | public $guarded = ['id']; |
||
20 | |||
21 | public $timestamps = true; |
||
22 | |||
23 | protected $casts = [ |
||
24 | 'is_approved' => 'boolean', |
||
25 | ]; |
||
26 | |||
27 | public function commentable() |
||
31 | |||
32 | public function approve() |
||
38 | |||
39 | public function disapprove() |
||
45 | |||
46 | public function newEloquentBuilder($query) : CommentBuilder |
||
50 | } |
||
51 |