M24: implement privacy governance
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
"""add explicit customer anonymisation state
|
||||
|
||||
Revision ID: b913a72e8c14
|
||||
Revises: a81d0ce9f662
|
||||
"""
|
||||
|
||||
import sqlalchemy as sa
|
||||
|
||||
from alembic import op
|
||||
|
||||
revision = "b913a72e8c14"
|
||||
down_revision = "a81d0ce9f662"
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade() -> None:
|
||||
op.add_column("customers", sa.Column("anonymized_at", sa.DateTime(timezone=True)))
|
||||
op.create_index("ix_customers_anonymized_at", "customers", ["anonymized_at"])
|
||||
|
||||
|
||||
def downgrade() -> None:
|
||||
op.drop_index("ix_customers_anonymized_at", table_name="customers")
|
||||
op.drop_column("customers", "anonymized_at")
|
||||
Reference in New Issue
Block a user