From 1445c7629ef432a0ae795d14dd3ded38bc8164c4 Mon Sep 17 00:00:00 2001 From: meixiongfeng <766881921@qq.com> Date: Mon, 1 Aug 2022 18:11:08 +0800 Subject: [PATCH] bug --- modules/hero/model_hero.go | 2 +- modules/mail/api_delmail.go | 2 +- modules/mail/api_getAttachment.go | 58 ++++++++- modules/mail/api_getmail.go | 2 +- modules/mail/api_readmail.go | 2 +- modules/mail/model_mail.go | 27 ++-- modules/mail/module.go | 2 +- pb/mail_msg.pb.go | 202 ++++++++++++++++++++++++------ 8 files changed, 242 insertions(+), 55 deletions(-) diff --git a/modules/hero/model_hero.go b/modules/hero/model_hero.go index 65f2ac6fb..e03bc604a 100644 --- a/modules/hero/model_hero.go +++ b/modules/hero/model_hero.go @@ -150,7 +150,7 @@ func (this *ModelHero) createHeroOverlying(uid string, heroCfgId string, count i data := map[string]interface{}{ "sameCount": h.SameCount, //叠加数 } - + hero = h if err := this.ChangeList(uid, h.Id, data); err != nil { return nil, err } diff --git a/modules/mail/api_delmail.go b/modules/mail/api_delmail.go index d49fbb069..5b99602f8 100644 --- a/modules/mail/api_delmail.go +++ b/modules/mail/api_delmail.go @@ -22,7 +22,7 @@ func (this *apiComp) DelMail(session comm.IUserSession, req *pb.MailDelMailReq) if code != pb.ErrorCode_Success { return } - bRet := this.module.modelMail.Mail_DelUserMail(req.ObjID) + bRet := this.module.modelMail.MailDelUserMail(req.ObjID) if !bRet { code = pb.ErrorCode_MailErr // 邮件不存在 return diff --git a/modules/mail/api_getAttachment.go b/modules/mail/api_getAttachment.go index ec04a087a..04fd2e6da 100644 --- a/modules/mail/api_getAttachment.go +++ b/modules/mail/api_getAttachment.go @@ -22,7 +22,7 @@ func (this *apiComp) GetUserMailAttachment(session comm.IUserSession, req *pb.Ma if code != pb.ErrorCode_Success { return } - mail, err := this.module.modelMail.Mail_GetMailAttachmentState(req.ObjID, session.GetUserId()) + mail, err := this.module.modelMail.MailGetMailAttachmentState(req.ObjID) if err != nil { code = pb.ErrorCode_MailErr return @@ -31,7 +31,7 @@ func (this *apiComp) GetUserMailAttachment(session comm.IUserSession, req *pb.Ma code = pb.ErrorCode_StateInvalid return } - _data, err := this.module.modelMail.Mail_GetMailAttachment(req.ObjID) + _data, err := this.module.modelMail.MailGetMailAttachment(req.ObjID) if err == nil { if len(_data) > 0 { res := make([]*cfg.Game_atn, 0) @@ -46,7 +46,7 @@ func (this *apiComp) GetUserMailAttachment(session comm.IUserSession, req *pb.Ma code = this.module.api.module.DispenseRes(session, res, true) // 领取附件 if code == pb.ErrorCode_Success { // 修改状态 - this.module.modelMail.Mail_UpdateMailAttachmentState(req.ObjID) + this.module.modelMail.MailUpdateMailAttachmentState(req.ObjID) mail.Reward = true return } @@ -56,3 +56,55 @@ func (this *apiComp) GetUserMailAttachment(session comm.IUserSession, req *pb.Ma session.SendMsg(string(this.module.GetType()), "getusermailattachment", &pb.MailGetUserMailAttachmentResp{Mail: mail}) return } + +func (this *apiComp) GetAllMailAttachmentCheck(session comm.IUserSession, req *pb.MailGetAllMailAttachmentReq) (code pb.ErrorCode) { + + return +} + +func (this *apiComp) GetAllMailAttachment(session comm.IUserSession, req *pb.MailGetAllMailAttachmentReq) (code pb.ErrorCode, data proto.Message) { + + code = this.GetAllMailAttachmentCheck(session, req) // check + if code != pb.ErrorCode_Success { + return + } + mails, err := this.module.modelMail.MailQueryUserMailByReard(session.GetUserId()) + if err != nil { + code = pb.ErrorCode_MailErr + return + } + if len(mails) == 0 { + code = pb.ErrorCode_MailErr + return + } + res := make([]*cfg.Game_atn, 0) + for _, v := range mails { + + for _, v1 := range v.Items { + d := &cfg.Game_atn{ + A: v1.A, + T: v1.T, + N: v1.N, + } + res = append(res, d) + } + code = this.module.api.module.DispenseRes(session, res, true) // 领取附件 + if code == pb.ErrorCode_Success { + // 修改状态 + this.module.modelMail.MailUpdateMailAttachmentState(v.ObjId) + v.Reward = true + return + } + } + fj := make([]*pb.UserAssets, 0) + for _, v := range res { + atn1 := &pb.UserAssets{ + A: v.A, + T: v.T, + N: v.N, + } + fj = append(fj, atn1) + } + session.SendMsg(string(this.module.GetType()), "getusermailattachment", &pb.MailGetAllMailAttachmentResp{Res: fj}) + return +} diff --git a/modules/mail/api_getmail.go b/modules/mail/api_getmail.go index cb8db052f..27d77b1e0 100644 --- a/modules/mail/api_getmail.go +++ b/modules/mail/api_getmail.go @@ -23,7 +23,7 @@ func (this *apiComp) GetList(session comm.IUserSession, req *pb.MailGetListReq) if code != pb.ErrorCode_Success { return } - if mailinfo, err = this.module.modelMail.Mail_QueryUserMail(session.GetUserId()); err != nil { + if mailinfo, err = this.module.modelMail.MailQueryUserMail(session.GetUserId()); err != nil { this.module.Errorf("Mail_GetList_Resp err:%v", err) code = pb.ErrorCode_CacheReadError return diff --git a/modules/mail/api_readmail.go b/modules/mail/api_readmail.go index 85b5d4b15..65c15351d 100644 --- a/modules/mail/api_readmail.go +++ b/modules/mail/api_readmail.go @@ -28,7 +28,7 @@ func (this *apiComp) ReadMail(session comm.IUserSession, req *pb.MailReadMailReq log.Debugf("read mail failed%d", code) return } - mail, err = this.module.modelMail.Mail_ReadOneMail(req.ObjID) + mail, err = this.module.modelMail.MailReadOneMail(req.ObjID) if err != nil { code = pb.ErrorCode_ReqParameterError return diff --git a/modules/mail/model_mail.go b/modules/mail/model_mail.go index 471207852..95fa1f676 100644 --- a/modules/mail/model_mail.go +++ b/modules/mail/model_mail.go @@ -32,7 +32,7 @@ func (this *modelMail) Init(service core.IService, module core.IModule, comp cor return } -func (this *modelMail) Mail_QueryUserMail(uId string) (mail []*pb.DBMailData, err error) { +func (this *modelMail) MailQueryUserMail(uId string) (mail []*pb.DBMailData, err error) { if _data, err := this.DB.Find(DB_MailTable, bson.M{"uid": uId}); err == nil { for _data.Next(context.TODO()) { @@ -46,7 +46,7 @@ func (this *modelMail) Mail_QueryUserMail(uId string) (mail []*pb.DBMailData, er } // 插入一封新的邮件 -func (this *modelMail) Mail_InsertUserMail(mail *pb.DBMailData) (err error) { +func (this *modelMail) MailInsertUserMail(mail *pb.DBMailData) (err error) { mail.ObjId = primitive.NewObjectID().Hex() mail.Check = false @@ -60,7 +60,7 @@ func (this *modelMail) Mail_InsertUserMail(mail *pb.DBMailData) (err error) { return err } -func (this *modelMail) Mail_ReadOneMail(objId string) (mail *pb.DBMailData, err error) { +func (this *modelMail) MailReadOneMail(objId string) (mail *pb.DBMailData, err error) { err = this.DB.FindOneAndUpdate( DB_MailTable, @@ -75,7 +75,7 @@ func (this *modelMail) Mail_ReadOneMail(objId string) (mail *pb.DBMailData, err } // 查询附件信息 -func (this *modelMail) Mail_GetMailAttachment(objId string) (itmes []*pb.UserAssets, err error) { +func (this *modelMail) MailGetMailAttachment(objId string) (itmes []*pb.UserAssets, err error) { var nd *pb.DBMailData err = this.DB.FindOne(DB_MailTable, bson.M{"_id": objId}).Decode(&nd) @@ -86,7 +86,7 @@ func (this *modelMail) Mail_GetMailAttachment(objId string) (itmes []*pb.UserAss } // 查看领取附件状态 -func (this *modelMail) Mail_GetMailAttachmentState(objId string, uid string) (*pb.DBMailData, error) { +func (this *modelMail) MailGetMailAttachmentState(objId string) (*pb.DBMailData, error) { var nd *pb.DBMailData err := this.DB.FindOne(DB_MailTable, bson.M{"_id": objId}).Decode(&nd) @@ -95,7 +95,7 @@ func (this *modelMail) Mail_GetMailAttachmentState(objId string, uid string) (*p } // 更新领取附件状态 -func (this *modelMail) Mail_UpdateMailAttachmentState(objId string) bool { +func (this *modelMail) MailUpdateMailAttachmentState(objId string) bool { this.DB.FindOneAndUpdate( DB_MailTable, bson.M{"_id": objId}, @@ -109,7 +109,7 @@ func (this *modelMail) Mail_UpdateMailAttachmentState(objId string) bool { } // 删除一封邮件 -func (this *modelMail) Mail_DelUserMail(objId string) bool { +func (this *modelMail) MailDelUserMail(objId string) bool { var obj *pb.DBMailData err := this.DB.FindOne(DB_MailTable, bson.M{"_id": objId}).Decode(&obj) if err != nil { @@ -119,3 +119,16 @@ func (this *modelMail) Mail_DelUserMail(objId string) bool { return true } + +func (this *modelMail) MailQueryUserMailByReard(uId string) (mail []*pb.DBMailData, err error) { + + if _data, err := this.DB.Find(DB_MailTable, bson.M{"uid": uId, "Reward": false}); err == nil { + for _data.Next(context.TODO()) { + temp := &pb.DBMailData{} + if err = _data.Decode(temp); err == nil { + mail = append(mail, temp) + } + } + } + return +} diff --git a/modules/mail/module.go b/modules/mail/module.go index 07356c744..dd8d49258 100644 --- a/modules/mail/module.go +++ b/modules/mail/module.go @@ -51,7 +51,7 @@ func (this *Mail) CreateNewMail(session comm.IUserSession, mail *pb.DBMailData) if mail == nil { return false } - err := this.modelMail.Mail_InsertUserMail(mail) + err := this.modelMail.MailInsertUserMail(mail) if err != nil { this.ModuleBase.Errorf("create mail failed") } diff --git a/pb/mail_msg.pb.go b/pb/mail_msg.pb.go index 949428518..da074101a 100644 --- a/pb/mail_msg.pb.go +++ b/pb/mail_msg.pb.go @@ -439,39 +439,132 @@ func (x *MailGetNewMailPush) GetMail() *DBMailData { return nil } +// 领取所有附件 +type MailGetAllMailAttachmentReq struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *MailGetAllMailAttachmentReq) Reset() { + *x = MailGetAllMailAttachmentReq{} + if protoimpl.UnsafeEnabled { + mi := &file_mail_mail_msg_proto_msgTypes[9] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MailGetAllMailAttachmentReq) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MailGetAllMailAttachmentReq) ProtoMessage() {} + +func (x *MailGetAllMailAttachmentReq) ProtoReflect() protoreflect.Message { + mi := &file_mail_mail_msg_proto_msgTypes[9] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use MailGetAllMailAttachmentReq.ProtoReflect.Descriptor instead. +func (*MailGetAllMailAttachmentReq) Descriptor() ([]byte, []int) { + return file_mail_mail_msg_proto_rawDescGZIP(), []int{9} +} + +type MailGetAllMailAttachmentResp struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Res []*UserAssets `protobuf:"bytes,1,rep,name=res,proto3" json:"res"` //资源类型 +} + +func (x *MailGetAllMailAttachmentResp) Reset() { + *x = MailGetAllMailAttachmentResp{} + if protoimpl.UnsafeEnabled { + mi := &file_mail_mail_msg_proto_msgTypes[10] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *MailGetAllMailAttachmentResp) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*MailGetAllMailAttachmentResp) ProtoMessage() {} + +func (x *MailGetAllMailAttachmentResp) ProtoReflect() protoreflect.Message { + mi := &file_mail_mail_msg_proto_msgTypes[10] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use MailGetAllMailAttachmentResp.ProtoReflect.Descriptor instead. +func (*MailGetAllMailAttachmentResp) Descriptor() ([]byte, []int) { + return file_mail_mail_msg_proto_rawDescGZIP(), []int{10} +} + +func (x *MailGetAllMailAttachmentResp) GetRes() []*UserAssets { + if x != nil { + return x.Res + } + return nil +} + var File_mail_mail_msg_proto protoreflect.FileDescriptor var file_mail_mail_msg_proto_rawDesc = []byte{ 0x0a, 0x13, 0x6d, 0x61, 0x69, 0x6c, 0x2f, 0x6d, 0x61, 0x69, 0x6c, 0x5f, 0x6d, 0x73, 0x67, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x12, 0x6d, 0x61, 0x69, 0x6c, 0x2f, 0x6d, 0x61, 0x69, 0x6c, - 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x10, 0x0a, 0x0e, 0x4d, 0x61, 0x69, - 0x6c, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x22, 0x34, 0x0a, 0x0f, 0x4d, - 0x61, 0x69, 0x6c, 0x47, 0x65, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x21, - 0x0a, 0x05, 0x4d, 0x61, 0x69, 0x6c, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, - 0x44, 0x42, 0x4d, 0x61, 0x69, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x52, 0x05, 0x4d, 0x61, 0x69, 0x6c, - 0x73, 0x22, 0x27, 0x0a, 0x0f, 0x4d, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x69, - 0x6c, 0x52, 0x65, 0x71, 0x12, 0x14, 0x0a, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x09, 0x52, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x22, 0x33, 0x0a, 0x10, 0x4d, 0x61, - 0x69, 0x6c, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1f, - 0x0a, 0x04, 0x4d, 0x61, 0x69, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x44, - 0x42, 0x4d, 0x61, 0x69, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04, 0x4d, 0x61, 0x69, 0x6c, 0x22, - 0x34, 0x0a, 0x1c, 0x4d, 0x61, 0x69, 0x6c, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x4d, 0x61, - 0x69, 0x6c, 0x41, 0x74, 0x74, 0x61, 0x63, 0x68, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x12, - 0x14, 0x0a, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, - 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x22, 0x40, 0x0a, 0x1d, 0x4d, 0x61, 0x69, 0x6c, 0x47, 0x65, 0x74, - 0x55, 0x73, 0x65, 0x72, 0x4d, 0x61, 0x69, 0x6c, 0x41, 0x74, 0x74, 0x61, 0x63, 0x68, 0x6d, 0x65, - 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1f, 0x0a, 0x04, 0x4d, 0x61, 0x69, 0x6c, 0x18, 0x01, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x44, 0x42, 0x4d, 0x61, 0x69, 0x6c, 0x44, 0x61, 0x74, - 0x61, 0x52, 0x04, 0x4d, 0x61, 0x69, 0x6c, 0x22, 0x26, 0x0a, 0x0e, 0x4d, 0x61, 0x69, 0x6c, 0x44, - 0x65, 0x6c, 0x4d, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x71, 0x12, 0x14, 0x0a, 0x05, 0x4f, 0x62, 0x6a, - 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x22, - 0x27, 0x0a, 0x0f, 0x4d, 0x61, 0x69, 0x6c, 0x44, 0x65, 0x6c, 0x4d, 0x61, 0x69, 0x6c, 0x52, 0x65, - 0x73, 0x70, 0x12, 0x14, 0x0a, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x22, 0x35, 0x0a, 0x12, 0x4d, 0x61, 0x69, 0x6c, - 0x47, 0x65, 0x74, 0x4e, 0x65, 0x77, 0x4d, 0x61, 0x69, 0x6c, 0x50, 0x75, 0x73, 0x68, 0x12, 0x1f, - 0x0a, 0x04, 0x4d, 0x61, 0x69, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x44, - 0x42, 0x4d, 0x61, 0x69, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04, 0x4d, 0x61, 0x69, 0x6c, 0x42, - 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x5f, 0x64, 0x62, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x1a, 0x0a, 0x63, 0x6f, 0x6d, 0x6d, 0x2e, + 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x10, 0x0a, 0x0e, 0x4d, 0x61, 0x69, 0x6c, 0x47, 0x65, 0x74, + 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x71, 0x22, 0x34, 0x0a, 0x0f, 0x4d, 0x61, 0x69, 0x6c, 0x47, + 0x65, 0x74, 0x4c, 0x69, 0x73, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x21, 0x0a, 0x05, 0x4d, 0x61, + 0x69, 0x6c, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x44, 0x42, 0x4d, 0x61, + 0x69, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x52, 0x05, 0x4d, 0x61, 0x69, 0x6c, 0x73, 0x22, 0x27, 0x0a, + 0x0f, 0x4d, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x61, 0x64, 0x4d, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x71, + 0x12, 0x14, 0x0a, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x22, 0x33, 0x0a, 0x10, 0x4d, 0x61, 0x69, 0x6c, 0x52, 0x65, + 0x61, 0x64, 0x4d, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1f, 0x0a, 0x04, 0x4d, 0x61, + 0x69, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x44, 0x42, 0x4d, 0x61, 0x69, + 0x6c, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04, 0x4d, 0x61, 0x69, 0x6c, 0x22, 0x34, 0x0a, 0x1c, 0x4d, + 0x61, 0x69, 0x6c, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, 0x4d, 0x61, 0x69, 0x6c, 0x41, 0x74, + 0x74, 0x61, 0x63, 0x68, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x12, 0x14, 0x0a, 0x05, 0x4f, + 0x62, 0x6a, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x4f, 0x62, 0x6a, 0x49, + 0x44, 0x22, 0x40, 0x0a, 0x1d, 0x4d, 0x61, 0x69, 0x6c, 0x47, 0x65, 0x74, 0x55, 0x73, 0x65, 0x72, + 0x4d, 0x61, 0x69, 0x6c, 0x41, 0x74, 0x74, 0x61, 0x63, 0x68, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, + 0x73, 0x70, 0x12, 0x1f, 0x0a, 0x04, 0x4d, 0x61, 0x69, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, + 0x32, 0x0b, 0x2e, 0x44, 0x42, 0x4d, 0x61, 0x69, 0x6c, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04, 0x4d, + 0x61, 0x69, 0x6c, 0x22, 0x26, 0x0a, 0x0e, 0x4d, 0x61, 0x69, 0x6c, 0x44, 0x65, 0x6c, 0x4d, 0x61, + 0x69, 0x6c, 0x52, 0x65, 0x71, 0x12, 0x14, 0x0a, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x18, 0x01, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x22, 0x27, 0x0a, 0x0f, 0x4d, + 0x61, 0x69, 0x6c, 0x44, 0x65, 0x6c, 0x4d, 0x61, 0x69, 0x6c, 0x52, 0x65, 0x73, 0x70, 0x12, 0x14, + 0x0a, 0x05, 0x4f, 0x62, 0x6a, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x4f, + 0x62, 0x6a, 0x49, 0x44, 0x22, 0x35, 0x0a, 0x12, 0x4d, 0x61, 0x69, 0x6c, 0x47, 0x65, 0x74, 0x4e, + 0x65, 0x77, 0x4d, 0x61, 0x69, 0x6c, 0x50, 0x75, 0x73, 0x68, 0x12, 0x1f, 0x0a, 0x04, 0x4d, 0x61, + 0x69, 0x6c, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x44, 0x42, 0x4d, 0x61, 0x69, + 0x6c, 0x44, 0x61, 0x74, 0x61, 0x52, 0x04, 0x4d, 0x61, 0x69, 0x6c, 0x22, 0x1d, 0x0a, 0x1b, 0x4d, + 0x61, 0x69, 0x6c, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x4d, 0x61, 0x69, 0x6c, 0x41, 0x74, 0x74, + 0x61, 0x63, 0x68, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x22, 0x3d, 0x0a, 0x1c, 0x4d, 0x61, + 0x69, 0x6c, 0x47, 0x65, 0x74, 0x41, 0x6c, 0x6c, 0x4d, 0x61, 0x69, 0x6c, 0x41, 0x74, 0x74, 0x61, + 0x63, 0x68, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x12, 0x1d, 0x0a, 0x03, 0x72, 0x65, + 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x0b, 0x2e, 0x55, 0x73, 0x65, 0x72, 0x41, 0x73, + 0x73, 0x65, 0x74, 0x73, 0x52, 0x03, 0x72, 0x65, 0x73, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, + 0x62, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -486,7 +579,7 @@ func file_mail_mail_msg_proto_rawDescGZIP() []byte { return file_mail_mail_msg_proto_rawDescData } -var file_mail_mail_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 9) +var file_mail_mail_msg_proto_msgTypes = make([]protoimpl.MessageInfo, 11) var file_mail_mail_msg_proto_goTypes = []interface{}{ (*MailGetListReq)(nil), // 0: MailGetListReq (*MailGetListResp)(nil), // 1: MailGetListResp @@ -497,18 +590,22 @@ var file_mail_mail_msg_proto_goTypes = []interface{}{ (*MailDelMailReq)(nil), // 6: MailDelMailReq (*MailDelMailResp)(nil), // 7: MailDelMailResp (*MailGetNewMailPush)(nil), // 8: MailGetNewMailPush - (*DBMailData)(nil), // 9: DBMailData + (*MailGetAllMailAttachmentReq)(nil), // 9: MailGetAllMailAttachmentReq + (*MailGetAllMailAttachmentResp)(nil), // 10: MailGetAllMailAttachmentResp + (*DBMailData)(nil), // 11: DBMailData + (*UserAssets)(nil), // 12: UserAssets } var file_mail_mail_msg_proto_depIdxs = []int32{ - 9, // 0: MailGetListResp.Mails:type_name -> DBMailData - 9, // 1: MailReadMailResp.Mail:type_name -> DBMailData - 9, // 2: MailGetUserMailAttachmentResp.Mail:type_name -> DBMailData - 9, // 3: MailGetNewMailPush.Mail:type_name -> DBMailData - 4, // [4:4] is the sub-list for method output_type - 4, // [4:4] is the sub-list for method input_type - 4, // [4:4] is the sub-list for extension type_name - 4, // [4:4] is the sub-list for extension extendee - 0, // [0:4] is the sub-list for field type_name + 11, // 0: MailGetListResp.Mails:type_name -> DBMailData + 11, // 1: MailReadMailResp.Mail:type_name -> DBMailData + 11, // 2: MailGetUserMailAttachmentResp.Mail:type_name -> DBMailData + 11, // 3: MailGetNewMailPush.Mail:type_name -> DBMailData + 12, // 4: MailGetAllMailAttachmentResp.res:type_name -> UserAssets + 5, // [5:5] is the sub-list for method output_type + 5, // [5:5] is the sub-list for method input_type + 5, // [5:5] is the sub-list for extension type_name + 5, // [5:5] is the sub-list for extension extendee + 0, // [0:5] is the sub-list for field type_name } func init() { file_mail_mail_msg_proto_init() } @@ -517,6 +614,7 @@ func file_mail_mail_msg_proto_init() { return } file_mail_mail_db_proto_init() + file_comm_proto_init() if !protoimpl.UnsafeEnabled { file_mail_mail_msg_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*MailGetListReq); i { @@ -626,6 +724,30 @@ func file_mail_mail_msg_proto_init() { return nil } } + file_mail_mail_msg_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MailGetAllMailAttachmentReq); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_mail_mail_msg_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*MailGetAllMailAttachmentResp); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } } type x struct{} out := protoimpl.TypeBuilder{ @@ -633,7 +755,7 @@ func file_mail_mail_msg_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_mail_mail_msg_proto_rawDesc, NumEnums: 0, - NumMessages: 9, + NumMessages: 11, NumExtensions: 0, NumServices: 0, },