Completed
Push — version-4 ( 5bb021 )
by
unknown
08:16
created

NotificationGroup   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 15
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 5
Bugs 3 Features 1
Metric Value
c 5
b 3
f 1
dl 0
loc 15
rs 10
wmc 1
lcom 0
cbo 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A categories() 0 8 1
1
<?php
2
3
namespace Fenos\Notifynder\Models;
4
5
use Illuminate\Database\Eloquent\Model;
6
7
class NotificationGroup extends Model
8
{
9
    protected $fillable = ['name'];
10
11
    public $timestamps = false;
12
13
    public function categories()
14
    {
15
        return $this->belongsToMany(
16
            NotificationCategory::class,
17
            'notifications_categories_in_groups',
18
            'group_id', 'category_id'
19
        );
20
    }
21
}
22