mirror of
https://github.com/openimsdk/open-im-server.git
synced 2026-05-11 20:45:57 +08:00
add sdk svr to docker script
This commit is contained in:
@@ -14,7 +14,7 @@ type config struct {
|
||||
GinPort []int `yaml:"openImApiPort"`
|
||||
}
|
||||
Sdk struct {
|
||||
WsPort []int `yaml:"sdkWsPort"`
|
||||
WsPort []int `yaml:"openImSdkWsPort"`
|
||||
}
|
||||
Credential struct {
|
||||
Tencent struct {
|
||||
@@ -92,7 +92,7 @@ type config struct {
|
||||
PushName string `yaml:"pushName"`
|
||||
}
|
||||
LongConnSvr struct {
|
||||
WebsocketPort []int `yaml:"websocketPort"`
|
||||
WebsocketPort []int `yaml:"openImWsPort"`
|
||||
WebsocketMaxConnNum int `yaml:"websocketMaxConnNum"`
|
||||
WebsocketMaxMsgLen int `yaml:"websocketMaxMsgLen"`
|
||||
WebsocketTimeOut int `yaml:"websocketTimeOut"`
|
||||
|
||||
@@ -110,6 +110,10 @@ func (s *friendServer) ImportFriend(ctx context.Context, req *pbFriend.ImportFri
|
||||
SessionType: constant.SingleChatType,
|
||||
OperationID: req.OperationID,
|
||||
})
|
||||
} else {
|
||||
resp.CommonResp.ErrorMsg = "some uid establish failed"
|
||||
resp.CommonResp.ErrorCode = 408
|
||||
resp.FailedUidList = append(resp.FailedUidList, v)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -81,7 +81,7 @@ func (s *groupServer) InviteUserToGroup(ctx context.Context, req *pbGroup.Invite
|
||||
log.Error(claims.UID, req.OperationID, "FindUserByUID failed, err: ", err.Error())
|
||||
return &pbGroup.InviteUserToGroupResp{ErrorCode: config.ErrParam.ErrCode, ErrorMsg: config.ErrParam.ErrMsg}, nil
|
||||
}*/
|
||||
|
||||
var nicknameList string
|
||||
for _, v := range req.UidList {
|
||||
var resultNode pbGroup.Id2Result
|
||||
resultNode.UId = v
|
||||
@@ -113,7 +113,7 @@ func (s *groupServer) InviteUserToGroup(ctx context.Context, req *pbGroup.Invite
|
||||
if err != nil {
|
||||
log.Error("", "", "add mongo group member failed, db.DB.AddGroupMember fail [err: %s]", err.Error())
|
||||
}
|
||||
|
||||
nicknameList = nicknameList + toUserInfo.Name + " "
|
||||
resp.Id2Result = append(resp.Id2Result, &resultNode)
|
||||
}
|
||||
resp.ErrorCode = 0
|
||||
@@ -121,12 +121,13 @@ func (s *groupServer) InviteUserToGroup(ctx context.Context, req *pbGroup.Invite
|
||||
|
||||
//if claims.UID == config.Config.AppManagerUid
|
||||
if utils.IsContain(claims.UID, config.Config.Manager.AppManagerUid) {
|
||||
m, _ := imdb.FindUserByUID(claims.UID)
|
||||
var iu inviteUserToGroupReq
|
||||
iu.GroupID = req.GroupID
|
||||
iu.OperationID = req.OperationID
|
||||
iu.Reason = req.Reason
|
||||
iu.UidList = req.UidList
|
||||
n := content_struct.NotificationContent{1, req.GroupID, iu.ContentToString()}
|
||||
n := content_struct.NotificationContent{1, nicknameList + " invited into the group chat by " + m.Name, iu.ContentToString()}
|
||||
logic.SendMsgByWS(&pbChat.WSToMsgSvrChatMsg{
|
||||
SendID: claims.UID,
|
||||
RecvID: req.GroupID,
|
||||
|
||||
Reference in New Issue
Block a user