Passed
Pull Request — master (#343)
by
unknown
04:45
created

ProblemModel   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 11
Duplicated Lines 0 %

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A submissions() 0 3 1
1
<?php
2
3
namespace App\Models\Eloquent;
4
5
use Illuminate\Database\Eloquent\Model;
6
use Illuminate\Support\Facades\DB;
7
8
class ProblemModel extends Model
9
{
10
    protected $table='problem';
11
    protected $primaryKey='pid';
12
    const DELETED_AT=null;
13
    const UPDATED_AT="update_date";
14
    const CREATED_AT=null;
15
16
    public function submissions()
17
    {
18
        return $this->hasMany('App\Models\Eloquent\SubmissionModel','pid','pid');
19
    }
20
}
21