"""empty message

Revision ID: 0f5c44e5e07f
Revises: 3e33cc123e7e
Create Date: 2021-01-11 14:45:43.860755

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '0f5c44e5e07f'
down_revision = '3e33cc123e7e'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('cmf_card',
    sa.Column('cmf_author_id', sa.String(length=64), nullable=True),
    sa.Column('cmf_created_at', sa.TIMESTAMP(timezone=True), nullable=True),
    sa.Column('cmf_deleted', sa.Boolean(), nullable=False),
    sa.Column('cmf_locked_at', sa.TIMESTAMP(timezone=True), nullable=True),
    sa.Column('cmf_locked_by_id', sa.String(length=64), nullable=True),
    sa.Column('cmf_modified_at', sa.TIMESTAMP(timezone=True), nullable=True),
    sa.Column('cmf_modified_by_id', sa.String(length=64), nullable=True),
    sa.Column('cmf_owner_id', sa.String(length=64), nullable=True),
    sa.Column('cmf_version', sa.Integer(), nullable=True),
    sa.Column('cmf_viewed_at', sa.TIMESTAMP(timezone=True), nullable=True),
    sa.Column('code', sa.String(length=64), nullable=True),
    sa.Column('id', sa.String(length=64), nullable=False),
    sa.Column('name', sa.String(length=256), nullable=True),
    sa.Column('obj_alarm_date', sa.TIMESTAMP(timezone=True), nullable=True),
    sa.Column('obj_cmf_owner_id', sa.String(length=64), nullable=True),
    sa.Column('obj_cmf_owner_login', sa.String(length=64), nullable=True),
    sa.Column('obj_cmf_owner_name', sa.String(length=256), nullable=True),
    sa.Column('obj_code', sa.String(length=64), nullable=True),
    sa.Column('obj_deadline', sa.TIMESTAMP(timezone=True), nullable=True),
    sa.Column('obj_id', sa.String(length=64), nullable=True),
    sa.Column('obj_name', sa.String(length=256), nullable=True),
    sa.Column('obj_orderno', sa.Integer(), nullable=True),
    sa.Column('obj_plan_end_date', sa.TIMESTAMP(timezone=True), nullable=True),
    sa.Column('obj_plan_start_date', sa.TIMESTAMP(timezone=True), nullable=True),
    sa.Column('obj_priority', sa.String(length=32), nullable=True),
    sa.Column('obj_responsible_id', sa.String(length=64), nullable=True),
    sa.Column('obj_responsible_login', sa.String(length=64), nullable=True),
    sa.Column('obj_responsible_name', sa.String(length=256), nullable=True),
    sa.Column('obj_status_id', sa.String(length=64), nullable=True),
    sa.Column('obj_status_type', sa.String(length=32), nullable=True),
    sa.Column('obj_time_estimate', sa.Integer(), nullable=True),
    sa.Column('obj_url', sa.String(length=4096), nullable=True),
    sa.Column('orderno', sa.Integer(), nullable=True),
    sa.Column('person_id', sa.String(length=64), nullable=True),
    sa.Column('pinned', sa.Boolean(), nullable=True),
    sa.Column('status', sa.String(length=32), nullable=True),
    sa.Column('text', sa.TEXT(), nullable=True),
    sa.Column('type', sa.String(length=32), nullable=True),
    sa.ForeignKeyConstraint(['obj_status_id'], ['cmf_status.id'], ),
    sa.PrimaryKeyConstraint('id')
    )
    op.create_index(op.f('ix_cmf_card_cmf_author_id'), 'cmf_card', ['cmf_author_id'], unique=False)
    op.create_index(op.f('ix_cmf_card_cmf_created_at'), 'cmf_card', ['cmf_created_at'], unique=False)
    op.create_index(op.f('ix_cmf_card_cmf_deleted'), 'cmf_card', ['cmf_deleted'], unique=False)
    op.create_index(op.f('ix_cmf_card_cmf_locked_at'), 'cmf_card', ['cmf_locked_at'], unique=False)
    op.create_index(op.f('ix_cmf_card_cmf_locked_by_id'), 'cmf_card', ['cmf_locked_by_id'], unique=False)
    op.create_index(op.f('ix_cmf_card_cmf_modified_at'), 'cmf_card', ['cmf_modified_at'], unique=False)
    op.create_index(op.f('ix_cmf_card_cmf_modified_by_id'), 'cmf_card', ['cmf_modified_by_id'], unique=False)
    op.create_index(op.f('ix_cmf_card_cmf_owner_id'), 'cmf_card', ['cmf_owner_id'], unique=False)
    op.create_index(op.f('ix_cmf_card_cmf_version'), 'cmf_card', ['cmf_version'], unique=False)
    op.create_index(op.f('ix_cmf_card_cmf_viewed_at'), 'cmf_card', ['cmf_viewed_at'], unique=False)
    op.create_index(op.f('ix_cmf_card_code'), 'cmf_card', ['code'], unique=True)
    op.create_index(op.f('ix_cmf_card_name'), 'cmf_card', ['name'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_alarm_date'), 'cmf_card', ['obj_alarm_date'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_cmf_owner_id'), 'cmf_card', ['obj_cmf_owner_id'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_cmf_owner_login'), 'cmf_card', ['obj_cmf_owner_login'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_cmf_owner_name'), 'cmf_card', ['obj_cmf_owner_name'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_code'), 'cmf_card', ['obj_code'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_id'), 'cmf_card', ['obj_id'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_name'), 'cmf_card', ['obj_name'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_orderno'), 'cmf_card', ['obj_orderno'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_responsible_id'), 'cmf_card', ['obj_responsible_id'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_responsible_login'), 'cmf_card', ['obj_responsible_login'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_responsible_name'), 'cmf_card', ['obj_responsible_name'], unique=False)
    op.create_index(op.f('ix_cmf_card_obj_status_id'), 'cmf_card', ['obj_status_id'], unique=False)
    op.create_index(op.f('ix_cmf_card_orderno'), 'cmf_card', ['orderno'], unique=False)
    op.create_index(op.f('ix_cmf_card_person_id'), 'cmf_card', ['person_id'], unique=False)
    op.create_index(op.f('ix_cmf_card_pinned'), 'cmf_card', ['pinned'], unique=False)
    op.create_index(op.f('ix_cmf_card_status'), 'cmf_card', ['status'], unique=False)
    op.create_index(op.f('ix_cmf_card_type'), 'cmf_card', ['type'], unique=False)
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_index(op.f('ix_cmf_card_type'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_status'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_pinned'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_person_id'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_orderno'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_status_id'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_responsible_name'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_responsible_login'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_responsible_id'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_orderno'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_name'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_id'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_code'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_cmf_owner_name'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_cmf_owner_login'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_cmf_owner_id'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_obj_alarm_date'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_name'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_code'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_viewed_at'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_version'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_owner_id'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_modified_by_id'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_modified_at'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_locked_by_id'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_locked_at'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_deleted'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_created_at'), table_name='cmf_card')
    op.drop_index(op.f('ix_cmf_card_cmf_author_id'), table_name='cmf_card')
    op.drop_table('cmf_card')
    # ### end Alembic commands ###
