"""empty message

Revision ID: 79ddc8b3910a
Revises: 0c948aa929c7
Create Date: 2018-09-29 17:40:57.767732

"""
from alembic import op
import sqlalchemy as sa
from sqlalchemy.dialects import mysql

# revision identifiers, used by Alembic.
revision = '79ddc8b3910a'
down_revision = '0c948aa929c7'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('article', sa.Column('pub_time', sa.DateTime(), nullable=True))
    op.create_index(op.f('ix_article_pub_time'), 'article', ['pub_time'], unique=False)
    op.drop_index('ix_article_time', table_name='article')
    op.drop_column('article', 'time')
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('article', sa.Column('time', mysql.DATETIME(), nullable=True))
    op.create_index('ix_article_time', 'article', ['time'], unique=False)
    op.drop_index(op.f('ix_article_pub_time'), table_name='article')
    op.drop_column('article', 'pub_time')
    # ### end Alembic commands ###
