Versions in this module Expand all Collapse all v0 v0.0.2 Mar 10, 2020 v0.0.1 Mar 8, 2020 Changes in this version + type Action struct + FlashMessage func(actionArgument *ActionArgument, succeed bool, isUndo bool) string + Handler func(actionArgument *ActionArgument) error + Label string + MessageTypes []string + Method string + Name string + Resource *admin.Resource + URL func(data *QorNotification, context *admin.Context) string + Undo func(actionArgument *ActionArgument) error + Visible func(data *QorNotification, context *admin.Context) bool + func (action Action) HasMessageType(t string) bool + func (action Action) ToParam() string + type ActionArgument struct + Argument interface{} + Context *admin.Context + Message *QorNotification + type ChannelInterface interface + GetNotification func(user interface{}, notificationID string, notification *Notification, ...) (*QorNotification, error) + GetNotifications func(user interface{}, results *NotificationsResult, notification *Notification, ...) error + GetUnresolvedNotificationsCount func(user interface{}, notification *Notification, context *qor.Context) uint + Send func(message *Message, context *qor.Context) error + type Config struct + type Message struct + Body string + From interface{} + MessageType string + ResolvedAt *time.Time + Title string + To interface{} + type Notification struct + Actions []*Action + Channels []ChannelInterface + Config *Config + func New(config *Config) *Notification + func (notification *Notification) Action(action *Action) error + func (notification *Notification) ConfigureQorResource(res resource.Resourcer) + func (notification *Notification) GetAction(name string) *Action + func (notification *Notification) GetNotification(user interface{}, messageID string, context *qor.Context) *QorNotification + func (notification *Notification) GetNotifications(user interface{}, context *qor.Context) *NotificationsResult + func (notification *Notification) GetUnresolvedNotificationsCount(user interface{}, context *qor.Context) uint + func (notification *Notification) RegisterChannel(channel ChannelInterface) + func (notification *Notification) Send(message *Message, context *qor.Context) error + type NotificationsResult struct + Notification *Notification + Notifications []*QorNotification + Resolved []*QorNotification + type QorNotification struct + Body string + From string + MessageType string + ResolvedAt *time.Time + Title string + To string + func (qorNotification *QorNotification) Actions(context *admin.Context) (actions []*Action) + func (qorNotification QorNotification) IsResolved() bool