ilateral\SilverStripe\Notifier\Types\EmailNotification
Simple wrapper for SilverStripe email notoifications
Synopsis
class EmailNotification
extends NotificationType
{
- // members
- private static string $table_name = "Notifications_EmailNotification";
- private static string $singular_name = 'Email Notification';
- private static string $plural_name = 'Email Notifications';
- private static $template = self::class;
- private static array $db = ;
- private static array $casting = ;
- // Inherited members from NotificationType
- protected DataObject $object;
- protected array $extra_vars;
- // methods
- public string getRenderedSubject()
- public void send()
- // Inherited methods from NotificationType
- public void getType()
- public string getSummary()
- public string getRenderedContent()
- protected array getAltFromFields()
- protected array getAltRecipientFields()
- protected array getRecipients()
- protected string getSender()
- protected void getFieldsFromClass()
- protected array compilePossibleTemplateVars()
- protected string getRenderedTemplateVars()
- public void getCMSFields()
- public ValidationResult validate()
- public void send()
- public DataObject getObject()
- public NotificationType setObject()
- protected string renderString()
- public array getExtraVars()
- public NotificationType setExtraVars()
- public NotificationType addExtraVar()
- public NotificationType removeExtraVar()
Hierarchy
Members
private
- $casting
- $db
- $plural_name
- $singular_name
- $table_name
- $template
protected
- $extra_vars
—
array
Extra vars to be used when rendering - $object
—
SilverStripe\ORM\DataObject
The current object instance that is notifying
Methods
public
- getRenderedSubject() — Return a rendered version of this notification's subject using the current object as a base
- send()
Inherited from ilateral\SilverStripe\Notifier\Types\NotificationType
protected
- compilePossibleTemplateVars() — Attempt to generate a list possible template variables that can be used in the subject and content fields.
- getAltFromFields() — Get a list of possible alternate fields that can be used for the from address
- getAltRecipientFields() — Get a list of possible alternate fields that can be used for the recipient address
- getFieldsFromClass()
- getRecipients() — Get a list of recipients to recieve this notification.
- getRenderedTemplateVars() — Generate a string of possible template vars
- getSender() — Try and find the correct default sender
- renderString() — Take the passed string and render it using SSViewer
public
- addExtraVar() — Add a variable to be used when rendering
- getCMSFields()
- getExtraVars() — Get extra vars to be used when rendering
- getObject() — Get the current object instance that is notifying
- getRenderedContent() — Return a rendered version of this notification's content using the current object as a base
- getSummary() — Attempt to generate a summary of this rule
- getType()
- removeExtraVar() — Remove a variable to be used when rendering
- send()
- setExtraVars() — Set extra vars to be used when rendering
- setObject() — Set the current object instance that is notifying
- validate() — Ensure that a sender and recipient are set