Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Notify Task Bundle Laravel Package

creavo/notify-task-bundle

View on GitHub
Deep Wiki
Context7

CREAVO TaskNotifyBundle

SensioLabsInsight Packagist

Installation

composer require creavo/notify-task-bundle

Add the bundle to your app/AppKernel.php with

class AppKernel extends Kernel
{
    public function registerBundles()
    {
        $bundles = [
            [...],
            new Creavo\NotifyTaskBundle\CreavoNotifyTaskBundle(),
        ];
        
        return $bundles;
    }
    
    [...]
}

register routing in routing.yml:

notify_task:
    resource: '@CreavoNotifyTaskBundle/Resources/config/routing.xml'
    prefix: /task-notify

Update the doctrine-schema - use

php bin/console doctrine:schema:update

or do a migration:

php bin/console doctrine:migration:diff
php bin/console doctrine:migration:migrate

configuration

add to your config.yml and adjust to your wishes:

creavo_notify_task:
    send_notification_immediately: true
    pushover_enabled: false
    pushover_api_token: YOUR_PUSHOVER_APP_TOKEN
    email_enabled: false
    email_from: symfony@localhost
    email_subject: new notification

usage

create notification:

// create notification
$notification=$this->get('creavo_notify_task.notification')->create($user, 'this is the message', 'optional title', $relatedEntity);

// maybe modify notification further
$notification->setLinkTitle('Test');

// save it
$this->get('creavo_notify_task.notification')->save($nofitication);

// you can also save it with $em directly, but this will not trigger pushover or email-notification
$em->persist($notification);
$em->flush();

todo

  • create only one unread notification - system must check, if it already exists and maybe reject the second notification
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
elmogy/larafast
xeviant/laravel-paystack
gorilladash/laravel-website-sdk
martialbe/flysystem-oss
chondal/3312client
jeroen-g/flickr
opscale-co/nova-genbi
itsjustvita/laravel-retention
tequilarapido/trackit
gregsphotography/site-builder-filament
cabaoctavio/laravel-query-log
gregsphotography/site-builder-components
io-digital/clickatell
snowsoft/laravel-admin
oxygen/auth
relicsoftware/barakah-payment-gateway
tobya/work-with-composer
equipc/laravel-email-validator
equipc/laravel-email-database-log
adedsec/nova-translated-labels