<reponame>AnvarGaliullin/LSP<gh_stars>0
"""empty message

Revision ID: 0663c0c01436
Revises: 2adb4829e960
Create Date: 2019-11-30 02:38:58.104299

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '0663c0c01436'
down_revision = '2adb4829e960'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('UserSocial_Pages',
    sa.Column('id', sa.Integer(), nullable=False),
    sa.Column('user_id', sa.Integer(), nullable=False),
    sa.Column('vk', sa.String(length=100), nullable=True),
    sa.Column('facebook', sa.String(length=100), nullable=True),
    sa.Column('linked_in', sa.String(length=100), nullable=True),
    sa.Column('instagram', sa.String(length=100), nullable=True),
    sa.ForeignKeyConstraint(['user_id'], ['users.id'], ),
    sa.PrimaryKeyConstraint('id'),
    sa.UniqueConstraint('user_id')
    )
    op.drop_table('UserSocialPages')
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('UserSocialPages',
    sa.Column('id', sa.INTEGER(), server_default=sa.text('nextval(\'"UserSocialPages_id_seq"\'::regclass)'), autoincrement=True, nullable=False),
    sa.Column('user_id', sa.INTEGER(), autoincrement=False, nullable=False),
    sa.Column('vk', sa.VARCHAR(length=100), autoincrement=False, nullable=True),
    sa.Column('facebook', sa.VARCHAR(length=100), autoincrement=False, nullable=True),
    sa.Column('linked_in', sa.VARCHAR(length=100), autoincrement=False, nullable=True),
    sa.Column('instagram', sa.VARCHAR(length=100), autoincrement=False, nullable=True),
    sa.ForeignKeyConstraint(['user_id'], ['users.id'], name='UserSocialPages_user_id_fkey'),
    sa.PrimaryKeyConstraint('id', name='UserSocialPages_pkey'),
    sa.UniqueConstraint('user_id', name='UserSocialPages_user_id_key')
    )
    op.drop_table('UserSocial_Pages')
    # ### end Alembic commands ###
