活动:月卡权限

This commit is contained in:
luying
2022-03-09 19:47:20 +08:00
parent dafc77954b
commit f440ef2ebe
22 changed files with 295 additions and 220 deletions
+3 -3
View File
@@ -187,10 +187,10 @@ async function getTowerEntryData(role: RoleType) {
const status = await getTowerStatus(role);
const hungUp = await getHungupRewards(roleId);
const tasks = await getTasks(role);
if (hungUp.status == -1) {
if (!hungUp) {
return { status, hungUp: {}, tasks }
} else {
return { status, hungUp: hungUp.data, tasks }
return { status, hungUp: hungUp, tasks }
}
}
@@ -202,7 +202,7 @@ async function getPvpEntryData(roleId: string) {
let pvpDefense = await PvpDefenseModel.findByRoleId(roleId);
if (pvpDefense) {
let seasonEndTime = pinus.app.get('pvpSeasonEndTime');
let refChallengeObj = refChallengeCnt(pvpDefense.challengeCnt, pvpDefense.challengeRefTime, seasonEndTime);
let refChallengeObj = await refChallengeCnt(pvpDefense.challengeCnt, pvpDefense.challengeRefTime, seasonEndTime, roleId);
let { challengeCnt } = refChallengeObj;
let { receivedBox, score, hisScore } = pvpDefense;