"""

Revision ID: 048bac60974f
Revises: 14b821135552
Create Date: 2025-11-13 15:31:56.901014

"""

from typing import Sequence, Union

from alembic import op
import sqlalchemy as sa
from sqlalchemy.dialects import sqlite

# revision identifiers, used by Alembic.
revision: str = "048bac60974f"
down_revision: Union[str, None] = "14b821135552"
branch_labels: Union[str, Sequence[str], None] = None
depends_on: Union[str, Sequence[str], None] = None


def upgrade() -> None:
    # ### commands auto generated by Alembic - please adjust! ###

    with op.batch_alter_table("portfolio", schema=None) as batch_op:
        batch_op.add_column(sa.Column("amount", sa.Float(), nullable=True))
        batch_op.drop_column("total_value")

    # ### end Alembic commands ###


def downgrade() -> None:
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table("portfolio", schema=None) as batch_op:
        batch_op.add_column(sa.Column("total_value", sa.FLOAT(), nullable=True))
        batch_op.drop_column("amount")

    # ### end Alembic commands ###
