红点:添加每日5点定时刷新推送

This commit is contained in:
luying
2021-06-03 12:04:32 +08:00
parent 9eb82321c4
commit e29344072f
6 changed files with 156 additions and 81 deletions

View File

@@ -26,6 +26,7 @@ import { GuildModel } from '../db/Guild';
import { dispatch } from '../util/dispatcher';
import { Rank } from './rankService';
import { checkTask } from './taskService';
import { everydayRefresh } from './connectorService';
const PER_SECOND = 1 * 1000;
const PER_DAY = 24 * 60 * 60;
@@ -75,12 +76,13 @@ export async function init() {
// 军团活动排行榜
guildActivitySchedule();
// 每天0点计算前一天活跃玩家中位数战力
scheduleJob('setMedian', '0 0 5 * * ?', setMedianCe);
// 拍卖行刷新:拍卖阶段刷新,分红发放
auctionSchedule();
// 每天5点推送刷新时间消息
// 顺便每天0点计算前一天活跃玩家中位数战力
scheduleJob('everyDayRefresh', `0 0 ${REFRESH_TIME} * * ?`, everydayRefresh);
}
function setPvpSeasonSchdule() {