feat: persist task lane across submits and session reloads
Task lane questions/actions are now saved to a pending_task_lane JSONB column on ai_sessions, restoring them on session switch or page reload. Partial submit no longer force-clears the lane — the AI response controls what stays. Also removes redundant "New Session" button from the sidebar (dashboard already provides this). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
30
backend/alembic/versions/fc01_add_pending_task_lane.py
Normal file
30
backend/alembic/versions/fc01_add_pending_task_lane.py
Normal file
@@ -0,0 +1,30 @@
|
||||
"""add pending_task_lane to ai_sessions
|
||||
|
||||
Revision ID: fc01a1b2c3d4
|
||||
Revises: fb1481317ff6
|
||||
Create Date: 2026-03-27
|
||||
"""
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
from sqlalchemy.dialects.postgresql import JSONB
|
||||
|
||||
revision = "fc01a1b2c3d4"
|
||||
down_revision = "fb1481317ff6"
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
op.add_column(
|
||||
"ai_sessions",
|
||||
sa.Column(
|
||||
"pending_task_lane",
|
||||
JSONB,
|
||||
nullable=True,
|
||||
comment="Current task lane state: {questions: [...], actions: [...]}",
|
||||
),
|
||||
)
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
op.drop_column("ai_sessions", "pending_task_lane")
|
||||
Reference in New Issue
Block a user