update Implement standardized documentation for all database modules, including purpose, rules, and requirements for each CRUD operation; refactor existing comments to follow new documentation standard ```
19 lines
420 B
TypeScript
19 lines
420 B
TypeScript
//
|
|
// PURPOSE:
|
|
// Get total count of all QuizLPQuestions records
|
|
// REQ0006
|
|
//
|
|
// RULES:
|
|
// returns 0 on error
|
|
// contain definition to collection only
|
|
//
|
|
|
|
import { COL_QUIZ_LP_QUESTIONS } from '@/constants';
|
|
|
|
import { pb } from '@/lib/pb';
|
|
|
|
export default async function GetAllCount(): Promise<number> {
|
|
const { totalItems: count } = await pb.collection(COL_QUIZ_LP_QUESTIONS).getList(1, 9999, {});
|
|
return count;
|
|
}
|