misp-modules/website/migrations/versions/c0e243696052_.py

35 lines
918 B
Python

"""empty message
Revision ID: c0e243696052
Revises: 1d38ae8361a7
Create Date: 2024-02-07 11:59:20.615266
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = 'c0e243696052'
down_revision = '1d38ae8361a7'
branch_labels = None
depends_on = None
def upgrade():
# ### commands auto generated by Alembic - please adjust! ###
with op.batch_alter_table('session_db', schema=None) as batch_op:
batch_op.add_column(sa.Column('query_enter', sa.String(), nullable=True))
batch_op.drop_column('query')
# ### end Alembic commands ###
def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
with op.batch_alter_table('session_db', schema=None) as batch_op:
batch_op.add_column(sa.Column('query', sa.VARCHAR(), nullable=True))
batch_op.drop_column('query_enter')
# ### end Alembic commands ###