"""empty message

Revision ID: ef43027bfce7
Revises: 04fd7d87d175
Create Date: 2021-02-07 20:18:45.518948

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = 'ef43027bfce7'
down_revision = '04fd7d87d175'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('products', sa.Column('country_id', sa.Integer(), nullable=False))
    op.create_foreign_key(None, 'products', 'countries', ['country_id'], ['id'])
    op.drop_column('products', 'country_of_origin')
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('products', sa.Column('country_of_origin', sa.VARCHAR(), autoincrement=False, nullable=True))
    op.drop_constraint(None, 'products', type_='foreignkey')
    op.drop_column('products', 'country_id')
    # ### end Alembic commands ###
