Getting started with zfc-user-doctrine-orm
zfc-user-doctrine-orm Is a Zend Framework 2 Module that enables Doctrine 2 support for the ZfcUser module.
Basic Setup
Installation via composer:
composer require "zf-commons/zfc-user-doctrine-orm:0.1.*"
An appropriate version of ZfcUser should be pulled in during installation.
Configuration Setup
-
Copy
vendor/zf-commons/zfcuser.global.php.dist
toconfig/autoload/zfcuser.global.php
-
Edit your application.config.php to include
modules => array(‘ZfcBase’, ‘ZfcUser’, ‘ZfcUserDoctrineORM’)
You don’t have to edit
zfcuser.global.php
– the default values will work fine, and zfc-user-doctrine-orm will inject itself such that you don’t even have to edit the zend_db_adapter (as I initially thought you would).Custom User Entity
If you wish to use a custom user entity definition (too add additional fields, for example).
To do this, modify your
zfcuser.gloabl.php
to include the following configuration values:'zfcuser' => array( 'UserEntityClass' => '\UserEntityNamespace\UserEntityClass', 'EnableDefaultEntities' => false ),
comments powered by Disqus