refactor(models): Use the SQLAlchemy base model. (#19435)
Signed-off-by: -LAN- <laipz8200@outlook.com>
This commit is contained in:
parent
2ad7305349
commit
792b321a81
8 changed files with 61 additions and 87 deletions
|
|
@ -2,6 +2,7 @@ import enum
|
|||
|
||||
from sqlalchemy import func
|
||||
|
||||
from .base import Base
|
||||
from .engine import db
|
||||
from .types import StringUUID
|
||||
|
||||
|
|
@ -13,7 +14,7 @@ class APIBasedExtensionPoint(enum.Enum):
|
|||
APP_MODERATION_OUTPUT = "app.moderation.output"
|
||||
|
||||
|
||||
class APIBasedExtension(db.Model): # type: ignore[name-defined]
|
||||
class APIBasedExtension(Base):
|
||||
__tablename__ = "api_based_extensions"
|
||||
__table_args__ = (
|
||||
db.PrimaryKeyConstraint("id", name="api_based_extension_pkey"),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue