Merge pull request #948 from dod-ccpo/non-unique-to
Do not enforce TO number uniqueness.
This commit is contained in:
commit
f46d1f80af
@ -0,0 +1,25 @@
|
|||||||
|
"""remove task_orders.number unique constraint
|
||||||
|
|
||||||
|
Revision ID: d966d7194f5c
|
||||||
|
Revises: 3d3c71b03e98
|
||||||
|
Create Date: 2019-06-19 12:53:39.502250
|
||||||
|
|
||||||
|
"""
|
||||||
|
from alembic import op
|
||||||
|
import sqlalchemy as sa
|
||||||
|
|
||||||
|
|
||||||
|
# revision identifiers, used by Alembic.
|
||||||
|
revision = 'd966d7194f5c'
|
||||||
|
down_revision = '3d3c71b03e98'
|
||||||
|
branch_labels = None
|
||||||
|
depends_on = None
|
||||||
|
|
||||||
|
|
||||||
|
def upgrade():
|
||||||
|
# ### commands auto generated by Alembic - please adjust! ###
|
||||||
|
op.drop_constraint('task_orders_number_key1', 'task_orders', type_='unique')
|
||||||
|
# ### end Alembic commands ###
|
||||||
|
|
||||||
|
|
||||||
|
# Not downgradeable; would have to determine what redundant TOs to delete
|
@ -40,7 +40,7 @@ class TaskOrder(Base, mixins.TimestampsMixin):
|
|||||||
|
|
||||||
pdf_attachment_id = Column(ForeignKey("attachments.id"))
|
pdf_attachment_id = Column(ForeignKey("attachments.id"))
|
||||||
_pdf = relationship("Attachment", foreign_keys=[pdf_attachment_id])
|
_pdf = relationship("Attachment", foreign_keys=[pdf_attachment_id])
|
||||||
number = Column(String, unique=True) # Task Order Number
|
number = Column(String) # Task Order Number
|
||||||
signer_dod_id = Column(String)
|
signer_dod_id = Column(String)
|
||||||
signed_at = Column(DateTime)
|
signed_at = Column(DateTime)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user