Project

General

Profile

Actions

Feature proposal #7266

open

CBLib: Implement Notification API

Added by krileon about 6 years ago. Updated 3 months ago.

Status:
New
Priority:
Normal
Assignee:
-
Target version:
Start date:
04 September 2018
Due date:
% Done:

0%

Estimated time:

Description

This initially should just be for Emails to replace existing cbNotification API, but should likely support additional types (e.g. PM). Proposed structure as follows.

CBLib\Notification
CBLib\Notification\Email

Usage as follows.

Application::Notification()->send( to, from, subject, message )

Specify type in the constructor (e.g. Application::Notification( 'pm' )).

The problem is PMs are from a plugin while Emails are core. So it needs to be able to call plugin notification types without being dependent on those plugins (e.g. if notification type doesn't exist do nothing). This will likely rely on #5209 existing to call something like Application::PM->send( to, from, subject, message ) when using Application::Notification( 'pm' ).

Actions

Also available in: Atom PDF