Merge remote-tracking branch 'origin/superGroup' into superGroup

This commit is contained in:
wenxu12345
2022-06-23 09:24:20 +08:00
6 changed files with 36 additions and 25 deletions
+11 -7
View File
@@ -553,13 +553,15 @@ func modifyMessageByUserMessageReceiveOptoptimization(userID, sourceID string, s
}
type NotificationMsg struct {
SendID string
RecvID string
Content []byte // open_im_sdk.TipsComm
MsgFrom int32
ContentType int32
SessionType int32
OperationID string
SendID string
RecvID string
Content []byte // open_im_sdk.TipsComm
MsgFrom int32
ContentType int32
SessionType int32
OperationID string
SenderNickname string
SenderFaceURL string
}
func Notification(n *NotificationMsg) {
@@ -579,6 +581,8 @@ func Notification(n *NotificationMsg) {
msg.CreateTime = utils.GetCurrentTimestampByMill()
msg.ClientMsgID = utils.GetMsgID(n.SendID)
msg.Options = make(map[string]bool, 7)
msg.SenderNickname = n.SenderNickname
msg.SenderFaceURL = n.SenderFaceURL
switch n.SessionType {
case constant.GroupChatType, constant.SuperGroupChatType:
msg.RecvID = ""
+1 -1
View File
@@ -284,7 +284,7 @@ func (s *userServer) SetRecvMsgOpt(ctx context.Context, req *pbUser.SetRecvMsgOp
stringList := strings.Split(req.ConversationID, "_")
if len(stringList) > 1 {
switch stringList[0] {
case "single_":
case "single":
conversation.UserID = stringList[1]
conversation.ConversationType = constant.SingleChatType
case "group":