- Add subscription_link column to users table (nullable, unique) - Add SUBSCRIPTION_URL to config settings - Update user creation to include subscription link from Remnawave - Add support subscription ticket creation with formatted message - Add "update link" button to main menu - Refactor support subscription formatting to include user details
35 lines
1.0 KiB
Python
35 lines
1.0 KiB
Python
"""user -> +subscription_link optional text.
|
|
|
|
Revision ID: 5985b2df0830
|
|
Revises: 756210f564a5
|
|
Create Date: 2026-04-09 20:38:15.157762
|
|
|
|
"""
|
|
|
|
from typing import Sequence, Union
|
|
|
|
from alembic import op
|
|
import sqlalchemy as sa
|
|
|
|
# revision identifiers, used by Alembic.
|
|
revision: str = "5985b2df0830"
|
|
down_revision: Union[str, Sequence[str], None] = "756210f564a5"
|
|
branch_labels: Union[str, Sequence[str], None] = None
|
|
depends_on: Union[str, Sequence[str], None] = None
|
|
|
|
|
|
def upgrade() -> None:
|
|
"""Upgrade schema."""
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
op.add_column("users", sa.Column("subscription_link", sa.TEXT(), nullable=True))
|
|
op.create_unique_constraint(None, "users", ["subscription_link"])
|
|
# ### end Alembic commands ###
|
|
|
|
|
|
def downgrade() -> None:
|
|
"""Downgrade schema."""
|
|
# ### commands auto generated by Alembic - please adjust! ###
|
|
op.drop_constraint(None, "users", type_="unique")
|
|
op.drop_column("users", "subscription_link")
|
|
# ### end Alembic commands ###
|