feat: add createdAt and updatedAt fields to Article model and implement article pagination with new components

This commit is contained in:
2026-04-10 23:19:14 -03:00
parent 4b1bd056fc
commit 792627b0f0
7 changed files with 292 additions and 5 deletions

View File

@@ -0,0 +1,10 @@
import { z } from 'zod';
export const Pagination = <T extends z.ZodTypeAny>(itemSchema: T) =>
z.object({
data: z.array(itemSchema),
total: z.number(),
page: z.number(),
pageSize: z.number(),
totalPages: z.number(),
});