mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-23 00:41:35 -05:00
27 lines
719 B
Python
27 lines
719 B
Python
|
|
"""empty message
|
||
|
|
|
||
|
|
Revision ID: 0008_unique_service_to_key_name
|
||
|
|
Revises: 0007_change_to_api_keys
|
||
|
|
Create Date: 2016-01-21 16:14:51.773001
|
||
|
|
|
||
|
|
"""
|
||
|
|
|
||
|
|
# revision identifiers, used by Alembic.
|
||
|
|
revision = '0008_unique_service_to_key_name'
|
||
|
|
down_revision = '0007_change_to_api_keys'
|
||
|
|
|
||
|
|
from alembic import op
|
||
|
|
import sqlalchemy as sa
|
||
|
|
|
||
|
|
|
||
|
|
def upgrade():
|
||
|
|
### commands auto generated by Alembic - please adjust! ###
|
||
|
|
op.create_unique_constraint('uix_service_to_key_name', 'api_key', ['service_id', 'name'])
|
||
|
|
### end Alembic commands ###
|
||
|
|
|
||
|
|
|
||
|
|
def downgrade():
|
||
|
|
### commands auto generated by Alembic - please adjust! ###
|
||
|
|
op.drop_constraint('uix_service_to_key_name', 'api_key', type_='unique')
|
||
|
|
### end Alembic commands ###
|