Completed
Push — master ( da9adb...96fdd3 )
by
unknown
7s
created

SiswaModel   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 29
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

Changes 0
Metric Value
dl 0
loc 29
rs 10
c 0
b 0
f 0
wmc 1
lcom 0
cbo 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A user() 0 4 1
1
<?php namespace Bantenprov\Siswa\Models;
2
3
use Illuminate\Database\Eloquent\Model;
4
5
/**
6
 * The SiswaModel class.
7
 *
8
 * @package Bantenprov\Siswa
9
 * @author  bantenprov <[email protected]>
10
 */
11
class SiswaModel extends Model
12
{
13
    /**
14
    * Table name.
15
    *
16
    * @var string
17
    */
18
    protected $table = 'siswas';
19
20
    /**
21
    * The attributes that are mass assignable.
22
    *
23
    * @var mixed
24
    */
25
    protected $fillable = ['nomor_un','nik','label','nama_siswa','alamat_kk','tempat_lahir','tgl_lahir','jenis_kelamin','agama','nisn','tahun_lulus','description','user_id'];
26
27
    /**
28
     * The attributes that should be hidden for arrays.
29
     *
30
     * @var array
31
     */
32
    protected $hidden = [];
33
34
        public function user()
35
    {
36
        return $this->belongsTo('App\User','user_id');
37
    }
38
39
}
40