名将擂台:排行榜细节

This commit is contained in:
luying
2022-07-16 18:40:10 +08:00
parent 0a80d3f2cf
commit d9f6174900
3 changed files with 27 additions and 12 deletions

View File

@@ -78,7 +78,7 @@ export default class LadderMatch extends BaseModel {
public static async findAll(serverId: number) {
let result: LadderMatchType[] = [], latestTime = new Date();
while(latestTime) {
let ladderMatch = await LadderMatchModel.find({ serverId, rank: { $gt: 0, $lte: 3000 }, createdAt: { $lt: latestTime } })
let ladderMatch = await LadderMatchModel.find({ serverId, rank: { $gt: 0 }, createdAt: { $lt: latestTime } })
.sort({ createdAt: -1 })
.populate('role', 'roleId roleName head frame spine heads frames spines title lv updatedAt')
.limit(1000);