add Mailbox.disable_pgp column
This commit is contained in:
parent
ab861b3624
commit
5997e5b5b5
|
@ -1663,6 +1663,9 @@ class Mailbox(db.Model, ModelMixin):
|
|||
|
||||
pgp_public_key = db.Column(db.Text, nullable=True)
|
||||
pgp_finger_print = db.Column(db.String(512), nullable=True)
|
||||
disable_pgp = db.Column(
|
||||
db.Boolean, default=False, nullable=False, server_default="0"
|
||||
)
|
||||
|
||||
# incremented when a check is failed on the mailbox
|
||||
# alert when the number exceeds a threshold
|
||||
|
|
|
@ -0,0 +1,29 @@
|
|||
"""empty message
|
||||
|
||||
Revision ID: d1edb3cadec8
|
||||
Revises: ac41029fb329
|
||||
Create Date: 2020-11-24 11:14:24.208867
|
||||
|
||||
"""
|
||||
import sqlalchemy_utils
|
||||
from alembic import op
|
||||
import sqlalchemy as sa
|
||||
|
||||
|
||||
# revision identifiers, used by Alembic.
|
||||
revision = 'd1edb3cadec8'
|
||||
down_revision = 'ac41029fb329'
|
||||
branch_labels = None
|
||||
depends_on = None
|
||||
|
||||
|
||||
def upgrade():
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
op.add_column('mailbox', sa.Column('disable_pgp', sa.Boolean(), server_default='0', nullable=False))
|
||||
# ### end Alembic commands ###
|
||||
|
||||
|
||||
def downgrade():
|
||||
# ### commands auto generated by Alembic - please adjust! ###
|
||||
op.drop_column('mailbox', 'disable_pgp')
|
||||
# ### end Alembic commands ###
|
Loading…
Reference in New Issue