diff --git a/modules/timer/vikingrank.go b/modules/timer/vikingrank.go index fa7e49d27..b814679aa 100644 --- a/modules/timer/vikingrank.go +++ b/modules/timer/vikingrank.go @@ -46,12 +46,12 @@ func (this *VikingRank) Start() (err error) { // 0 0 0 ? * MON // 每周一零点 cron.AddFunc("0 0 0 ? * MON", this.TimerSeason) - this.TimerSeason() + //this.TimerSeason() return } func (this *VikingRank) TimerSeason() { - endTime := utils.WeekIntervalTime() + endTime := utils.WeekIntervalTime(configure.Now().Unix()) this.module.Debugf("TimerSeason end: %d,cur time:%d", endTime, configure.Now().Unix()) if err := this.service.RpcCall( diff --git a/modules/viking/api_seasonrank.go b/modules/viking/api_seasonrank.go index 03efff675..199cc8e0e 100644 --- a/modules/viking/api_seasonrank.go +++ b/modules/viking/api_seasonrank.go @@ -3,6 +3,7 @@ package viking import ( "go_dreamfactory/comm" "go_dreamfactory/pb" + "go_dreamfactory/sys/configure" "go_dreamfactory/sys/db" "go_dreamfactory/utils" ) @@ -61,10 +62,9 @@ func (this *apiComp) SeasonRank(session comm.IUserSession, req *pb.VikingSeasonR } } - _, etime := utils.GetMonthStartEnd() session.SendMsg(string(this.module.GetType()), VikingSeasonRankReq, &pb.VikingSeasonRankResp{ Ranks: players, - Etime: etime, + Etime: utils.WeekIntervalTime(configure.Now().Unix()), }) return }