Add pagination, complete organization routes
This commit is contained in:
14
src/pagination.ts
Normal file
14
src/pagination.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import { z } from "zod";
|
||||
|
||||
export const pageMetadata = z.object({
|
||||
count: z.number(),
|
||||
page: z.number(),
|
||||
pageSize: z.number(),
|
||||
});
|
||||
|
||||
export const pageQueryParams = z.object({
|
||||
page: z.number().optional(),
|
||||
pageSize: z.number().optional(),
|
||||
});
|
||||
|
||||
export type PageQueryParams = z.infer<typeof pageQueryParams>;
|
||||
Reference in New Issue
Block a user