"""adding parent id index

Revision ID: f6a9c7e6694b
Revises: d10d998b796b
Create Date: 2018-03-29 09:25:30.500405

"""

# revision identifiers, used by Alembic.
revision = 'f6a9c7e6694b'
down_revision = 'd10d998b796b'
branch_labels = None
depends_on = None

from alembic import op
import sqlalchemy as sa


def upgrade(engine_name):
    globals()["upgrade_%s" % engine_name]()


def downgrade(engine_name):
    globals()["downgrade_%s" % engine_name]()





def upgrade_data_broker():
    ### commands auto generated by Alembic - please adjust! ###
    op.create_index(op.f('ix_fsrs_subcontract_parent_id'), 'fsrs_subcontract', ['parent_id'], unique=False)
    op.create_index(op.f('ix_fsrs_subgrant_parent_id'), 'fsrs_subgrant', ['parent_id'], unique=False)
    ### end Alembic commands ###


def downgrade_data_broker():
    ### commands auto generated by Alembic - please adjust! ###
    op.drop_index(op.f('ix_fsrs_subgrant_parent_id'), table_name='fsrs_subgrant')
    op.drop_index(op.f('ix_fsrs_subcontract_parent_id'), table_name='fsrs_subcontract')
    ### end Alembic commands ###

