Elgg  Version 6.3
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
Elgg\Notifications\Handlers\AdminValidation Class Reference

Send a notification to all (subscribed) site admins that there are unvalidated users. More...

Inheritance diagram for Elgg\Notifications\Handlers\AdminValidation:
Elgg\Notifications\NonConfigurableNotificationEventHandler Elgg\Notifications\NotificationEventHandler

Public Member Functions

 getSubscriptions ()
 {Returns subscriptions for the event.
Returns
array
} More...
 
- Public Member Functions inherited from Elgg\Notifications\NotificationEventHandler
 __construct (protected NotificationEvent $event, protected NotificationsService $service, array $params=[])
 Constructor. More...
 
 send ()
 Process the event. More...
 
 getMethods ()
 Returns methods to be used for this notification. More...
 

Protected Member Functions

 getNotificationSubject (\ElggUser $recipient, string $method)
 {Get subject for the notification.Plugins can define a subtype specific subject simply by providing a translation for the string "notification:<action>:<type>:<subtype>:subject".
Parameters
\ElggUser$recipientNotification recipient
string$methodMethod
Returns
string Notification subject in the recipient's language
} More...
 
 getNotificationSummary (\ElggUser $recipient, string $method)
 {Return the summary for a notification.
Parameters
\ElggUser$recipientNotification recipient
string$methodMethod
Returns
string
} More...
 
 getNotificationBody (\ElggUser $recipient, string $method)
 {Get body for the notification.Plugin can define a subtype specific body simply by providing a translation for the string "notification:<action>:<type>:<subtype>:body".The arguments passed into the translation are:

  1. Recipient's name
  2. Name of the user who triggered the notification
  3. Title of the content
  4. Name of the content's container
  5. The actual content (entity's 'description' field)
  6. URL to the content
Argument swapping can be used to change the order of the parameters. See http://php.net/manual/en/function.sprintf.php#example-5427
Parameters
\ElggUser$recipientNotification recipient
string$methodMethod
Returns
string Notification body in the recipient's language
} More...
 
 getNotificationURL (\ElggUser $recipient, string $method)
 {Returns the url related to this notification.
Parameters
\ElggUser$recipientNotification recipient
string$methodMethod
Returns
string
} More...
 
- Protected Member Functions inherited from Elgg\Notifications\NotificationEventHandler
 setMethodsOverride (array $methods)
 Override the default user preferred delivery methods with the given methods. More...
 
 getMethodsOverride ()
 Get the delivery methods override. More...
 
 getNotificationMethods ()
 Get the notification methods to use. More...
 
 prepareSubscriptions ()
 Returns subscriptions. More...
 
 filterMutedSubscriptions ()
 Should muted subscribers be filtered. More...
 
 getNotificationSubsciptionExclusionGUIDs ()
 Get an array of GUIDs to not get the subscription records for. More...
 
 excludeOwnerSubscribers ()
 Exclude the NotificationEvent object owner_guid when fetching the subscription records for this notification. More...
 
 excludeContainerSubscribers ()
 Exclude the NotificationEvent object container_guid when fetching the subscription records for this notification. More...
 
 excludeEntitySubscribers ()
 Exclude the NotificationEvent object guid when fetching the subscription records for this notification. More...
 
 sendNotifications (array $subscriptions, array $params=[])
 Sends the notifications based on subscriptions. More...
 
 sendNotification (\ElggEntity $recipient, string $method, array $params=[])
 Send a notification to a subscriber. More...
 
 deliverNotification (Notification $notification, string $method)
 Deliver a notification. More...
 
 prepareNotification (array $params)
 Prepares a notification for delivery. More...
 
 getNotificationAttachments (\ElggUser $recipient, string $method)
 Get the attachments for this notification. More...
 
 getEventActor ()
 Get the acting user from the notification event. More...
 
 getEventEntity ()
 Get the entity from the notification event. More...
 
 addMuteLink ()
 Add a mute link in the email notification. More...
 
 getParam (string $param, mixed $default=null)
 Get a parameter from the notification parameters. More...
 

Protected Attributes

int $unvalidated_count = 0
 
- Protected Attributes inherited from Elgg\Notifications\NotificationEventHandler
array $params = []
 
array $methods_override = []
 

Additional Inherited Members

- Static Public Member Functions inherited from Elgg\Notifications\NonConfigurableNotificationEventHandler
static isConfigurableByUser ()
 {Is this event configurable by the user on the notification settings page.
Returns
bool
} More...
 
- Static Public Member Functions inherited from Elgg\Notifications\NotificationEventHandler
static isConfigurableForEntity (\ElggEntity $entity)
 Can this event be configured for a specific entity. More...
 
- Static Protected Member Functions inherited from Elgg\Notifications\NonConfigurableNotificationEventHandler
static isConfigurableForUser (\ElggUser $user)
 {Can this event be configured for a specific user.
Parameters
\ElggUser$userthe user to check for
Returns
bool
Since
4.1
} More...
 
static isConfigurableForGroup (\ElggGroup $group)
 {Can this event be configured for a specific group.For example this can be based on a group tools option which is enabled or not
Parameters
\ElggGroup$groupthe group to check for
Returns
bool
Since
4.1
} More...
 

Detailed Description

Send a notification to all (subscribed) site admins that there are unvalidated users.

Since
6.3

Definition at line 12 of file AdminValidation.php.

Member Function Documentation

◆ getNotificationBody()

Elgg\Notifications\Handlers\AdminValidation::getNotificationBody ( \ElggUser  $recipient,
string  $method 
)
protected

{Get body for the notification.Plugin can define a subtype specific body simply by providing a translation for the string "notification:<action>:<type>:<subtype>:body".The arguments passed into the translation are:

  1. Recipient's name
  2. Name of the user who triggered the notification
  3. Title of the content
  4. Name of the content's container
  5. The actual content (entity's 'description' field)
  6. URL to the content
Argument swapping can be used to change the order of the parameters. See http://php.net/manual/en/function.sprintf.php#example-5427
Parameters
\ElggUser$recipientNotification recipient
string$methodMethod
Returns
string Notification body in the recipient's language
}

Reimplemented from Elgg\Notifications\NotificationEventHandler.

Definition at line 72 of file AdminValidation.php.

◆ getNotificationSubject()

Elgg\Notifications\Handlers\AdminValidation::getNotificationSubject ( \ElggUser  $recipient,
string  $method 
)
protected

{Get subject for the notification.Plugins can define a subtype specific subject simply by providing a translation for the string "notification:<action>:<type>:<subtype>:subject".

Parameters
\ElggUser$recipientNotification recipient
string$methodMethod
Returns
string Notification subject in the recipient's language
}

Reimplemented from Elgg\Notifications\NotificationEventHandler.

Definition at line 54 of file AdminValidation.php.

◆ getNotificationSummary()

Elgg\Notifications\Handlers\AdminValidation::getNotificationSummary ( \ElggUser  $recipient,
string  $method 
)
protected

{Return the summary for a notification.

Parameters
\ElggUser$recipientNotification recipient
string$methodMethod
Returns
string
}

Reimplemented from Elgg\Notifications\NotificationEventHandler.

Definition at line 63 of file AdminValidation.php.

◆ getNotificationURL()

Elgg\Notifications\Handlers\AdminValidation::getNotificationURL ( \ElggUser  $recipient,
string  $method 
)
protected

{Returns the url related to this notification.

Parameters
\ElggUser$recipientNotification recipient
string$methodMethod
Returns
string
}

Reimplemented from Elgg\Notifications\NotificationEventHandler.

Definition at line 87 of file AdminValidation.php.

◆ getSubscriptions()

Elgg\Notifications\Handlers\AdminValidation::getSubscriptions ( )

{Returns subscriptions for the event.

Returns
array
}

Reimplemented from Elgg\Notifications\NotificationEventHandler.

Definition at line 19 of file AdminValidation.php.

Member Data Documentation

◆ $unvalidated_count

int Elgg\Notifications\Handlers\AdminValidation::$unvalidated_count = 0
protected

Definition at line 14 of file AdminValidation.php.


The documentation for this class was generated from the following file: