gen group pb

This commit is contained in:
withchao 2023-05-31 15:54:42 +08:00
parent f61a5429a0
commit e8763f32d0
4 changed files with 521 additions and 526 deletions

View File

@ -141,7 +141,7 @@ func (s *groupServer) CreateGroup(ctx context.Context, req *pbGroup.CreateGroupR
if err := tokenverify.CheckAccessV3(ctx, req.OwnerUserID); err != nil {
return nil, err
}
userIDs := append(append(req.InitMembers, req.AdminUserIDs...), req.OwnerUserID)
userIDs := append(append(req.MemberUserIDs, req.AdminUserIDs...), req.OwnerUserID)
opUserID := mcontext.GetOpUserID(ctx)
if !utils.Contain(opUserID, userIDs...) {
userIDs = append(userIDs, opUserID)
@ -190,7 +190,7 @@ func (s *groupServer) CreateGroup(ctx context.Context, req *pbGroup.CreateGroupR
return nil, err
}
}
for _, userID := range req.InitMembers {
for _, userID := range req.MemberUserIDs {
if err := joinGroup(userID, constant.GroupOrdinaryUsers); err != nil {
return nil, err
}

View File

@ -1,13 +1,12 @@
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.25.0
// protoc-gen-go v1.29.1
// protoc v4.22.0
// source: errinfo/errinfo.proto
package errinfo
import (
proto "github.com/golang/protobuf/proto"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
@ -21,20 +20,16 @@ const (
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
// This is a compile-time assertion that a sufficiently up-to-date version
// of the legacy proto package is being used.
const _ = proto.ProtoPackageIsVersion4
type ErrorInfo struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
Line uint32 `protobuf:"varint,2,opt,name=line,proto3" json:"line,omitempty"`
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
Cause string `protobuf:"bytes,4,opt,name=cause,proto3" json:"cause,omitempty"`
Warp []string `protobuf:"bytes,5,rep,name=warp,proto3" json:"warp,omitempty"`
Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path"`
Line uint32 `protobuf:"varint,2,opt,name=line,proto3" json:"line"`
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name"`
Cause string `protobuf:"bytes,4,opt,name=cause,proto3" json:"cause"`
Warp []string `protobuf:"bytes,5,rep,name=warp,proto3" json:"warp"`
}
func (x *ErrorInfo) Reset() {

File diff suppressed because it is too large Load Diff

View File

@ -7,7 +7,7 @@ option go_package = "github.com/OpenIMSDK/Open-IM-Server/pkg/proto/group";
message CreateGroupReq{
repeated string initMembers = 1;
repeated string memberUserIDs = 1;
sdkws.GroupInfo groupInfo = 2;
repeated string adminUserIDs = 3;
string ownerUserID = 4; //owner