Total Complexity | 2 |
Total Lines | 53 |
Duplicated Lines | 0 % |
Changes | 0 |
1 | <?php |
||
8 | class Examination_student extends Model |
||
9 | { |
||
10 | |||
11 | |||
12 | /** |
||
13 | * The database table used by the model. |
||
14 | * |
||
15 | * @var string |
||
16 | */ |
||
17 | protected $table = 'examination_students'; |
||
18 | |||
19 | /** |
||
20 | * Attributes that should be mass-assignable. |
||
21 | * |
||
22 | * @var array |
||
23 | */ |
||
24 | protected $fillable = ['st_no', 'stu_no', 'nsid', 'school_id', 'full_name', 'dob', 'gender', 'address', 'annual_income', 'has_special_need', 'disable_type', 'disable_details', 'special_education_centre']; |
||
25 | |||
26 | /** |
||
27 | * The attributes excluded from the model's JSON form. |
||
28 | * |
||
29 | * @var array |
||
30 | */ |
||
31 | protected $hidden = []; |
||
32 | |||
33 | /** |
||
34 | * The attributes that should be casted to native types. |
||
35 | * |
||
36 | * @var array |
||
37 | */ |
||
38 | protected $casts = ['has_special_need' => 'boolean']; |
||
39 | |||
40 | /** |
||
41 | * The attributes that should be mutated to dates. |
||
42 | * |
||
43 | * @var array |
||
44 | */ |
||
45 | protected $dates = ['dob']; |
||
46 | |||
47 | protected $primaryKey = 'st_no'; |
||
48 | |||
49 | public $timestamps = true; |
||
50 | |||
51 | public static function insertData($data) |
||
63 |