Last active
June 20, 2016 02:47
-
-
Save prapats/0862ad66b3aadc3cd434f197a4097650 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class EducationDetail extends Model{ | |
fatherEducationLevel{ | |
return $this->belongsToOne('EducationLevel'); | |
} | |
motherEducationLevel{ | |
return $this->belongsToOne('EducationLevel'); | |
} | |
sisterEducationLevel{ | |
return $this->belongsToOne('EducationLevel'); | |
} | |
} | |
class EducationLevel extends Model{ | |
public $table = 'education_levels'; | |
// | |
public function educationDetails(){ | |
return $this->hasMany('EducationLevel'); | |
} | |
// ???? | |
public function educationDetails(){ | |
return $this->hasMany('EducationLevel'); | |
} | |
// ???? | |
public function educationDetails(){ | |
return $this->hasMany('EducationLevel'); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I think, just one func
educationDetailsOfApplication
below is enough