File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ write mapping information with annotations, XML, or YAML:
108108
109109
.. code-block:: yaml
110110
111-
# Acme/HelloBundle/Resources/config/doctrine/Acme.HelloBundle.Entity.User.orm.dcm.yml
111+
# Acme/HelloBundle/Resources/config/doctrine/Acme.HelloBundle.Entity.User.orm.yml
112112
Acme\HelloBundle\Entity\User:
113113
type: entity
114114
table: user
@@ -124,7 +124,7 @@ write mapping information with annotations, XML, or YAML:
124124
125125
.. code-block:: xml
126126
127-
<!-- Acme/HelloBundle/Resources/config/doctrine/Acme.HelloBundle.Entity.User.orm.dcm.xml -->
127+
<!-- Acme/HelloBundle/Resources/config/doctrine/Acme.HelloBundle.Entity.User.orm.xml -->
128128
<doctrine-mapping xmlns="http://doctrine-project.org/schemas/orm/doctrine-mapping"
129129
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
130130
xsi:schemaLocation="http://doctrine-project.org/schemas/orm/doctrine-mapping
@@ -153,7 +153,7 @@ write mapping information with annotations, XML, or YAML:
153153
.. tip::
154154

155155
Instead of creating one file per entity, you can also define all your
156-
mapping information into a single ``doctrine.orm.dcm.yml`` file.
156+
mapping information into a single ``doctrine.orm.yml`` file.
157157

158158
Create the database and the schema related to your metadata information with
159159
the following commands:
@@ -179,7 +179,7 @@ Eventually, use your entity and manage its persistent state with Doctrine:
179179
$user = new User();
180180
$user->setName('Jonathan H. Wage');
181181
182-
$em = $this->get('registry')->getEntityManager();
182+
$em = $this->get('doctrine')->getEntityManager();
183183
$em->persist($user);
184184
$em->flush();
185185
@@ -188,7 +188,7 @@ Eventually, use your entity and manage its persistent state with Doctrine:
188188
189189
public function editAction($id)
190190
{
191-
$em = $this->get('registry')->getEntityManager();
191+
$em = $this->get('doctrine')->getEntityManager();
192192
$user = $em->find('AcmeHelloBundle:User', $id);
193193
$user->setBody('new body');
194194
$em->persist($user);
@@ -199,7 +199,7 @@ Eventually, use your entity and manage its persistent state with Doctrine:
199199
200200
public function deleteAction($id)
201201
{
202-
$em = $this->get('registry')->getEntityManager();
202+
$em = $this->get('doctrine')->getEntityManager();
203203
$user = $em->find('AcmeHelloBundle:User', $id);
204204
$em->remove($user);
205205
$em->flush();
@@ -325,8 +325,8 @@ follow these conventions:
325325
example ``Acme/HelloBundle/Entity/``.
326326

327327
2. If you are using xml, yml or php mapping put all your configuration files
328-
into the "Resources/config/doctrine/" directory suffixed with ``orm.dcm.xml``,
329-
``orm.dcm.yml`` or ``orm.dcm.php`` respectively.
328+
into the "Resources/config/doctrine/" directory suffixed with ``orm.xml``,
329+
``orm.yml`` or ``orm.php`` respectively.
330330

331331
3. Annotations is assumed if an ``Entity/`` but no
332332
"Resources/config/doctrine/" directory is found.
@@ -387,8 +387,8 @@ Doctrine registry::
387387
{
388388
public function indexAction()
389389
{
390-
$em = $this->get('registry')->getEntityManager();
391-
$customerEm = $this->get('registry')->getEntityManager('customer');
390+
$em = $this->get('doctrine')->getEntityManager();
391+
$customerEm = $this->get('doctrine')->getEntityManager('customer');
392392
}
393393
}
394394

@@ -509,8 +509,8 @@ without any arguments or options:
509509
510510
.. note::
511511

512-
To be able to load data fixtures to your database, you will need to have the
513-
``DoctrineFixturesBundle`` bundle installed. To learn how to do it,
512+
To be able to load data fixtures to your database, you will need to have the
513+
``DoctrineFixturesBundle`` bundle installed. To learn how to do it,
514514
read the ":doc:`/cookbook/doctrine/doctrine_fixtures`" entry of the Cookbook.
515515

516516
Form Integration

0 commit comments

Comments
 (0)