mirror of
https://github.com/aaronpo97/the-biergarten-app.git
synced 2026-02-16 10:42:08 +00:00
Update brewery/beer style to use tuples for ranges/coords. Seed updates.
This commit is contained in:
@@ -6,7 +6,7 @@ const getAllBeerStyles = async (
|
||||
pageNum: number,
|
||||
pageSize: number,
|
||||
): Promise<z.infer<typeof BeerStyleQueryResult>[]> => {
|
||||
const styles = await DBClient.instance.beerStyle.findMany({
|
||||
const styles = (await DBClient.instance.beerStyle.findMany({
|
||||
take: pageSize,
|
||||
skip: (pageNum - 1) * pageSize,
|
||||
select: {
|
||||
@@ -15,8 +15,10 @@ const getAllBeerStyles = async (
|
||||
postedBy: { select: { id: true, username: true } },
|
||||
createdAt: true,
|
||||
updatedAt: true,
|
||||
abvRange: true,
|
||||
ibuRange: true,
|
||||
},
|
||||
});
|
||||
})) as z.infer<typeof BeerStyleQueryResult>[];
|
||||
|
||||
return styles;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user