fcm ios push badge

This commit is contained in:
Gordon
2022-09-02 16:36:47 +08:00
parent 3f87958328
commit 72aff32024
7 changed files with 101 additions and 61 deletions
-8
View File
@@ -75,14 +75,6 @@ func (rpc *rpcConversation) ModifyConversationField(c context.Context, req *pbCo
case constant.FieldUnread:
isSyncConversation = false
err = imdb.UpdateColumnsConversations(haveUserID, req.Conversation.ConversationID, map[string]interface{}{"update_unread_count_time": conversation.UpdateUnreadCountTime})
for _, v := range req.UserIDList {
if err = db.DB.SetUserBadgeUnreadCountSum(v, int(req.BadgeUnreadCountSum)); err != nil {
log.NewError(req.OperationID, utils.GetSelfFuncName(), "SetUserBadgeUnreadCountSum, rpc return", err.Error())
resp.CommonResp = &pbConversation.CommonResp{ErrCode: constant.ErrDB.ErrCode, ErrMsg: err.Error()}
return resp, nil
}
}
}
if err != nil {
log.NewError(req.OperationID, utils.GetSelfFuncName(), "UpdateColumnsConversations error", err.Error())