Skip to content

Commit

Permalink
Add another migration
Browse files Browse the repository at this point in the history
  • Loading branch information
lulunac27a committed Jan 15, 2025
1 parent 94e7636 commit 0bd9cf5
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions migrations/versions/a5e285045629_create_xp_multipliers.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
"""Create XP multipliers
Revision ID: a5e285045629
Revises: 5d319985c5f2
Create Date: 2025-01-14 22:07:08.437280
"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = 'a5e285045629'
down_revision = '5d319985c5f2'
branch_labels = None
depends_on = None


def upgrade():
# ### commands auto generated by Alembic - please adjust! ###
with op.batch_alter_table('user', schema=None) as batch_op:
batch_op.add_column(sa.Column('multiplier', sa.Integer(), nullable=False, server_default='1'))
batch_op.add_column(sa.Column('last_item_clicked', sa.Integer(), nullable=False, server_default='0'))

# ### end Alembic commands ###


def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
with op.batch_alter_table('user', schema=None) as batch_op:
batch_op.drop_column('last_item_clicked')
batch_op.drop_column('multiplier')

# ### end Alembic commands ###

0 comments on commit 0bd9cf5

Please sign in to comment.