Files
video-gen/video-gen-api/app/models/user_oauth_account.py
T
2026-06-16 15:59:52 +08:00

25 lines
883 B
Python

from sqlalchemy import ForeignKey, String
from sqlalchemy.orm import Mapped, mapped_column
from app.models.base import Base, TimestampMixin, SoftDeleteMixin
class UserOAuthAccount(Base, TimestampMixin, SoftDeleteMixin):
__tablename__ = "user_oauth_account"
id: Mapped[str] = mapped_column(
String(32), primary_key=True, comment="主键"
)
oauth_id: Mapped[str] = mapped_column(
String(64),
nullable=False, index=True, comment="授权表中的id"
)
advertiser_id: Mapped[str | None] = mapped_column(
String(64), nullable=True, index=True, comment="广告主账户id"
)
advertiser_name: Mapped[str | None] = mapped_column(
String(128), nullable=True, comment="广告账户名"
)
advertiser_role: Mapped[str | None] = mapped_column(
String(64), nullable=True, comment="广告账户类型"
)