Ward   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 20
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 5
c 1
b 0
f 0
dl 0
loc 20
rs 10
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A compilations() 0 3 1
1
<?php
2
declare(strict_types = 1);
3
4
namespace App\Models;
5
6
use App\Models\Interfaces\Importable;
7
use App\Models\Traits\EloquentGetTableName;
8
use Illuminate\Database\Eloquent\Model;
9
use Illuminate\Database\Eloquent\Relations\HasMany;
10
use Illuminate\Database\Eloquent\SoftDeletes;
11
12
class Ward extends Model implements Importable
13
{
14
15
    use SoftDeletes;
16
    use EloquentGetTableName;
17
18
    /**
19
     * The attributes that should be mutated to dates.
20
     *
21
     * @var array
22
     */
23
    protected $dates = ["deleted_at"];
24
25
    /**
26
     * Get the compilations of this student
27
     * @return HasMany
28
     */
29
    public function compilations() : HasMany
30
    {
31
        return $this->hasMany("App\Models\Compilation", "stage_ward_id");
32
    }
33
34
}
35