-
Notifications
You must be signed in to change notification settings - Fork 117
Open
Description
EntityToPropertyTransformer.php and EntitiesToPropertyTransformer.php are not compatible with MongoDB DocumentManager.
The following code in EntityToPropertyTransformer.php
$entity = $this->em->createQueryBuilder() ->select('entity') ->from($this->className, 'entity') ->where('entity.'.$this->primaryKey.' = :id') ->setParameter('id', $value) ->getQuery() ->getSingleResult();
has to be changed to
$entity = $this->em->getRepository($this->className)->find($value);
to get it working. Similar issue with EntitiesToPropertyTransformer.php
Metadata
Metadata
Assignees
Labels
No labels