To override the notification entity (eg to add fields), you just have to create a new entity like this :
<?php
namespace App\Entity;
use Doctrine\ORM\Mapping as ORM;
use Mgilet\NotificationBundle\Entity\NotificationInterface;
use Mgilet\NotificationBundle\Model\Notification as NotificationModel;
/**
* Class Notification
* @ORM\Entity
*
* @package Acme\Entity
*/
class Notification extends NotificationModel implements NotificationInterface
{
}
Next, the only other step is to configure the bundle to use your new entity :
config/packages/mgilet_notification.yaml
mgilet_notification:
notification_class: App\Entity\MyCustomNotification
If you like my bundle and/or want to :
- Suggest something
- Report a problem
- Improve something
- Add translation(s)
Just go to the project's Github. :)
Most important thing : if you like it share it !
A huge thanks to the Symfony community and all amazing free piece of software.
And thank you for using this.