mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-04-06 04:15:46 +08:00
fcm ios push badge
This commit is contained in:
parent
72aff32024
commit
f6137dfc34
@ -90,6 +90,7 @@ func (f *Fcm) Push(accounts []string, title, detailContent, operationID string,
|
||||
}
|
||||
for _, token := range personTokens {
|
||||
temp := &messaging.Message{
|
||||
Data: map[string]string{"ex": opts.Data},
|
||||
Token: token,
|
||||
Notification: notification,
|
||||
APNS: apns,
|
||||
|
@ -300,6 +300,7 @@ func GetOfflinePushOpts(pushMsg *pbPush.PushMsgReq) (opts push.PushOpts, err err
|
||||
if pushMsg.MsgData.OfflinePushInfo != nil {
|
||||
opts.IOSBadgeCount = pushMsg.MsgData.OfflinePushInfo.IOSBadgeCount
|
||||
opts.IOSPushSound = pushMsg.MsgData.OfflinePushInfo.IOSPushSound
|
||||
opts.Data = pushMsg.MsgData.OfflinePushInfo.Ex
|
||||
}
|
||||
|
||||
return opts, nil
|
||||
|
@ -12,6 +12,7 @@ type PushOpts struct {
|
||||
Signal Signal
|
||||
IOSPushSound string
|
||||
IOSBadgeCount bool
|
||||
Data string
|
||||
}
|
||||
|
||||
type Signal struct {
|
||||
|
Loading…
x
Reference in New Issue
Block a user