Skip to content

Instantly share code, notes, and snippets.

@mvanduijker
Created November 6, 2015 08:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mvanduijker/4bd7b3a8d7956f01c8c0 to your computer and use it in GitHub Desktop.
Save mvanduijker/4bd7b3a8d7956f01c8c0 to your computer and use it in GitHub Desktop.
Doctrine2 repository as a symfony2 service
services:
orm_repository.your_entity:
class: Doctrine\ORM\EntityRepository
factory_service: doctrine.orm.default_entity_manager
factory_method: getRepository
arguments:
- Acme\Entity\YourEntity
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment