Total Complexity | 3 |
Total Lines | 37 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
8 | class Tag extends Model |
||
9 | { |
||
10 | use SoftDeletes; |
||
11 | |||
12 | protected $table = 'tags'; |
||
13 | |||
14 | protected $fillable = [ |
||
15 | 'id', |
||
16 | 'en', |
||
17 | 'de', |
||
18 | ]; |
||
19 | |||
20 | /** |
||
21 | * Get all of the characters that are assigned this tag. |
||
22 | */ |
||
23 | public function characters() |
||
24 | { |
||
25 | return $this->morphedByMany(Character::class, 'taggable') |
||
26 | ->using(Taggable::class); |
||
27 | } |
||
28 | |||
29 | /** |
||
30 | * Get all of the locations that are assigned this tag. |
||
31 | */ |
||
32 | public function locations() |
||
36 | } |
||
37 | |||
38 | /** |
||
39 | * Get all of the locations that are assigned this tag. |
||
40 | */ |
||
41 | public function houses() |
||
45 | } |
||
46 | } |
||
47 |