20f2c14aa0b6_.py 744 Bytes
"""empty message

Revision ID: 20f2c14aa0b6
Revises: 
Create Date: 2021-03-08 15:14:27.758721

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '20f2c14aa0b6'
down_revision = None
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('user', sa.Column('login', sa.String(length=1000), nullable=True))
    op.create_unique_constraint(None, 'user', ['login'])
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_constraint(None, 'user', type_='unique')
    op.drop_column('user', 'login')
    # ### end Alembic commands ###