diff --git a/docs/reference/installation.rst b/docs/reference/installation.rst index f43353c4c..f318a65a8 100644 --- a/docs/reference/installation.rst +++ b/docs/reference/installation.rst @@ -82,6 +82,7 @@ And then create the corresponding entity, ``src/Entity/SonataUserUser``:: use Doctrine\DBAL\Types\Types; use Doctrine\ORM\Mapping as ORM; use Sonata\UserBundle\Entity\BaseUser; + // or `Sonata\UserBundle\Entity\BaseUser3` as BaseUser if you upgrade to doctrine/orm ^3 #[ORM\Entity] #[ORM\Table(name: 'user__user')] diff --git a/src/Entity/BaseUser3.php b/src/Entity/BaseUser3.php new file mode 100644 index 000000000..042350969 --- /dev/null +++ b/src/Entity/BaseUser3.php @@ -0,0 +1,18 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +namespace Sonata\UserBundle\Entity; + +class BaseUser3 extends BaseUser +{ +} diff --git a/src/Resources/config/doctrine/BaseUser.orm.xml b/src/Resources/config/doctrine/BaseUser.orm.xml index 11d5ec41f..92ae3d230 100644 --- a/src/Resources/config/doctrine/BaseUser.orm.xml +++ b/src/Resources/config/doctrine/BaseUser.orm.xml @@ -11,7 +11,7 @@ - + diff --git a/src/Resources/config/doctrine/BaseUser.orm3.xml b/src/Resources/config/doctrine/BaseUser.orm3.xml new file mode 100644 index 000000000..6ebf323c6 --- /dev/null +++ b/src/Resources/config/doctrine/BaseUser.orm3.xml @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + + + + +