Completed
Pull Request — dev (#317)
by Tristan
06:21
created

MicroReference::experience_level()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 2
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
eloc 1
dl 0
loc 2
ccs 0
cts 2
cp 0
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
crap 2
1
<?php
2
3
/**
4
 * Created by Reliese Model.
5
 * Date: Thu, 12 Jul 2018 22:39:27 +0000.
6
 */
0 ignored issues
show
Coding Style introduced by
Missing @link tag in file comment
Loading history...
Coding Style introduced by
Missing @category tag in file comment
Loading history...
Coding Style introduced by
Missing @author tag in file comment
Loading history...
Coding Style introduced by
PHP version not specified
Loading history...
Coding Style introduced by
Missing @package tag in file comment
Loading history...
Coding Style introduced by
Missing @license tag in file comment
Loading history...
7
8
namespace App\Models;
9
10
/**
11
 * Class MicroReference
12
 *
13
 * @property int $id
14
 * @property string $name
15
 * @property string $email
16
 * @property int $relationship_id
17
 * @property string $description
18
 * @property \Jenssegers\Date\Date $created_at
19
 * @property \Jenssegers\Date\Date $updated_at
20
 *
21
 * @property \App\Models\Lookup\Relationship $relationship
22
 * @property \Illuminate\Database\Eloquent\Collection $projects
23
 * @property \Illuminate\Database\Eloquent\Collection $application_micro_references
24
 */
0 ignored issues
show
Coding Style introduced by
Missing @category tag in class comment
Loading history...
Coding Style introduced by
Missing @package tag in class comment
Loading history...
Coding Style introduced by
Missing @author tag in class comment
Loading history...
Coding Style introduced by
Missing @license tag in class comment
Loading history...
Coding Style introduced by
Missing @link tag in class comment
Loading history...
25
class MicroReference extends BaseModel {
0 ignored issues
show
Coding Style introduced by
Opening brace of a class must be on the line after the definition
Loading history...
26
27
    protected $casts = [
28
        'relationship_id' => 'int',
29
        'experience_level_id' => 'int'
30
    ];
31
    protected $fillable = [
32
        'name',
33
        'email',
34
        'relationship_id',
35
        'description'
36
    ];
37
38
    public function relationship() {
0 ignored issues
show
Coding Style introduced by
Missing doc comment for function relationship()
Loading history...
39
        return $this->belongsTo(\App\Models\Lookup\Relationship::class);
40
    }
41
42
    public function projects() {
0 ignored issues
show
Coding Style introduced by
Missing doc comment for function projects()
Loading history...
43
        return $this->belongsToMany(\App\Models\Project::class);
44
    }
45
    
46
    public function application_micro_references() {
0 ignored issues
show
Coding Style introduced by
Missing doc comment for function application_micro_references()
Loading history...
Coding Style introduced by
Public method name "MicroReference::application_micro_references" is not in camel caps format
Loading history...
47
        return $this->hasMany(\App\Models\ApplicationMicroReference::class);
48
    }
49
50
}
51