"""empty message

Revision ID: 2de9749937e4
Revises: <PASSWORD>
Create Date: 2021-06-14 14:44:56.591378

"""
from alembic import op
import sqlalchemy as sa


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


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('postboard',
    sa.Column('id', sa.Integer(), autoincrement=True, nullable=False),
    sa.Column('sys_name', sa.String(length=255), nullable=False),
    sa.Column('show_name', sa.String(length=255), nullable=False),
    sa.Column('rule', sa.Text(), nullable=True),
    sa.PrimaryKeyConstraint('id'),
    sa.UniqueConstraint('show_name'),
    sa.UniqueConstraint('sys_name')
    )
    op.create_table('post',
    sa.Column('id', sa.Integer(), autoincrement=True, nullable=False),
    sa.Column('board_id', sa.Integer(), nullable=False),
    sa.Column('user_id', sa.Integer(), nullable=False),
    sa.Column('user_name', sa.String(length=255), nullable=False),
    sa.Column('title', sa.String(length=255), nullable=False),
    sa.Column('content', sa.String(length=255), nullable=False),
    sa.Column('create_time', sa.DateTime(), server_default=sa.text('NOW()'), nullable=True),
    sa.Column('like_count', sa.Integer(), server_default=sa.text('0'), nullable=False),
    sa.ForeignKeyConstraint(['board_id'], ['postboard.id'], ),
    sa.ForeignKeyConstraint(['user_id'], ['user.id'], ),
    sa.PrimaryKeyConstraint('id')
    )
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_table('post')
    op.drop_table('postboard')
    # ### end Alembic commands ###

"""empty message

Revision ID: 2de9749937e4
Revises: <PASSWORD>
Create Date: 2021-06-14 14:44:56.591378

"""
from alembic import op
import sqlalchemy as sa


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


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('postboard',
    sa.Column('id', sa.Integer(), autoincrement=True, nullable=False),
    sa.Column('sys_name', sa.String(length=255), nullable=False),
    sa.Column('show_name', sa.String(length=255), nullable=False),
    sa.Column('rule', sa.Text(), nullable=True),
    sa.PrimaryKeyConstraint('id'),
    sa.UniqueConstraint('show_name'),
    sa.UniqueConstraint('sys_name')
    )
    op.create_table('post',
    sa.Column('id', sa.Integer(), autoincrement=True, nullable=False),
    sa.Column('board_id', sa.Integer(), nullable=False),
    sa.Column('user_id', sa.Integer(), nullable=False),
    sa.Column('user_name', sa.String(length=255), nullable=False),
    sa.Column('title', sa.String(length=255), nullable=False),
    sa.Column('content', sa.String(length=255), nullable=False),
    sa.Column('create_time', sa.DateTime(), server_default=sa.text('NOW()'), nullable=True),
    sa.Column('like_count', sa.Integer(), server_default=sa.text('0'), nullable=False),
    sa.ForeignKeyConstraint(['board_id'], ['postboard.id'], ),
    sa.ForeignKeyConstraint(['user_id'], ['user.id'], ),
    sa.PrimaryKeyConstraint('id')
    )
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_table('post')
    op.drop_table('postboard')
    # ### end Alembic commands ###

empty message  Revision ID: 2de9749937e4 Revises: <PASSWORD> Create Date: 2021-06-14 14:44:56.591378 # 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 ###