This Bundle allows the creation of activities based on Entity-Audits. It also displays the activity in SonataAdmin.
Required:
- SimpleThingsEntityAuditBundle
- DoctrineORM
Optional:
- SonataAdminBundle
For SimpleThingsEntityAuditBundle < 1.0.6
install the the bundle using composer:
composer require braune-digital/activity-bundle "~1.2"
For SimpleThingsEntityAuditBundle >= 1.0.6
install the the bundle with:
composer require braune-digital/activity-bundle "~1.3"
And enable the Bundle in your AppKernel:
public function registerBundles()
{
$bundles = array(
...
new SimpleThings\EntityAudit\SimpleThingsEntityAuditBundle(),
new BrauneDigital\ActivityBundle\BrauneDigitalActivityBundle(),
...
);
braune_digital_activity:
doctrine_subscribing: true #enable the direct creation of activities
observed_classes: #array of classes that need to be watched
'AppBundle\Entity\TimedTask': #classname
fields: #watched fields
created: ~
title: ~
modified: ~
'Application\Ekas\AppBundle\Entity\Step': ~ # watch creation / deletion only
'AppBundle\Entity\TimedTask':
fields:
done: ~
title: ~
description: ~
Resolve UserInterface:
doctrine:
orm:
resolve_target_entities:
BrauneDigital\ActivityBundle\Model\UserInterface: Application\AppBundle\Entity\User
Add Doctrine Relations to your User
oneToMany:
activities:
targetEntity: 'BrauneDigital\ActivityBundle\Entity\Stream\Activity'
mappedBy: user
cascade: ["persist", "remove"]
php app/console braunedigital:activity:buildstream
- Add Usage-Section in Readme