"""add notes column to entry and month_entry

Revision ID: ec804bdf366d
Revises: 03ebe3c07262
Create Date: 2026-04-17 12:47:41.533978

"""
from typing import Sequence, Union

from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision: str = 'ec804bdf366d'
down_revision: Union[str, Sequence[str], None] = '03ebe3c07262'
branch_labels: Union[str, Sequence[str], None] = None
depends_on: Union[str, Sequence[str], None] = None


def upgrade() -> None:
    """Upgrade schema."""
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table('entry', schema=None) as batch_op:
        batch_op.add_column(sa.Column('notes', sa.String(length=1024), nullable=True))

    with op.batch_alter_table('month_entry', schema=None) as batch_op:
        batch_op.add_column(sa.Column('notes', sa.String(length=1024), nullable=True))

    # ### end Alembic commands ###


def downgrade() -> None:
    """Downgrade schema."""
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table('month_entry', schema=None) as batch_op:
        batch_op.drop_column('notes')

    with op.batch_alter_table('entry', schema=None) as batch_op:
        batch_op.drop_column('notes')

    # ### end Alembic commands ###
