Files
notifications-api/migrations/versions/0370_remove_reach.py
Steven Reilly ff4190a8eb Remove letters-related code (#175)
This deletes a big ol' chunk of code related to letters. It's not everything—there are still a few things that might be tied to sms/email—but it's the the heart of letters function. SMS and email function should be untouched by this.

Areas affected:

- Things obviously about letters
- PDF tasks, used for precompiling letters
- Virus scanning, used for those PDFs
- FTP, used to send letters to the printer
- Postage stuff
2023-03-02 20:20:31 -05:00

53 lines
959 B
Python

"""
Revision ID: 0370_remove_reach
Revises: 0369_update_sms_rates
Create Date: 2022-04-27 16:00:00
"""
import itertools
import uuid
from datetime import datetime
from alembic import op
from sqlalchemy.sql import text
revision = '0370_remove_reach'
down_revision = '0369_update_sms_rates'
def upgrade():
conn = op.get_bind()
conn.execute("DELETE FROM provider_details WHERE identifier = 'reach'")
def downgrade():
conn = op.get_bind()
conn.execute(
"""
INSERT INTO provider_details (
id,
display_name,
identifier,
priority,
notification_type,
active,
version,
created_by_id
)
VALUES (
'{}',
'Reach',
'reach',
0,
'sms',
false,
1,
null
)
""".format(
str(uuid.uuid4()),
)
)