- POST /api/public/bookings: creates new slot instead of reusing
- POST /api/bookings/manual: creates new slot instead of reusing
- POST /api/slots (with customer): creates new slot for the booking
- POST /api/public/book-slot: already fixed previously
- All 4 endpoints now produce parallel slot blocks
- Backend: dailyCapacities includes ALL dates (blocked + slot dates)
- Admin calendar slot blocks:
- Title bar with slot name
- Booking rows only for existing bookings/blocked slots
- No 'Frei' sub-blocks shown
- Customer calendar unchanged (still shows Frei/Belegt/Ausstehend/Bestätigt)
- Capacity header (± controls) now visible for all week days
- New daily_capacity table with date-based overrides
- Default = COUNT of it_support users (dynamic)
- Backend: GET/PUT/DELETE /api/capacity/:date
- Backend: POST /api/capacity/batch for multiple dates
- Slots API returns dailyCapacities map alongside slots
- Public API: new slots get day_capacity as max_bookings
- WeekCalendar header: − N + ✕ capacity controls per day
- SlotsPage: capacity mutations + passes to calendar
- WeekCalendar slot blocks use day capacity for maxB
- Copy booking link buttons in Slot panel and Bookings list
- Customer history modal from Slot panel (📋 icon)
- Backend: GET /api/bookings supports customer_email filter
- Backend: new GET/PUT /api/email-templates
- DB: email_templates table with 3 default templates
- Email transporter reads templates from DB with {{var}} placeholders
- Settings: new E-Mail tab with template editor + preview
- Placeholders: app_name, customer_name, slot_title, slot_date, start_time, end_time, booking_url
- New server/src/seed.ts creates admin user via auth API if not exists
- Called from index.ts after app.listen
- Configurable via env: ADMIN_EMAIL, ADMIN_PASSWORD, ADMIN_NAME, ADMIN_ROLE
- Defaults match existing test account (admin@test.de / Test1234!)
- Settings table already seeded via schema.sql INSERT OR IGNORE
- DB: bookings table gets cc_email and notes columns (with migration)
- Backend: all booking endpoints accept cc_email and notes
- Customer booking form: CC email field + notes textarea
- Email templates updated to show sender from CC config
- BookingsPage: click booking -> navigates to /dashboard?slot_id=X&date=Y
- SlotsPage: reads query params, navigates to correct week, auto-selects slot
- SettingsPage: tabbed UI (Allgemein + SMTP) with separate field groups
- SMTP settings stored in DB settings table (smtp_host, smtp_port, etc.)
- Email transporter reads from DB settings with env var fallback
- Public API: no longer filters blocked slots out, includes is_day_blocked flag
- Public API response: includes blockedDates array for UI
- Customer calendar: blocked slots show 'Blockiert' with red dot
- Admin calendar: uses isSlotOrDayBlocked for styling
- SlotData interface: added is_day_blocked field
- New blocked_dates table (date, reason, created_by)
- Backend: GET/POST/DELETE /api/blocked-dates routes
- Backend: public API filters out slots on blocked dates
- Backend: slots API returns blockedDates alongside slots
- Frontend: blocked days shown with red striped pattern in calendar
- Frontend: blocked day header shows red background + diagonal stripes
- Frontend: 'Tag blocken' modal with reason input
- Frontend: blocked days summary bar with quick unblock (✕)
- Schema: is_blocked column for slots
- Backend: POST /api/bookings/manual for IT/AM to enter customers manually
- Backend: PUT /api/slots/:id/block toggle
- Backend: public API filters out blocked slots
- Frontend SlotForm: block toggle checkbox
- Frontend SlotsPage: detail panel with block/entblock + customer entry form
- Frontend: blocked slots shown with red badge in calendar
- is_blocked in types, PublicSlot updated
- Admin calendar: each capacity unit shown as sub-block with customer name
- Customer calendar: sub-blocks show Frei/Belegt/Ausstehend/Bestätigt per slot
- SlotsPage: detail panel right side with booking list + confirm/cancel
- Backend returns bookings array per slot via GET /api/slots
- Password field: toggle visibility with 👁️/🙈 icon
- Customer calendar: slots colored by booking status
- Amber = ausstehend (pending)
- Green = bestätigt (confirmed)
- Grey = storniert (cancelled)
- Blue = frei (available)
- Red = von anderen belegt
- Public API: returns myStatus per slot for logged-in customer token
- Form fields persist when switching time slots (no reset)
- New POST /api/public/book-slot endpoint
- Creates slot + booking in one step if no slot exists
- Reuses existing slot if one exists at that time
- Customer mode: cell click opens booking form
- Backend validates capacity, auto-calculates end_time
- Admin slot blocks still clickable for editing