Total Complexity | 11 |
Total Lines | 41 |
Duplicated Lines | 0 % |
Changes | 1 | ||
Bugs | 0 | Features | 1 |
1 | <?php |
||
8 | class Dojo extends Model |
||
9 | { |
||
10 | use SoftDeletes; |
||
11 | |||
12 | public function phase() |
||
13 | { |
||
14 | return $this->belongsTo('App\Models\Eloquent\Dojo\DojoPhase', 'dojo_phase_id'); |
||
15 | } |
||
16 | |||
17 | public function problems() |
||
18 | { |
||
19 | return $this->hasMany('App\Models\Eloquent\Dojo\DojoProblem', 'dojo_id'); |
||
20 | } |
||
21 | |||
22 | public function passes() |
||
25 | } |
||
26 | |||
27 | public function canPass() |
||
35 | } |
||
36 | |||
37 | public function getPassedAttribute() |
||
38 | { |
||
39 | return DojoPass::isPassed($this->id); |
||
40 | } |
||
41 | |||
42 | public function getAvailabilityAttribute() |
||
49 | } |
||
50 | |||
51 | } |
||
52 |
Checks if undeclared accessed properties appear in database migrations and if the creating migration is correct.