Files
webmail-client/backend/migrations/versions/0004_thread_pinned.py
T
lukasandClaude Opus 4.8 a5ec0d21cb Initial commit: webmail client (M0/M1)
Three-pane webmail client.
- Backend: FastAPI + async SQLAlchemy + arq worker (Postgres/Redis), IMAP/SMTP
  sync, threading, search, drafts/outbox with undo, attachments, 2FA.
- Frontend: React 18 + Vite + TypeScript + TanStack Query + Tailwind; three-pane
  UI with rich-text composer, light/dark themes, resizable panels.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-07-17 23:20:34 +02:00

29 lines
687 B
Python

"""add threads.pinned
Denormalized "pinned" state for a thread (SPEC extension for the UI pin action):
true when any message in the thread carries the \\Flagged flag.
Revision ID: 0004
Revises: 0003
Create Date: 2026-07-17
"""
from __future__ import annotations
from collections.abc import Sequence
from alembic import op
revision: str = "0004"
down_revision: str | None = "0003"
branch_labels: str | Sequence[str] | None = None
depends_on: str | Sequence[str] | None = None
def upgrade() -> None:
op.execute("ALTER TABLE threads ADD COLUMN pinned boolean NOT NULL DEFAULT false")
def downgrade() -> None:
op.execute("ALTER TABLE threads DROP COLUMN IF EXISTS pinned")