"""type

迁移 ID: a61ec0d70761
父迁移: 5d80e832962b
创建时间: 2025-08-24 21:29:52.384423

"""

from __future__ import annotations

from collections.abc import Sequence

import sqlalchemy as sa
from alembic import op

revision: str = "a61ec0d70761"
down_revision: str | Sequence[str] | None = "5d80e832962b"
branch_labels: str | Sequence[str] | None = None
depends_on: str | Sequence[str] | None = None


def upgrade(name: str = "") -> None:
    if name:
        return
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table("amrita_daily_usage", schema=None) as batch_op:
        batch_op.alter_column(
            "id",
            existing_type=sa.BIGINT(),
            type_=sa.Integer(),
            existing_nullable=False,
            autoincrement=True,
        )

    # ### end Alembic commands ###


def downgrade(name: str = "") -> None:
    if name:
        return
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table("amrita_daily_usage", schema=None) as batch_op:
        batch_op.alter_column(
            "id",
            existing_type=sa.Integer(),
            type_=sa.BIGINT(),
            existing_nullable=False,
            autoincrement=True,
        )

    # ### end Alembic commands ###
