Git Product home page Git Product logo

Comments (3)

easternmayurt avatar easternmayurt commented on June 27, 2024

Screenshot from 2019-12-10 20-14-34
Now I got this error, can anyone of you please help me.
I have changed in the Entity added

@Notifiable(name="user")

bind notification bundle inside services.yaml

bind:
            Mgilet\NotificationBundle\Manager\NotificationManager : "@mgilet.notification"
mgilet.twig_extension:
        class: Mgilet\NotificationBundle\Twig\NotificationExtension
        arguments: ['@mgilet.notification', '@security.token_storage', '@twig', '@router']

Inside controller added following below-mentioned function

public function sendNotification(\Mgilet\NotificationBundle\Manager\NotificationManager $manager)
    {
        $notif = $manager->createNotification('New Test');
        $notif->setMessage('Test');
        $notif->setLink('http://symfony.com/');
        $manager->addNotification([$this->getUser()], $notif, true);

        return $this->redirectToRoute('currencies');
    }

What else is missing here ?

from notification-bundle.

emulienfou avatar emulienfou commented on June 27, 2024

HI @easternmayurt this bundle is not yet compatible with SF4.4, it still use deprecated classes like Twig_SimpleFunction.
If you want to use it with SF4.4 you will have to upgrade the TwigExtension class and probably other classes.
Pull Request is welcomed

from notification-bundle.

easternmayurt avatar easternmayurt commented on June 27, 2024

Thanks for the reply @emulienfou, I will trying to fix it if you can help me out, where I need to maily, because as I am new with the SF so its a bit time taken process to check everything and upgrade. I appreciate if you just let me know what are the main libraries which I need to upgrade.

from notification-bundle.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.