FitTrackee/fittrackee/migrations/versions/38_965bdd65109f_add_calisthenics.py

35 lines
613 B
Python
Raw Permalink Normal View History

2024-02-07 14:59:30 +01:00
"""add calisthenics sport
Revision ID: 965bdd65109f
Revises: 4229a42eff8b
Create Date: 2024-02-06 21:51:15.000016
"""
from alembic import op
import sqlalchemy as sa
# revision identifiers, used by Alembic.
revision = '965bdd65109f'
down_revision = '4229a42eff8b'
branch_labels = None
depends_on = None
def upgrade():
op.execute(
"""
INSERT INTO sports (label, is_active, stopped_speed_threshold)
VALUES ('Calisthenics', True, 0.1)
"""
)
def downgrade():
op.execute(
"""
DELETE FROM sports
WHERE label = 'Calisthenics';
"""
)