Documentation
¶
Overview ¶
Copyright 2019-2020 Axetroy. All rights reserved. MIT license.
Copyright 2019-2020 Axetroy. All rights reserved. MIT license.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Notifier ¶
type Notifier interface {
SendNotifyToAllUser(headings string, content string) error // 向所有用户推送
SendNotifyToCustomUser(userIds []string, headings string, content string) error // 推送自定义通知
//SendNotifySystemMessageToUser(userIds []string, title string, content string) error // 推送系统通知
//SendNotifyUserMessageToUser(userIds []string, title string, content string) error // 推送用户消息
SendNotifyToLoginAbnormalUser(userInfo schema.ProfilePublic) error // 推送用户登录异常
}
var Notify *Notifier
type NotifierOneSignal ¶
type NotifierOneSignal struct {
}
func NewNotifierOneSignal ¶
func NewNotifierOneSignal() *NotifierOneSignal
func (*NotifierOneSignal) SendNotifyToAllUser ¶
func (n *NotifierOneSignal) SendNotifyToAllUser(headings string, content string) error
func (*NotifierOneSignal) SendNotifyToCustomUser ¶
func (n *NotifierOneSignal) SendNotifyToCustomUser(userId []string, headings string, content string) error
func (*NotifierOneSignal) SendNotifyToLoginAbnormalUser ¶
func (n *NotifierOneSignal) SendNotifyToLoginAbnormalUser(userInfo schema.ProfilePublic) error
type SendNotifyEvent ¶
type SendNotifyEvent string
const ( SendNotifyEventSendNotifyToAllUser SendNotifyEvent = "SendNotifyToAllUser" SendNotifyEventSendNotifyToCustomUser SendNotifyEvent = "SendNotifyToCustomUser" SendNotifyEventSendNotifyToLoginAbnormalUser SendNotifyEvent = "SendNotifyToLoginAbnormalUser" )
Click to show internal directories.
Click to hide internal directories.