"""Kick Feature table

Revision ID: <KEY>
Revises: <PASSWORD>
Create Date: 2019-03-14 11:08:18.396464

"""
import sqlalchemy as sa
from alembic import op

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


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_table('issue_features')
    op.drop_table('feature')
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('feature',
                    sa.Column('identifier', sa.TEXT(), autoincrement=False, nullable=False),
                    sa.PrimaryKeyConstraint('identifier', name='feature_pkey'),
                    postgresql_ignore_search_path=False
                    )
    op.create_table('issue_features',
                    sa.Column('issue_id', sa.INTEGER(), autoincrement=False, nullable=False),
                    sa.Column('feature_identifier', sa.TEXT(), autoincrement=False, nullable=False),
                    sa.ForeignKeyConstraint(['feature_identifier'], ['feature.identifier'],
                                            name='issue_features_feature_identifier_fkey'),
                    sa.ForeignKeyConstraint(['issue_id'], ['issues.uid'], name='issue_features_issue_id_fkey'),
                    sa.PrimaryKeyConstraint('issue_id', 'feature_identifier', name='issue_features_pkey')
                    )
    # ### end Alembic commands ###

"""Kick Feature table

Revision ID: <KEY>
Revises: <PASSWORD>
Create Date: 2019-03-14 11:08:18.396464

"""
import sqlalchemy as sa
from alembic import op

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


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_table('issue_features')
    op.drop_table('feature')
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('feature',
                    sa.Column('identifier', sa.TEXT(), autoincrement=False, nullable=False),
                    sa.PrimaryKeyConstraint('identifier', name='feature_pkey'),
                    postgresql_ignore_search_path=False
                    )
    op.create_table('issue_features',
                    sa.Column('issue_id', sa.INTEGER(), autoincrement=False, nullable=False),
                    sa.Column('feature_identifier', sa.TEXT(), autoincrement=False, nullable=False),
                    sa.ForeignKeyConstraint(['feature_identifier'], ['feature.identifier'],
                                            name='issue_features_feature_identifier_fkey'),
                    sa.ForeignKeyConstraint(['issue_id'], ['issues.uid'], name='issue_features_issue_id_fkey'),
                    sa.PrimaryKeyConstraint('issue_id', 'feature_identifier', name='issue_features_pkey')
                    )
    # ### end Alembic commands ###

Kick Feature table  Revision ID: <KEY> Revises: <PASSWORD> Create Date: 2019-03-14 11:08:18.396464 # 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 ###