Merge branch 'v2.3.0release' of github.com:OpenIMSDK/Open-IM-Server into v2.3.0release

This commit is contained in:
wangchuxiao 2022-07-06 16:12:33 +08:00
commit 278329b73c
2 changed files with 13 additions and 4 deletions

View File

@ -183,7 +183,16 @@ func groupNotification(contentType int32, m proto.Message, sendID, groupID, recv
n.SendID = sendID n.SendID = sendID
if groupID != "" { if groupID != "" {
n.RecvID = groupID n.RecvID = groupID
n.SessionType = constant.GroupChatType group, err := imdb.GetGroupInfoByGroupID(groupID)
if err != nil {
log.NewError(operationID, "GetGroupInfoByGroupID failed ", err.Error(), groupID)
}
switch group.GroupType {
case constant.NormalGroup:
n.SessionType = constant.GroupChatType
default:
n.SessionType = constant.SuperGroupChatType
}
} else { } else {
n.RecvID = recvUserID n.RecvID = recvUserID
n.SessionType = constant.SingleChatType n.SessionType = constant.SingleChatType

View File

@ -161,9 +161,9 @@ const (
GroupStatusMuted = 3 GroupStatusMuted = 3
//GroupType //GroupType
NormalGroup = 0 NormalGroup = 0
SuperGroup = 1 SuperGroup = 1
DepartmentGroup = 2 WorkingGroup = 2
GroupBaned = 3 GroupBaned = 3
GroupBanPrivateChat = 4 GroupBanPrivateChat = 4