21 lines
480 B
Python
21 lines
480 B
Python
"""Create durable OAuth, mapping, inbox, outbox, setup and audit storage."""
|
|
|
|
from alembic import op
|
|
|
|
from app.models import Base
|
|
|
|
revision = "0001_bitrix_local"
|
|
down_revision = None
|
|
branch_labels = None
|
|
depends_on = None
|
|
|
|
|
|
def upgrade() -> None:
|
|
bind = op.get_bind()
|
|
op.execute("CREATE SCHEMA IF NOT EXISTS bitrix_local")
|
|
Base.metadata.create_all(bind=bind, checkfirst=False)
|
|
|
|
|
|
def downgrade() -> None:
|
|
Base.metadata.drop_all(bind=op.get_bind(), checkfirst=True)
|