Laravel one to many relation with a one to one relation

you can use this type of method for one to one or one to many

public function yourmethod(){
    return Modalnamewhereyouwanttoretrive::where('yourcolmn',$this->foreign_key)->get(); 
}

Leave a Comment