Skip to content
This repository was archived by the owner on Jun 5, 2024. It is now read-only.

Commit

Permalink
add sequence to Top
Browse files Browse the repository at this point in the history
This is so that later we can show the tops in the
correct order
  • Loading branch information
k-nut committed Aug 31, 2017
1 parent 31e1946 commit 219622b
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
24 changes: 24 additions & 0 deletions migrations/versions/b2574371025b_add_sequence_to_top.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
"""add_sequence_to_top
Revision ID: b2574371025b
Revises: f31e2387c73a
Create Date: 2017-08-31 11:09:21.749110
"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = 'b2574371025b'
down_revision = 'f31e2387c73a'
branch_labels = None
depends_on = None


def upgrade():
op.add_column('tops', sa.Column('sequence', sa.Integer(), nullable=True))


def downgrade():
op.drop_column('tops', 'sequence')
1 change: 1 addition & 0 deletions models.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ class Top(db.Model):
category = db.Column(db.String)
duration = db.Column(db.Integer)
held_on = db.Column(db.Date)
sequence = db.Column(db.Integer)


@staticmethod
Expand Down

0 comments on commit 219622b

Please sign in to comment.