mirror of
https://github.com/283375/arcaea-offline.git
synced 2025-04-19 06:00:18 +00:00
impr(external): Andreal B30 best30_overflow
field
This commit is contained in:
parent
00255e5b74
commit
66a4cc8cff
@ -74,10 +74,10 @@ class AndrealImageGeneratorApiDataConverter:
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
def user_best30(self, limit: int = 40):
|
def user_best30(self):
|
||||||
scores = list(
|
scores = list(
|
||||||
self.session.scalars(
|
self.session.scalars(
|
||||||
select(ScoreBest).order_by(ScoreBest.potential.desc()).limit(limit)
|
select(ScoreBest).order_by(ScoreBest.potential.desc()).limit(40)
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
if not scores:
|
if not scores:
|
||||||
@ -88,6 +88,7 @@ class AndrealImageGeneratorApiDataConverter:
|
|||||||
"content": {
|
"content": {
|
||||||
"account_info": self.account_info(),
|
"account_info": self.account_info(),
|
||||||
"best30_avg": best30_avg,
|
"best30_avg": best30_avg,
|
||||||
"best30_list": [self.score(score) for score in scores],
|
"best30_list": [self.score(score) for score in scores[:30]],
|
||||||
|
"best30_overflow": [self.score(score) for score in scores[-10:]],
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user