2b39a728a38f_add_branch_info_to_projects_groups.py 615 B

123456789101112131415161718192021222324252627282930
  1. """Add branch info to projects_groups
  2. Revision ID: 2b39a728a38f
  3. Revises: 318a4793b360
  4. Create Date: 2020-03-26 21:50:45.899760
  5. """
  6. from alembic import op
  7. import sqlalchemy as sa
  8. # revision identifiers, used by Alembic.
  9. revision = '2b39a728a38f'
  10. down_revision = '318a4793b360'
  11. def upgrade():
  12. ''' Add the column branches to the table projects_groups.
  13. '''
  14. op.add_column(
  15. 'projects_groups',
  16. sa.Column('branches', sa.Text, nullable=True)
  17. )
  18. def downgrade():
  19. ''' Drop the column branches from the table projects_groups.
  20. '''
  21. op.drop_column('projects_groups', 'branches')