"""criacao de tabela de pedidos

Revision ID: 3212268ed162
Revises: 7a556c9c1982
Create Date: 2018-07-15 21:56:24.867527

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '3212268ed162'
down_revision = '7a556c9c1982'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('order',
    sa.Column('id', sa.Integer(), nullable=False),
    sa.Column('item_name', sa.String(length=50), nullable=True),
    sa.Column('date', sa.String(length=50), nullable=True),
    sa.Column('orderer', sa.String(length=50), nullable=True),
    sa.Column('quantity', sa.Float(), nullable=True),
    sa.Column('addit_info', sa.String(length=140), nullable=True),
    sa.PrimaryKeyConstraint('id')
    )
    op.create_index(op.f('ix_order_item_name'), 'order', ['item_name'], unique=False)
    op.create_index(op.f('ix_order_orderer'), 'order', ['orderer'], unique=False)
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_index(op.f('ix_order_orderer'), table_name='order')
    op.drop_index(op.f('ix_order_item_name'), table_name='order')
    op.drop_table('order')
    # ### end Alembic commands ###
