"""empty message

Revision ID: 9845a330ed06
Revises: 4<PASSWORD>
Create Date: 2017-03-31 20:31:34.199580

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '9845a330ed06'
down_revision = '<PASSWORD>'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('likes',
    sa.Column('id', sa.Integer(), nullable=False),
    sa.Column('who', sa.String(), nullable=True),
    sa.PrimaryKeyConstraint('id')
    )
    op.create_table('like_protocol_association',
    sa.Column('like_id', sa.Integer(), nullable=False),
    sa.Column('protocol_id', sa.Integer(), nullable=False),
    sa.ForeignKeyConstraint(['like_id'], ['likes.id'], ),
    sa.ForeignKeyConstraint(['protocol_id'], ['protocols.id'], ),
    sa.PrimaryKeyConstraint('like_id', 'protocol_id')
    )
    op.create_table('like_todo_association',
    sa.Column('like_id', sa.Integer(), nullable=False),
    sa.Column('todo_id', sa.Integer(), nullable=False),
    sa.ForeignKeyConstraint(['like_id'], ['likes.id'], ),
    sa.ForeignKeyConstraint(['todo_id'], ['todos.id'], ),
    sa.PrimaryKeyConstraint('like_id', 'todo_id')
    )
    op.create_table('like_decision_association',
    sa.Column('like_id', sa.Integer(), nullable=False),
    sa.Column('decision_id', sa.Integer(), nullable=False),
    sa.ForeignKeyConstraint(['decision_id'], ['decisions.id'], ),
    sa.ForeignKeyConstraint(['like_id'], ['likes.id'], ),
    sa.PrimaryKeyConstraint('like_id', 'decision_id')
    )
    op.create_table('like_top_association',
    sa.Column('like_id', sa.Integer(), nullable=False),
    sa.Column('top_id', sa.Integer(), nullable=False),
    sa.ForeignKeyConstraint(['like_id'], ['likes.id'], ),
    sa.ForeignKeyConstraint(['top_id'], ['tops.id'], ),
    sa.PrimaryKeyConstraint('like_id', 'top_id')
    )
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_table('like_top_association')
    op.drop_table('like_decision_association')
    op.drop_table('like_todo_association')
    op.drop_table('like_protocol_association')
    op.drop_table('likes')
    # ### end Alembic commands ###

"""empty message

Revision ID: 9845a330ed06
Revises: 4<PASSWORD>
Create Date: 2017-03-31 20:31:34.199580

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '9845a330ed06'
down_revision = '<PASSWORD>'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('likes',
    sa.Column('id', sa.Integer(), nullable=False),
    sa.Column('who', sa.String(), nullable=True),
    sa.PrimaryKeyConstraint('id')
    )
    op.create_table('like_protocol_association',
    sa.Column('like_id', sa.Integer(), nullable=False),
    sa.Column('protocol_id', sa.Integer(), nullable=False),
    sa.ForeignKeyConstraint(['like_id'], ['likes.id'], ),
    sa.ForeignKeyConstraint(['protocol_id'], ['protocols.id'], ),
    sa.PrimaryKeyConstraint('like_id', 'protocol_id')
    )
    op.create_table('like_todo_association',
    sa.Column('like_id', sa.Integer(), nullable=False),
    sa.Column('todo_id', sa.Integer(), nullable=False),
    sa.ForeignKeyConstraint(['like_id'], ['likes.id'], ),
    sa.ForeignKeyConstraint(['todo_id'], ['todos.id'], ),
    sa.PrimaryKeyConstraint('like_id', 'todo_id')
    )
    op.create_table('like_decision_association',
    sa.Column('like_id', sa.Integer(), nullable=False),
    sa.Column('decision_id', sa.Integer(), nullable=False),
    sa.ForeignKeyConstraint(['decision_id'], ['decisions.id'], ),
    sa.ForeignKeyConstraint(['like_id'], ['likes.id'], ),
    sa.PrimaryKeyConstraint('like_id', 'decision_id')
    )
    op.create_table('like_top_association',
    sa.Column('like_id', sa.Integer(), nullable=False),
    sa.Column('top_id', sa.Integer(), nullable=False),
    sa.ForeignKeyConstraint(['like_id'], ['likes.id'], ),
    sa.ForeignKeyConstraint(['top_id'], ['tops.id'], ),
    sa.PrimaryKeyConstraint('like_id', 'top_id')
    )
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_table('like_top_association')
    op.drop_table('like_decision_association')
    op.drop_table('like_todo_association')
    op.drop_table('like_protocol_association')
    op.drop_table('likes')
    # ### end Alembic commands ###

empty message  Revision ID: 9845a330ed06 Revises: 4<PASSWORD> Create Date: 2017-03-31 20:31:34.199580 # revision identifiers, used by Alembic. # ### commands auto generated by Alembic - please adjust! ### # ### end Alembic commands ### # ### commands auto generated by Alembic - please adjust! ### # ### end Alembic commands ###