mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-06-01 00:13:20 -05:00
14 lines
419 B
TypeScript
14 lines
419 B
TypeScript
import { Prisma } from "@prisma/client";
|
|
import prisma from "prisma/client";
|
|
|
|
export type GetPlayersTop500Placements = Prisma.PromiseReturnType<
|
|
typeof getPlayersTop500Placements
|
|
>;
|
|
|
|
export const getPlayersTop500Placements = async (switchAccountId: string) => {
|
|
return prisma.xRankPlacement.findMany({
|
|
where: { switchAccountId },
|
|
orderBy: [{ year: "desc" }, { month: "desc" }, { ranking: "asc" }],
|
|
});
|
|
};
|