feat: Add services, company documents, company timesheet export

- Add services table and CRUD endpoints (/api/services)
- Add company documents upload/download functionality
- Add company timesheet XLSX export endpoint
- Remove admin requirement from event routes (all authenticated users can manage events)
- Add service validators

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
richardtekula
2026-01-17 18:45:01 +01:00
parent b542d1d635
commit 514b6c8a92
13 changed files with 866 additions and 11 deletions

View File

@@ -63,6 +63,19 @@ router.post(
timeTrackingController.generateMonthlyTimesheet
);
// Generate company timesheet (XLSX)
router.post(
'/generate-company-timesheet',
validateBody(
z.object({
year: z.number().int().min(2000).max(2100),
month: z.number().int().min(1).max(12),
companyId: z.string().uuid('Neplatný formát company ID'),
})
),
timeTrackingController.generateCompanyTimesheet
);
// Get monthly statistics
router.get(
'/stats/monthly/:year/:month',