DatabaseNotificationService
Last updated
Last updated
Returns all database notifications for a Notifiable.
Name | Type | Required | Default | Description |
---|---|---|---|---|
Return: A DatabaseNotificationCursor
to interact with a paginated list of notifications for the notifiable.
Throws: Megaphone.Configuration.MissingChannel
Throws: Megaphone.Configuration.InvalidChannelProvider
Returns all read database notifications for a Notifiable.
Name | Type | Required | Default | Description |
---|---|---|---|---|
Return: A DatabaseNotificationCursor
to interact with a paginated list of read notifications for the notifiable.
Throws: Megaphone.Configuration.MissingChannel
Throws: Megaphone.Configuration.InvalidChannelProvider
Returns all unread database notifications for a Notifiable.
Return: A DatabaseNotificationCursor
to interact with a paginated list of unread notifications for the notifiable.
Throws: Megaphone.Configuration.MissingChannel
Throws: Megaphone.Configuration.InvalidChannelProvider
Name | Type | Required | Default | Description |
---|---|---|---|---|
notifiable
true
The INotifiable
instance to retrieve notifications for.
channelName
string
false
database
The name of the channel to retrieve notifications from. Defaults to database
.
initialPage
numeric
false
1
The initial page of the returned DatabaseNotificationCursor
.
maxRows
numeric
false
25
The number of rows per page for the returned DatabaseNotificationCursor
.
notifiable
true
The INotifiable
instance to retrieve read notifications for.
channelName
string
false
database
The name of the channel to retrieve read notifications from. Defaults to database
.
initialPage
numeric
false
1
The initial page of the returned DatabaseNotificationCursor
.
maxRows
numeric
false
25
The number of rows per page for the returned DatabaseNotificationCursor
.
notifiable
true
The INotifiable
instance to retrieve unread notifications for.
channelName
string
false
database
The name of the channel to retrieve unread notifications from. Defaults to database
.
initialPage
numeric
false
1
The initial page of the returned DatabaseNotificationCursor
.
maxRows
numeric
false
25
The number of rows per page for the returned DatabaseNotificationCursor
.