Test Setup Failed
Push — development ( 84aced...e2681b )
by Tim
05:18
created

Teams   A

Complexity

Total Complexity 2

Size/Duplication

Total Lines 38
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 2
Bugs 1 Features 1
Metric Value
wmc 2
c 2
b 1
f 1
lcom 0
cbo 1
dl 0
loc 38
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A departments() 0 4 1
A employee() 0 4 1
1
<?php
2
3
namespace App;
4
5
use Illuminate\Database\Eloquent\Model;
6
7
class Teams extends Model
8
{
9
    /**
10
     * The database table used by the model.
11
     *
12
     * @var string
13
     */
14
    protected $table = 'teams';
15
16
    /**
17
     * The attributes that are mass assignable.
18
     *
19
     * @var array
20
     */
21
    protected $fillable = ['name', 'manager', 'description'];
22
23
    /**
24
     * Departements relation.
25
     *
26
     * @return \Illuminate\Database\Eloquent\Relations\BelongsToMany
27
     */
28
    public function departments()
29
    {
30
        return $this->belongsToMany('App\Departments');
31
    }
32
33
    /**
34
     * The employees relation.
35
     *
36
     * Get all the employees setted on the teams.
37
     *
38
     * @return \Illuminate\Database\Eloquent\Relations\BelongsTo
39
     */
40
    public function employee()
41
    {
42
43
    }
44
}
45