This commit is contained in:
wh_zcy 2022-11-11 15:59:53 +08:00
commit 8cfb36d4ad
2 changed files with 12 additions and 12 deletions

View File

@ -252,7 +252,7 @@ func (this *ModelRank) seasonSettlement() {
if conn, err := db.Cross(); err == nil { if conn, err := db.Cross(); err == nil {
var ( var (
pipe *pipe.RedisPipe = conn.Redis.RedisPipe(context.TODO()) pipe *pipe.RedisPipe = conn.Redis.RedisPipe(context.TODO())
Items []*pb.UserAssets //Items []*pb.UserAssets
) )
rd := pipe.ZRange("pagodaSeasonRank0", 0, 50) rd := pipe.ZRange("pagodaSeasonRank0", 0, 50)
@ -264,7 +264,7 @@ func (this *ModelRank) seasonSettlement() {
uids := rd.Val() uids := rd.Val()
if len(uids) > 0 { if len(uids) > 0 {
Items = make([]*pb.UserAssets, 0) //TO 排名配置 //Items = make([]*pb.UserAssets, 0) //TO 排名配置
// for i, v := range v.RankReward { // for i, v := range v.RankReward {
// Items[i] = &pb.UserAssets{ // Items[i] = &pb.UserAssets{
// A: v.A, // A: v.A,
@ -273,10 +273,10 @@ func (this *ModelRank) seasonSettlement() {
// } // }
// } // }
//发邮件 //发邮件
this.modulePagoda.mail.SendNewMail(&pb.DBMailData{ // this.modulePagoda.mail.SendNewMail(&pb.DBMailData{
CreateTime: uint64(configure.Now().Unix()), // CreateTime: uint64(configure.Now().Unix()),
Items: Items, // Items: Items,
}, uids...) // }, uids...)
} }
} }
} }

View File

@ -24,7 +24,7 @@ type Pagoda struct {
configure *configureComp configure *configureComp
battle comm.IBattle battle comm.IBattle
service base.IRPCXService service base.IRPCXService
mail comm.Imail //mail comm.Imail
} }
func NewModule() core.IModule { func NewModule() core.IModule {
@ -73,10 +73,10 @@ func (this *Pagoda) Start() (err error) {
if module, err = this.service.GetModule(comm.ModuleBattle); err != nil { if module, err = this.service.GetModule(comm.ModuleBattle); err != nil {
return return
} }
if module, err = this.service.GetModule(comm.ModuleMail); err != nil { // if module, err = this.service.GetModule(comm.ModuleMail); err != nil {
return // return
} // }
this.mail = module.(comm.Imail) //this.mail = module.(comm.Imail)
this.battle = module.(comm.IBattle) this.battle = module.(comm.IBattle)
this.service.RegisterFunctionName(string(comm.Rpc_ModuleSeasonPagodaReward), this.Rpc_ModuleSeasonPagodaReward) this.service.RegisterFunctionName(string(comm.Rpc_ModuleSeasonPagodaReward), this.Rpc_ModuleSeasonPagodaReward)
return return