feat: add pagination
This commit is contained in:
+20
@@ -154,6 +154,26 @@ export async function getChapterVerses(
|
||||
};
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Single verse
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
/**
|
||||
* Get a single verse by its exact coordinates.
|
||||
*/
|
||||
export async function getSingleVerse(
|
||||
book: string,
|
||||
division: string | null,
|
||||
chapter: number,
|
||||
verse: number,
|
||||
): Promise<VerseRecord | null> {
|
||||
const result = await prisma.verse.findFirst({
|
||||
where: { book, division, chapter, verse },
|
||||
});
|
||||
|
||||
return result as unknown as VerseRecord | null;
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Glossary
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user