Lizandro GuarnizoandClaude Sonnet 4.6 8a97b52eb7 feat(services): add POST /services/block endpoint for slot blocking
- BlockSlotDto: validates day (ISO date) and range1_hour1 (HH:MM)
- ServicesService.blockSlot(): finds professional by userId, checks for
  conflicts (any non-cancelled/denied service at that slot), then creates
  a service with status=self_booked using the professional's own user_id
- ServicesController: POST /services/block (JWT-guarded) wired to blockSlot

Existing PATCH /services/:id/status → cancelled handles unblocking since
VALID_TRANSITIONS already allows self_booked → cancelled.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-07-12 18:26:57 -05:00
2026-06-17 07:47:29 -05:00
S
Description
No description provided
688 KiB
Languages
TypeScript 96.7%
HTML 2%
PLpgSQL 0.9%
CSS 0.2%