Commit Graph
16 Commits
Author SHA1 Message Date
Leon TonhäuserandClaude Opus 5.5 2775b406bf Release 2.3.0: calendar categories, reservations, month view, dashboard
- Admin-managed event categories (name + one of Sakani's 8 calendar
  colors) at /admin/kalender/kategorien; events pick a category.
- Calendar as Sakani MonthCalendar with a German header and a color
  legend, for editorials and admins.
- "Zu meinen Alben hinzufügen" replaces RSVP: grants the event album at
  once when it exists, otherwise reserves it; the auto-rule scheduler
  grants pending reservations once the album appears. Editorials see when
  an auto rule already covers the event. event_responses is dropped.
- New admin dashboard: to-dos, next events, 30-day figures, activity.
- Photo grid reads left to right in uniform 3:2 tiles.
- Release notes 2.3.0 seeded (migration 0008).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-30 23:45:59 +01:00
Leon TonhäuserandClaude Opus 5.5 4fb6f2d373 Ship all Drizzle migrations in the Docker image
.dockerignore whitelisted only 0000 and 0001, so 0002-0005 were missing
from the migrate image while the journal listed them. Allow
drizzle/*.sql instead of single file names.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-30 22:50:07 +01:00
Leon TonhäuserandClaude Opus 5.5 71110208a9 Release 2.2.1: quarterly billing and Sakani form polish
- Billing is always quarterly: the billing page opens the current
  quarter, the month view is gone, old ?month= links land in their
  quarter and invalid quarters no longer throw.
- Calendar and release-note forms and the RSVP buttons use Sakani
  components (Card, Input, Textarea, FormSelect, Button, Alert).
- Sidebar logo stays visible in dark mode (Sakani's logo tile is light).
- Release notes for 2.2.1 seeded via custom migration 0004; popup
  version bumped.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-30 22:38:32 +01:00
Leon Tonhäuser 7204dd6b60 feat: v2.2 batch (calendar, self-service, sort, description, filename search, stats, collab, invoice) on pre-redesign base 2026-11-30 21:20:13 +01:00
Leon Tonhäuser 453bece72c docs: preserve deployment and migration notes 2026-11-30 16:42:10 +01:00
Leon Tonhäuser 2a5a2f3815 feat: show outstanding unbilled amount next to net price in editorial overview
Grouped SUM over usages with billingStatus open/reopened (same selectable
set as the billing page; voided excluded) per editorial, rendered as an
amber-highlighted 'Offen' suffix in each card footer.
2026-09-01 17:23:38 +02:00
Leon Tonhäuser 0931ffc777 feat: add admin albums tab with access overview and bulk grants
New /admin/alben page: all Immich albums with per-album editorial grant
chips (link + one-click revoke) and a bulk-grant form (multiple albums x
multiple editorials, select-all, search). bulkGrantAlbums validates album
existence once via listAlbums, skips already-active pairs, and commits
each pair in its own transaction with full audit attribution.
2026-09-01 17:17:02 +02:00
Leon Tonhäuser 0b65fbba16 fix: rebuild migration history as baseline so migrate works on prod
Squash the 13 historical migrations into one generated baseline whose
journal entry reuses the original 0000 timestamp: the migrator skips it
on every existing database (prod journal stuck at 0006) and applies it
only on fresh ones. Parity with the old chain verified via pg_dump diff
plus fresh/existing/prod-simulated drizzle-kit migrate runs. Historical
files move to drizzle-history/pre-squash-2026-08/ for integration tests
that exercise legacy migration behavior.

Also repair db tests that already failed before this change:
- raw SQL targeted users, but the table has always been "user"
- membership recheck mocked legacy getAsset.albums instead of searchPhotos
- audit rollback assertion walks drizzle's wrapped error cause chain
- keyset index probe pinned to NULLS LAST ordering, removing a planner
  cost tie-break that flipped with index creation order
2026-08-25 11:56:52 +02:00
Leon Tonhäuser 2949149170 docs: record prod migration-journal debt and two_factor field contract 2026-08-25 03:32:52 +02:00
Leon Tonhäuser 0d939593c8 feat: enforce admin 2FA, step-up auth, stronger password policy
Implements OWASP audit recommendations P1-P3:

P1 - Two-factor authentication (TOTP) mandatory for admins:
- better-auth twoFactor plugin; new two_factor table + user flag
  (migration 0010, MUST run before deploying the app)
- requireAdmin throws TWO_FACTOR_REQUIRED without a finished setup;
  pages redirect to the new /zwei-faktor wizard which uses a weak
  guard (allowWithoutTwoFactor) so admins can never lock themselves
  out. Wizard lives outside /admin to avoid layout redirect loops.
- login flow handles twoFactorRedirect and asks for the TOTP code;
  backup codes are shown once during enablement

P2 - Step-up for destructive operations (ASVS 2.5.4):
- hardDeleteEditorialAction and resetUsageDataAction reject sessions
  older than 15 minutes (SESSION_STALE) with actionable German
  messages instead of throwing opaque digests

P3 - Password policy (NIST 800-63B):
- minimum length raised from 8 to 12 plus common-password denylist,
  enforced for registration AND reset/change via a before-hook
2026-08-25 02:30:58 +02:00
Leon Tonhäuser dd60fd6ee6 feat: auto-assign new Immich albums via keyword rules
Auto-assignment rules were only applied when an admin clicked
"Regeln jetzt anwenden". New albums created in Immich therefore
never reached editorials automatically.

- applyAllRules() syncs every active editorial's keywords against the
  full album list in one pass and grants matches as system actor
- in-process scheduler (src/instrumentation.ts) runs the sync every
  AUTO_RULE_SYNC_INTERVAL_SECONDS (default 120s)
- POST /api/cron/album-sync allows external triggers via CRON_SECRET
- overlapping sync runs coalesce to avoid duplicate grants/emails
2026-08-25 01:05:04 +02:00
Leon TonhäuserandClaude 21d41c7017 docs: record archiver v8 export-is-a-class gotcha in AI_MEMORY
Co-Authored-By: Claude <noreply@anthropic.com>
2026-08-11 14:48:14 +02:00
Leon TonhäuserandClaude ca5f79e193 docs: correct AI_MEMORY album-membership guidance for current Immich
getAlbum no longer returns assets on current Immich (AlbumService.get uses
{ withAssets: false }), so the old "getAlbum + iterate album.assets" best
practice is wrong and caused the download-404 bug. Document the
search/metadata id+albumIds membership check now in use.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-08-11 14:26:16 +02:00
Leon Tonhäuser b81cd7c3e2 docs: update AI Memory with watermark, responsive emails and image styling quirks 2026-08-11 13:14:45 +02:00
Leon Tonhäuser ed957e6559 docs: update AI memory with recent fixes and architectural knowledge 2026-08-11 12:52:23 +02:00
Leon Tonhäuser 4667615ed0 feat: implement hard delete, email notifications, watermark, and fix bulk download 2026-08-11 12:28:39 +02:00