Ouzo\Db\RelationFetcher::_loadRelationObjectsIndexedById PHP Метод

_loadRelationObjectsIndexedById() приватный Метод

private _loadRelationObjectsIndexedById ( $localKeys )
    private function _loadRelationObjectsIndexedById($localKeys)
    {
        $relationObject = $this->_relation->getRelationModelObject();
        $relationObjects = $relationObject::where(array($this->_relation->getForeignKey() => $localKeys))->where($this->_relation->getCondition())->order($this->_relation->getOrder())->fetchAll();
        return Arrays::groupBy($relationObjects, Functions::extractField($this->_relation->getForeignKey()));
    }