37 lines
1.1 KiB
Python
37 lines
1.1 KiB
Python
"""empty message
|
|
|
|
Revision ID: 49aeda2e2b80
|
|
Revises: d46f10b87507
|
|
Create Date: 2023-04-14 14:38:38.730728
|
|
|
|
"""
|
|
from alembic import op
|
|
import sqlalchemy as sa
|
|
from sqlalchemy.dialects import mysql
|
|
|
|
# revision identifiers, used by Alembic.
|
|
revision = '49aeda2e2b80'
|
|
down_revision = 'd46f10b87507'
|
|
branch_labels = None
|
|
depends_on = None
|
|
|
|
|
|
def upgrade():
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
with op.batch_alter_table('appointment', schema=None) as batch_op:
|
|
batch_op.add_column(sa.Column('time', sa.Integer(), nullable=True))
|
|
batch_op.drop_column('is_morning')
|
|
batch_op.drop_column('is_afternoon')
|
|
|
|
# ### end Alembic commands ###
|
|
|
|
|
|
def downgrade():
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
with op.batch_alter_table('appointment', schema=None) as batch_op:
|
|
batch_op.add_column(sa.Column('is_afternoon', mysql.INTEGER(display_width=11), autoincrement=False, nullable=True))
|
|
batch_op.add_column(sa.Column('is_morning', mysql.INTEGER(display_width=11), autoincrement=False, nullable=True))
|
|
batch_op.drop_column('time')
|
|
|
|
# ### end Alembic commands ###
|