-
Notifications
You must be signed in to change notification settings - Fork 3
Configuration
Copy zf-doctrine-audit/config/zf-doctrine-audit.global.php.dist
to your autoload directory and rename by removing the .dist
extension.
These options will exist in that config/autoload/zf-doctrine-audit.global.php
file in the zf-doctrine-audit
section.
target_object_manager
- This is the service manager alias for the object manager you are auditing from.
audit_object_manager
- This is the service manager alias for the object manager for your audit data. This cannot be the same name as target_object_manager
but they may use the same database. See blog.tomhanderson.com for more instructions on setting up a second object manager.
audit_table_name_suffix
- It is strongly recommended you include a suffix for your audit table names if you are using the same database for both target and audit object managers. It is not necessary to use a suffix or prefix if your audit database is independent of your target database.
audit_table_name_prefix
- Only use this if you like typing the same thing over and over when directly querying your database. SSIA.
user_entity_class_name
- The class name of your user entity. This is used to list the name, using getDisplayName()
of the user associated with a revision.
authentication_service
- Usually an instance of Zend\Authentication\AuthenticationService
, this service will be used to find the user id of the user_entity_class_name
entity when a revision is created.
entities
- an associative array of target entities to be audited. Array key names are the complete namespace for the entity and the value is routing information.
If provided as keys to the entities
array a link to the canonical url for the data will be provided by zf-doctrine-audit-view
.
'Db\Entity\Artist' => array(
'route' => 'default',
'defaults' => array(
'controller' => 'artist',
'action' => 'detail',
),
),
This will provide a link using the default route provided by zendframework/skeleton-application.
zf-doctrine-audit © 2016 API Skeletons. Released under the MIT license.