mirror of
https://github.com/simple-login/app.git
synced 2024-11-16 17:08:30 +01:00
48 lines
2.1 KiB
Python
48 lines
2.1 KiB
Python
|
"""empty message
|
||
|
|
||
|
Revision ID: 56c790ec8ab4
|
||
|
Revises: 623662ea0e7e
|
||
|
Create Date: 2020-12-02 17:32:23.332830
|
||
|
|
||
|
"""
|
||
|
import sqlalchemy_utils
|
||
|
from alembic import op
|
||
|
import sqlalchemy as sa
|
||
|
|
||
|
|
||
|
# revision identifiers, used by Alembic.
|
||
|
revision = '56c790ec8ab4'
|
||
|
down_revision = '623662ea0e7e'
|
||
|
branch_labels = None
|
||
|
depends_on = None
|
||
|
|
||
|
|
||
|
def upgrade():
|
||
|
# ### commands auto generated by Alembic - please adjust! ###
|
||
|
op.create_index(op.f('ix_alias_mailbox_id'), 'alias', ['mailbox_id'], unique=False)
|
||
|
op.create_index(op.f('ix_alias_user_id'), 'alias', ['user_id'], unique=False)
|
||
|
op.create_index(op.f('ix_alias_mailbox_alias_id'), 'alias_mailbox', ['alias_id'], unique=False)
|
||
|
op.create_index(op.f('ix_alias_mailbox_mailbox_id'), 'alias_mailbox', ['mailbox_id'], unique=False)
|
||
|
op.create_index(op.f('ix_contact_alias_id'), 'contact', ['alias_id'], unique=False)
|
||
|
op.create_index(op.f('ix_contact_user_id'), 'contact', ['user_id'], unique=False)
|
||
|
op.create_index(op.f('ix_email_log_contact_id'), 'email_log', ['contact_id'], unique=False)
|
||
|
op.create_index(op.f('ix_email_log_user_id'), 'email_log', ['user_id'], unique=False)
|
||
|
op.create_index(op.f('ix_mailbox_email'), 'mailbox', ['email'], unique=False)
|
||
|
op.create_index(op.f('ix_mailbox_user_id'), 'mailbox', ['user_id'], unique=False)
|
||
|
# ### end Alembic commands ###
|
||
|
|
||
|
|
||
|
def downgrade():
|
||
|
# ### commands auto generated by Alembic - please adjust! ###
|
||
|
op.drop_index(op.f('ix_mailbox_user_id'), table_name='mailbox')
|
||
|
op.drop_index(op.f('ix_mailbox_email'), table_name='mailbox')
|
||
|
op.drop_index(op.f('ix_email_log_user_id'), table_name='email_log')
|
||
|
op.drop_index(op.f('ix_email_log_contact_id'), table_name='email_log')
|
||
|
op.drop_index(op.f('ix_contact_user_id'), table_name='contact')
|
||
|
op.drop_index(op.f('ix_contact_alias_id'), table_name='contact')
|
||
|
op.drop_index(op.f('ix_alias_mailbox_mailbox_id'), table_name='alias_mailbox')
|
||
|
op.drop_index(op.f('ix_alias_mailbox_alias_id'), table_name='alias_mailbox')
|
||
|
op.drop_index(op.f('ix_alias_user_id'), table_name='alias')
|
||
|
op.drop_index(op.f('ix_alias_mailbox_id'), table_name='alias')
|
||
|
# ### end Alembic commands ###
|