From ef55d9bb24430610b60c1b77821307cd72c08c55 Mon Sep 17 00:00:00 2001 From: zwlucas Date: Sat, 25 Jul 2026 18:23:29 -0300 Subject: feat: upload of the project Signed-off-by: zwlucas --- api/src/modules/stats/stats.controller.ts | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 api/src/modules/stats/stats.controller.ts (limited to 'api/src/modules/stats/stats.controller.ts') diff --git a/api/src/modules/stats/stats.controller.ts b/api/src/modules/stats/stats.controller.ts new file mode 100644 index 0000000..520f692 --- /dev/null +++ b/api/src/modules/stats/stats.controller.ts @@ -0,0 +1,15 @@ +/** + * stats.controller.ts + * Lógica do dashboard. + */ + +import type { FastifyReply, FastifyRequest } from 'fastify'; +import { getTicketsStats } from './stats.repository.js'; + +export async function getStatsHandler( + request: FastifyRequest, + reply: FastifyReply, +) { + const stats = await getTicketsStats(request.server.db); + return reply.send(stats); +} -- cgit v1.2.3