77 lines
1.9 KiB
Go
77 lines
1.9 KiB
Go
package friend
|
|
|
|
import (
|
|
"context"
|
|
"go_dreamfactory/comm"
|
|
"go_dreamfactory/modules"
|
|
"go_dreamfactory/pb"
|
|
)
|
|
|
|
type FriendComp struct {
|
|
modules.MComp_GateComp
|
|
}
|
|
|
|
//搜索
|
|
func (this *FriendComp) Search(ctx context.Context, session comm.IUserSession, req *pb.FriendSearchReq) error {
|
|
return nil
|
|
}
|
|
|
|
//添加好友
|
|
func (this *FriendComp) Apply(ctx context.Context, session comm.IUserSession, req *pb.FriendAddReq) error {
|
|
//判断是否超过最大好友数量
|
|
//判断对方是否也超过最大好友数量
|
|
//判断是否是自己
|
|
//判断是否是好友
|
|
//判断是否已经申请
|
|
//判断是否在黑名单中
|
|
//判断是否在对方的黑名单中
|
|
|
|
|
|
return nil
|
|
}
|
|
|
|
//删除好友
|
|
func (this *FriendComp) Del(ctx context.Context, session comm.IUserSession, req *pb.FriendDelReq) error {
|
|
return nil
|
|
}
|
|
|
|
//好友列表
|
|
func (this *FriendComp) List(ctx context.Context, session comm.IUserSession, req *pb.FriendListReq) error {
|
|
return nil
|
|
}
|
|
|
|
//同意或拒绝
|
|
func (this *FriendComp) Check(ctx context.Context, session comm.IUserSession, req *pb.FriendAgreeOrRefuseReq) error {
|
|
return nil
|
|
}
|
|
|
|
//批量同意或拒绝
|
|
func (this *FriendComp) CheckAll(ctx context.Context, session comm.IUserSession, req *pb.FriendAgreeOrRefuseReq) error {
|
|
return nil
|
|
}
|
|
|
|
//赠送或接收
|
|
func (this *FriendComp) ReceSend(ctx context.Context, session comm.IUserSession, req *pb.FriendReceiveOrSendReq) error {
|
|
return nil
|
|
}
|
|
|
|
//好友数量
|
|
func (this *FriendComp) Total(ctx context.Context, session comm.IUserSession, req *pb.FriendTotalReq) error {
|
|
return nil
|
|
}
|
|
|
|
//好友详情
|
|
func (this *FriendComp) Detail(ctx context.Context, session comm.IUserSession, req *pb.FriendTotalReq) error {
|
|
return nil
|
|
}
|
|
|
|
//黑名单
|
|
func (this *FriendComp) Blacklist(ctx context.Context, session comm.IUserSession, req *pb.FriendBlackListReq) error {
|
|
return nil
|
|
}
|
|
|
|
//加入黑名单
|
|
func (this *FriendComp) Addblack(ctx context.Context, session comm.IUserSession, req *pb.FriendBlackAddReq) error {
|
|
return nil
|
|
}
|