2018-03-28 16:09:06 +01:00
|
|
|
"""
|
|
|
|
|
|
|
|
|
|
Revision ID: 0184_alter_primary_key_1
|
|
|
|
|
Revises: 0183_alter_primary_key
|
|
|
|
|
Create Date: 2018-03-28 16:05:54.648645
|
|
|
|
|
|
|
|
|
|
"""
|
2024-04-01 15:12:33 -07:00
|
|
|
|
2018-03-28 16:09:06 +01:00
|
|
|
import sqlalchemy as sa
|
2023-12-08 21:43:52 -05:00
|
|
|
from alembic import op
|
2018-03-28 16:09:06 +01:00
|
|
|
from sqlalchemy.dialects import postgresql
|
|
|
|
|
|
2023-08-29 14:54:30 -07:00
|
|
|
revision = "0184_alter_primary_key_1"
|
|
|
|
|
down_revision = "0183_alter_primary_key"
|
2018-03-28 16:09:06 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
def upgrade():
|
2023-08-29 14:54:30 -07:00
|
|
|
op.drop_constraint("ft_billing_pkey", "ft_billing", type_="primary")
|
|
|
|
|
|
|
|
|
|
op.create_primary_key(
|
|
|
|
|
"ft_billing_pkey",
|
|
|
|
|
"ft_billing",
|
|
|
|
|
[
|
|
|
|
|
"bst_date",
|
|
|
|
|
"template_id",
|
|
|
|
|
"service_id",
|
|
|
|
|
"rate_multiplier",
|
|
|
|
|
"provider",
|
|
|
|
|
"notification_type",
|
|
|
|
|
"international",
|
|
|
|
|
],
|
|
|
|
|
)
|
2018-03-28 16:09:06 +01:00
|
|
|
|
|
|
|
|
|
|
|
|
|
def downgrade():
|
2023-08-29 14:54:30 -07:00
|
|
|
op.drop_constraint("ft_billing_pkey", "ft_billing", type_="primary")
|
|
|
|
|
|
|
|
|
|
op.create_primary_key(
|
|
|
|
|
"ft_billing_pkey",
|
|
|
|
|
"ft_billing",
|
|
|
|
|
[
|
|
|
|
|
"bst_date",
|
|
|
|
|
"template_id",
|
|
|
|
|
"service_id",
|
|
|
|
|
"rate_multiplier",
|
|
|
|
|
"provider",
|
|
|
|
|
"notification_type",
|
|
|
|
|
],
|
|
|
|
|
)
|