"""Changed tilled id to payrix merchant model

Revision ID: aa2821d146c2
Revises: a5020d338f05
Create Date: 2025-12-18 01:52:43.280906

"""
from typing import Sequence, Union

from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision: str = 'aa2821d146c2'
down_revision: Union[str, Sequence[str], None] = 'a5020d338f05'
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! ###
    op.add_column('merchants', sa.Column('payrix_status', sa.String(length=30), nullable=True))
    op.add_column('merchants', sa.Column('payrix_account_id', sa.Text(), nullable=True))
    op.drop_column('merchants', 'tilled_status')
    op.drop_column('merchants', 'tilled_account_id')
    op.drop_column('merchants', 'tilled_customer_id')
    # ### end Alembic commands ###


def downgrade() -> None:
    """Downgrade schema."""
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('merchants', sa.Column('tilled_customer_id', sa.TEXT(), autoincrement=False, nullable=True))
    op.add_column('merchants', sa.Column('tilled_account_id', sa.TEXT(), autoincrement=False, nullable=True))
    op.add_column('merchants', sa.Column('tilled_status', sa.VARCHAR(length=30), autoincrement=False, nullable=True))
    op.drop_column('merchants', 'payrix_account_id')
    op.drop_column('merchants', 'payrix_status')
    # ### end Alembic commands ###
