Code Monkey home page Code Monkey logo

notifier's People

Contributors

b1scuit avatar bobmulder avatar brandon1811 avatar dereuromark avatar hillelectric avatar jpkleemans avatar leoruhland avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

notifier's Issues

Add more info to readme

The readme is missing some important information, like an introductory sentence saying something like "This ... helps to ... " to explain to people what this plugin is for, and why they should use it.

Not working on CakePHP 3.4.3 ?

Hello guys,

I'm trying to install the plugin, but i receive the following message after the command "composer require bakkerij/notifier"

Error message:
error

Any ideas ?

Thanks in advance!

Pedro

Add Adapters for modular extending through 3rd parties

Suggestion; implement kind of 'adapters' which are able took hook into notifications. Can be useful to connect to 3rd parties. This idea was brought internally and by #20.

Some ideas of adapters:

  • PusherAdapter
  • SocketIOAdapter
  • GoogleCMAdapter
  • FirebaseAdapter
  • WebhookAdapter
  • SlackAdapter
  • HipchatAdapter

(the idea of adapters can be seen like http://flysystem.thephpleague.com/)

If you want to join the realization of this implementation, feel free to hang into this issue!

Some points of discussion:

  • For sure we need to make use of a base adapter to create new adapters on
  • A cake bake command for adapters would be cute :)
  • Technically, the base adapter should listen to several events
  • What would be a standard Adapter class?

Improve templating

Hi! Thanks for the amazing work.

I have suggestion. Would it be better to handle templates in config files instead?
It would allow an easier integration process.

A config file would allow a few more improvements for he plugin such as
instead of doing this:

`$this->Notifier->allNotificationList(2, true);``

We could use config to set env var (or similar) to do this:

$this->Notifier->allNotificationList(2, __UNREAD__);

What do you think? Tell me if you need a PR on this one.

Install failes

Can not install the plugin:
php composer.phar create-project --prefer-dist cakephp/app cakeadmintestapp
cd cakeadmintestapp
php ../composer.phar require cakeplugins/notifier
bin/cake plugin install -b Notifier

fails: Error: Unknown short option b

If I use the load plugin it works:
bin/cake plugin load Notifier

But the next step fails:
bin/cake migrations migrate Notifier
Exception: Plugin Notifier could not be found. in [/var/www/vhosts/workspace_us/htdocs/cakeadmintestapp/vendor/cakephp/cakephp/src/Core/Plugin.php, line 148]

allNotificationList() is not working

Here is my code -
dump($this->Notifier->allNotificationList($userid, true));

got Error :

Error: Call to undefined method Notifier\Controller\Component\NotifierComponent::allNotificationList()
File /Users/adityagupta/talkadoc/vendor/cakedc/users/src/Controller/UsersController.php
Line: 70

NotificationsController could not be found.

when i install that composer package according the docs rule and then i run it on localhost as localhost/mann/notifications then it gives me error here could not found NotificationsController.
?which type of that issue.please help me

Should we consider this repo abandonned?

As I can see the last commit f913660 was 6 years ago.

If the plugin is no longer being maintained, could you suggest any alternatives or forks? Additionally, if there's a way for the community to assist or take over maintenance, please let us know.

In CakeMojo we are doing some updates (I have had to update it for a Open Source project). I guess that everyone is working in this plugin by yourself in your own fork and you have some ideas to improve this plugin, please don't hesitate to suggest them and collaborate.

How to render notification to view ?

Hello, I am new in CakePHP.

Here is my code -

// bootstrap.php
  `use Notifier\Utility\NotificationManager;
Plugin::load('Migrations');
Plugin::load('Notifier', ['bootstrap' => true, 'routes' => true, 'autoload' => true]);
$notificationManager = new NotificationManager();
$notificationManager->addTemplate('add', [
    'title' => 'New blog by :username',
    'body' => ':username has posted a new blog named :name'
]);`

// BookmarksController.php
`public function index()
    {
        $this->paginate = [
            'contain' => ['Users', 'Tags']
        ];
        $bookmarks = $this->paginate($this->Bookmarks);
        $this->Notifier->notify([
            'users' => [1],
            'template' => 'add',
            'vars' => [
                'username' => 'Aditya',
                'name' => 'My great new blogpost'
            ],
        ]);
public function add() {....}`

I am not seeing any notification.
I don't understand how to use this plugin?
Please describe in details.
Thank You

Create a behavior to send out auto notifications

As you know keeping controllers clean and implementing the data related logic into model level is a better approach for CakePHP in a few different ways.

So, since the notifications are created with templates, I often find myself using variables from my entity just after saving it. For example; I want to notify all users when I add a new record to my posts. So I suggest thinking about something like below:

    $this->addBehavior('bakkerij/notifier.notifier', [
                'template' => 'someTemplateName',
                'keywords' => [
                    'keyword1' => 'columnNameOne',
                    'keyword2' => 'columnNameTwo',
                ],
                'to' => 'recipentListName?'
    ]);

Problem with CakePHP 3.1

Hi !
Thank you for your plugin.

I would like use this plugin on CakePHP 3.1.x and i have this error when trying to get the number of notification :
Error: Call to undefined method Notifier\Utility\NotificationManager::countsNotifications()

I think the NotifierComponent don't load with the plugin.

Thank you for your answer.

(i'm using CakeDC/Users for User system and user_id is not in INT but in CHAR(36))

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.