mirror of
https://github.com/lucaspalomodevelop/eventcally.git
synced 2026-03-13 00:07:22 +00:00
44 lines
1.3 KiB
Python
44 lines
1.3 KiB
Python
"""empty message
|
|
|
|
Revision ID: 3f77c8693ae3
|
|
Revises: ec7a6b157860
|
|
Create Date: 2023-03-16 19:08:17.051573
|
|
|
|
"""
|
|
import sqlalchemy as sa
|
|
import sqlalchemy_utils
|
|
from alembic import op
|
|
from sqlalchemy.dialects import postgresql
|
|
|
|
from project import dbtypes
|
|
|
|
# revision identifiers, used by Alembic.
|
|
revision = "3f77c8693ae3"
|
|
down_revision = "ec7a6b157860"
|
|
branch_labels = None
|
|
depends_on = None
|
|
|
|
|
|
def upgrade():
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
op.drop_table("analytics")
|
|
op.add_column("settings", sa.Column("start_page", sa.UnicodeText(), nullable=True))
|
|
# ### end Alembic commands ###
|
|
|
|
|
|
def downgrade():
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
op.drop_column("settings", "start_page")
|
|
op.create_table(
|
|
"analytics",
|
|
sa.Column("id", sa.INTEGER(), autoincrement=True, nullable=False),
|
|
sa.Column("key", sa.VARCHAR(length=255), autoincrement=False, nullable=True),
|
|
sa.Column("value1", sa.VARCHAR(length=255), autoincrement=False, nullable=True),
|
|
sa.Column("value2", sa.VARCHAR(length=255), autoincrement=False, nullable=True),
|
|
sa.Column(
|
|
"created_at", postgresql.TIMESTAMP(), autoincrement=False, nullable=True
|
|
),
|
|
sa.PrimaryKeyConstraint("id", name="analytics_pkey"),
|
|
)
|
|
# ### end Alembic commands ###
|