Weave Code
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.
besmartand-pro/php-quality-config
sentix/ai-chatbot
codifyo/ts-generator-bundle
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky
spatie/mailcoach-vapor