排行榜:修改领取奖励返回格式
This commit is contained in:
@@ -12,6 +12,7 @@ import { getWorldChannelSid } from "./chatChannelService";
|
||||
import { pinus } from "pinus";
|
||||
import { RankFirstModel, RankFirstType, RankFirstUpdateParam } from "../db/RankFirst";
|
||||
import { getRandSingleEelm } from "../pubUtils/util";
|
||||
import { RANK_FIRST_REWARD_STATUS } from '../consts';
|
||||
|
||||
|
||||
/**
|
||||
@@ -1064,10 +1065,10 @@ export async function getGeneralRank(role: RoleType & { rankReceived: number[] }
|
||||
}
|
||||
|
||||
if(rankFirst) {
|
||||
let status = rankReceived.includes(id)?2: 1;
|
||||
let status = rankReceived.includes(id)?RANK_FIRST_REWARD_STATUS.RECEIVED: RANK_FIRST_REWARD_STATUS.CAN_RECEIVE;
|
||||
result.push({...rankFirst, status});
|
||||
} else {
|
||||
result.push({ id, type, status: 0 });
|
||||
result.push({ id, type, status: RANK_FIRST_REWARD_STATUS.WAITING });
|
||||
}
|
||||
}
|
||||
return result;
|
||||
|
||||
Reference in New Issue
Block a user