Improved generic submissions to replace viral culture addition.

This commit is contained in:
lwark
2024-09-06 11:22:05 -05:00
parent bcb6e15449
commit 7f6a476cd7
11 changed files with 166 additions and 155 deletions

View File

@@ -24,7 +24,7 @@ def upgrade() -> None:
sa.PrimaryKeyConstraint('id')
)
# with op.batch_alter_table('_process', schema=None) as batch_op:
# batch_op.create_unique_constraint("process_uni", ['name'])
# batch_op.create_unique_constraint("process_uni", ['sub_type'])
#
# with op.batch_alter_table('_submissionsampleassociation', schema=None) as batch_op:
# batch_op.create_unique_constraint("subsamp_uni", ['id'])
@@ -40,17 +40,17 @@ def upgrade() -> None:
def downgrade() -> None:
# ### commands auto generated by Alembic - please adjust! ###
with op.batch_alter_table('_wastewaterarticassociation', schema=None) as batch_op:
batch_op.alter_column('source_plate',
existing_type=sa.String(length=32),
type_=sa.VARCHAR(length=16),
existing_nullable=True)
with op.batch_alter_table('_submissionsampleassociation', schema=None) as batch_op:
batch_op.drop_constraint("subsamp_uni", type_='unique')
with op.batch_alter_table('_process', schema=None) as batch_op:
batch_op.drop_constraint("process_uni", type_='unique')
# with op.batch_alter_table('_wastewaterarticassociation', schema=None) as batch_op:
# batch_op.alter_column('source_plate',
# existing_type=sa.String(length=32),
# type_=sa.VARCHAR(length=16),
# existing_nullable=True)
#
# with op.batch_alter_table('_submissionsampleassociation', schema=None) as batch_op:
# batch_op.drop_constraint("subsamp_uni", type_='unique')
#
# with op.batch_alter_table('_process', schema=None) as batch_op:
# batch_op.drop_constraint("process_uni", type_='unique')
op.drop_table('_viralculture')
# ### end Alembic commands ###