"""adding source plates to Artic submission Revision ID: fabf697c721d Revises: 70426df72f80 Create Date: 2024-03-06 11:01:34.794411 """ from alembic import op import sqlalchemy as sa # revision identifiers, used by Alembic. revision = 'fabf697c721d' down_revision = '70426df72f80' branch_labels = None depends_on = None def upgrade() -> None: # ### commands auto generated by Alembic - please adjust! ### # with op.batch_alter_table('_submissionsampleassociation', schema=None) as batch_op: # batch_op.create_unique_constraint("ssa_unique", ['id']) with op.batch_alter_table('_wastewaterartic', schema=None) as batch_op: batch_op.add_column(sa.Column('source_plates', sa.JSON(), nullable=True)) with op.batch_alter_table('_wastewaterassociation', schema=None) as batch_op: batch_op.alter_column('id', existing_type=sa.INTEGER(), nullable=False) # ### end Alembic commands ### def downgrade() -> None: # ### commands auto generated by Alembic - please adjust! ### with op.batch_alter_table('_wastewaterassociation', schema=None) as batch_op: batch_op.alter_column('id', existing_type=sa.INTEGER(), nullable=True) with op.batch_alter_table('_wastewaterartic', schema=None) as batch_op: batch_op.drop_column('source_plates') # with op.batch_alter_table('_submissionsampleassociation', schema=None) as batch_op: # batch_op.drop_constraint("ssa_unique", type_='unique') # ### end Alembic commands ###