mirror of
https://git.sr.ht/~tsileo/microblog.pub
synced 2024-08-20 00:54:38 +00:00
34 lines
970 B
Python
34 lines
970 B
Python
"""Tweak notification model
|
|
|
|
Revision ID: 1702e88016db
|
|
Revises: 50d26a370a65
|
|
Create Date: 2022-08-02 15:19:57.221421+00:00
|
|
|
|
"""
|
|
import sqlalchemy as sa
|
|
|
|
from alembic import op
|
|
|
|
# revision identifiers, used by Alembic.
|
|
revision = '1702e88016db'
|
|
down_revision = '50d26a370a65'
|
|
branch_labels = None
|
|
depends_on = None
|
|
|
|
|
|
def upgrade() -> None:
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
with op.batch_alter_table('notifications', schema=None) as batch_op:
|
|
batch_op.add_column(sa.Column('is_accepted', sa.Boolean(), nullable=True))
|
|
batch_op.add_column(sa.Column('is_rejected', sa.Boolean(), nullable=True))
|
|
|
|
# ### end Alembic commands ###
|
|
|
|
|
|
def downgrade() -> None:
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
with op.batch_alter_table('notifications', schema=None) as batch_op:
|
|
batch_op.drop_column('is_rejected')
|
|
batch_op.drop_column('is_accepted')
|
|
|
|
# ### end Alembic commands ###
|