Activity   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 19
Duplicated Lines 0 %

Importance

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

2 Methods

Rating   Name   Duplication   Size   Complexity  
A candidate() 0 3 1
A user() 0 3 1
1
<?php
2
3
namespace App\Models;
4
5
use Illuminate\Database\Eloquent\Model;
6
7
class Activity extends Model
8
{
9
    protected $connection = 'tenant';
10
11
    /**
12
     * The attributes that are mass assignable.
13
     *
14
     * @var array
15
     */
16
    protected $fillable = ['candidate_id', 'user_id', 'type', 'prev_value', 'new_value'];
17
18
    public function candidate()
19
    {
20
        return $this->belongsTo(Candidate::class);
21
    }
22
23
    public function user()
24
    {
25
        return $this->belongsTo(User::class)->withTrashed();
26
    }
27
}
28