Download the PHP package shippinno/notification without Composer
On this page you can find all versions of the php package shippinno/notification. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Informations about the package notification
Notification
Installation
Basic Usage
Create and send a notification
Create a Notification with a Destination and send it through a Gateway.
Gateway has to be compatible with the Destination (check Destination::sendsToDestination(Destination $destination)). In the case above, we assume EmailGateway accepts notifications with EmailDestination.
Persist notifications
Use NotificationRepository to persist notifications on your database.
If you use DoctrineNotificationRepository and set $isPrecocious attribute to true, you do not have to do EntityManager::flush().
You can retrieve fresh (not sent or failed) notifications to send them.
Working with persisted notifications, you should want to mark them as sent or failed after trying to send.
If your DoctrineNotificationRepository is precocious, calling persist() will flush immediately.
Advanced usage
Using templates
Let’s say you have Liquid templates like:
Then you can create notifications using those templates with TemplateNotificationFactory.
Check out shippinno/template for more details how the template things work.
Gateway routing
SendNotification service routes a notification to and send it through a gateway designated on GatewayRegistry.
All versions of notification with dependencies
ext-json Version *
adbario/php-dot-notation Version ^2.1
alek13/slack Version ^2.2
doctrine/orm Version ^2.5
mathiasverraes/classfunctions Version ^1.1
shippinno/email Version ^1.0.0
shippinno/template Version ^1.0
symfony/cache Version ^6.3
tanigami/doctrine-json-unescaped-type Version ^1.0
tanigami/specification Version ^1.3
tanigami/value-objects Version ^0.4.6


