32 lines
788 B
Go
32 lines
788 B
Go
package sociaty
|
|
|
|
import (
|
|
"go_dreamfactory/comm"
|
|
"go_dreamfactory/lego/sys/log"
|
|
"go_dreamfactory/pb"
|
|
)
|
|
|
|
// 公会成员列表
|
|
|
|
func (this *apiComp) MembersCheck(session comm.IUserSession, req *pb.SociatyMembersReq) (errdata *pb.ErrorData) {
|
|
return
|
|
}
|
|
|
|
func (this *apiComp) Members(session comm.IUserSession, req *pb.SociatyMembersReq) (errdata *pb.ErrorData) {
|
|
uid := session.GetUserId()
|
|
sociaty := this.module.modelSociaty.getUserSociaty(uid)
|
|
if sociaty == nil {
|
|
this.module.Error("当前玩家所在的公会未找到", log.Field{Key: "uid", Value: uid})
|
|
return
|
|
}
|
|
|
|
// 成员列表
|
|
members := this.module.modelSociaty.members(sociaty)
|
|
rsp := &pb.SociatyMembersResp{
|
|
List: members,
|
|
}
|
|
|
|
session.SendMsg(string(this.module.GetType()), SociatySubTypeMembers, rsp)
|
|
return
|
|
}
|