Very poor solution:
$arr = array();
foreach($this->get(array('team2')) as $t) {
$arr[] += $t->getAttributeValue('team2');
}
return $this->hasMany('Team', 'id', 'team1')->orWhereIn('teams.id', $arr);
eloquent relations return Relation type object. They are specific things.
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community