Allow superusers to disable user accounts

This commit is contained in:
Joseph Schorr 2015-05-11 17:13:42 -04:00
parent 442cbed087
commit dc5af7496c
19 changed files with 291 additions and 37 deletions

View file

@ -0,0 +1,26 @@
"""Add enabled column to the user system
Revision ID: 154f2befdfbe
Revises: 41f4587c84ae
Create Date: 2015-05-11 17:02:43.507847
"""
# revision identifiers, used by Alembic.
revision = '154f2befdfbe'
down_revision = '41f4587c84ae'
from alembic import op
import sqlalchemy as sa
def upgrade(tables):
### commands auto generated by Alembic - please adjust! ###
op.add_column('user', sa.Column('enabled', sa.Boolean(), nullable=False, default=True))
### end Alembic commands ###
def downgrade(tables):
### commands auto generated by Alembic - please adjust! ###
op.drop_column('user', 'enabled')
### end Alembic commands ###