mirror of
https://github.com/Mailu/Mailu.git
synced 2024-12-14 10:53:30 +02:00
b88f61f183
Prefious commit set the constraint names for existing databases. New databases can now have named constraints from the ground up.
26 lines
516 B
Python
26 lines
516 B
Python
""" Add a configuration table
|
|
|
|
Revision ID: cd79ed46d9c2
|
|
Revises: 25fd6c7bcb4a
|
|
Create Date: 2018-10-17 21:44:48.924921
|
|
|
|
"""
|
|
|
|
revision = 'cd79ed46d9c2'
|
|
down_revision = '3b281286c7bd'
|
|
|
|
from alembic import op
|
|
import sqlalchemy as sa
|
|
|
|
|
|
def upgrade():
|
|
op.create_table('config',
|
|
sa.Column('name', sa.String(length=255), nullable=False),
|
|
sa.Column('value', sa.String(length=255), nullable=True),
|
|
sa.PrimaryKeyConstraint('name', name=op.f('config_pkey'))
|
|
)
|
|
|
|
|
|
def downgrade():
|
|
op.drop_table('config')
|