mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-11 07:42:20 -05:00
So we keep a record of who first uploaded a list it’s better to archive a list than completely delete it. The list in the database doesn’t contain any recipient info so this isn’t a change to what data we’re retaining. This means updating the endpoints that get contact lists to exclude ones that are archived.
27 lines
516 B
Python
27 lines
516 B
Python
"""
|
|
|
|
Revision ID: 0319_contact_list_archived
|
|
Revises: 0318_service_contact_list
|
|
Create Date: 2020-03-26 11:16:12.389524
|
|
|
|
"""
|
|
from alembic import op
|
|
import sqlalchemy as sa
|
|
|
|
revision = '0319_contact_list_archived'
|
|
down_revision = '0318_service_contact_list'
|
|
|
|
|
|
def upgrade():
|
|
op.add_column(
|
|
'service_contact_list',
|
|
sa.Column('archived', sa.Boolean(), nullable=False, server_default=sa.false()),
|
|
)
|
|
|
|
|
|
def downgrade():
|
|
op.drop_column(
|
|
'service_contact_list',
|
|
'archived',
|
|
)
|