contentdb/migrations/versions/06d23947e7ef_.py

36 lines
926 B
Python

"""empty message
Revision ID: 06d23947e7ef
Revises: 5d7233cf8a00
Create Date: 2020-12-05 20:30:12.166357
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '06d23947e7ef'
down_revision = '5d7233cf8a00'
branch_labels = None
depends_on = None
def upgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.create_table('email_subscription',
sa.Column('id', sa.Integer(), nullable=False),
sa.Column('email', sa.String(length=100), nullable=False),
sa.Column('blacklisted', sa.Boolean(), nullable=False),
sa.Column('token', sa.String(length=32), nullable=True),
sa.PrimaryKeyConstraint('id'),
sa.UniqueConstraint('email')
)
# ### end Alembic commands ###
def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.drop_table('email_subscription')
# ### end Alembic commands ###