Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Error = errs.Class("notifications console web error")
Error is error type of storagenode web console.
Functions ¶
This section is empty.
Types ¶
type Notifications ¶
type Notifications struct {
// contains filtered or unexported fields
}
Notifications represents notification service. architecture: Service
func NewNotifications ¶
func NewNotifications(log *zap.Logger, service *notifications.Service) *Notifications
NewNotifications creates new instance of notification service.
func (*Notifications) ListNotifications ¶
func (notification *Notifications) ListNotifications(w http.ResponseWriter, r *http.Request)
ListNotifications returns listed page of notifications from database.
func (*Notifications) ReadAllNotifications ¶
func (notification *Notifications) ReadAllNotifications(w http.ResponseWriter, r *http.Request)
ReadAllNotifications updates all notifications in database as read.
func (*Notifications) ReadNotification ¶
func (notification *Notifications) ReadNotification(w http.ResponseWriter, r *http.Request)
ReadNotification updates specific notification in database as read.
type Page ¶ added in v0.34.1
type Page struct { Notifications []notifications.Notification `json:"notifications"` Offset uint64 `json:"offset"` Limit uint `json:"limit"` CurrentPage uint `json:"currentPage"` PageCount uint `json:"pageCount"` }
Page contains notifications and related information.
Click to show internal directories.
Click to hide internal directories.