Moodle APIs 3.9
Moodle 3.9.13+ (Build: 20220325)
Static Public Member Functions | List of all members
message_popup\api Class Reference

Class used to return information to display for the message popup. More...

Static Public Member Functions

static count_unread_popup_notifications ($useridto=0)
 Count the unread notifications for a user. More...
 
static get_popup_notifications ($useridto=0, $sort='DESC', $limit=0, $offset=0)
 Get popup notifications for the specified users. More...
 

Detailed Description

Class used to return information to display for the message popup.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Member Function Documentation

◆ count_unread_popup_notifications()

static message_popup\api::count_unread_popup_notifications (   $useridto = 0)
static

Count the unread notifications for a user.

Parameters
int$useridtothe user id who received the notification
Return values
intcount of the unread notifications
Since
3.2

◆ get_popup_notifications()

static message_popup\api::get_popup_notifications (   $useridto = 0,
  $sort = 'DESC',
  $limit = 0,
  $offset = 0 
)
static

Get popup notifications for the specified users.

Nothing is returned if notifications are disabled.

Parameters
int$useridtothe user id who received the notification
string$sortthe column name to order by including optionally direction
int$limitlimit the number of result returned
int$offsetoffset the result set by this amount
Return values
arraynotification records
Exceptions
moodle_exception
Since
3.2

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