- 新增 ProductMessage 模型,挂载在 products.id(ON DELETE CASCADE)
- GET/POST /products/{id}/messages 接口
- 注册到 Alembic 自动发现
21 lines
598 B
Python
21 lines
598 B
Python
"""模型包 — 导入 Base 及所有模型,供 Alembic 自动发现"""
|
|
from app.models.base import Base
|
|
from app.models.production_order import ProductionOrder
|
|
from app.models.product import Product
|
|
from app.models.task import Task, TaskRecord
|
|
from app.models.task_log import TaskLog
|
|
from app.models.notification import Notification
|
|
from app.models.app_version import AppVersion
|
|
from app.models.message import ProductMessage
|
|
__all__ = [
|
|
"Base",
|
|
"ProductionOrder",
|
|
"Product",
|
|
"Task",
|
|
"TaskRecord",
|
|
"TaskLog",
|
|
"Notification",
|
|
"AppVersion",
|
|
"ProductMessage",
|
|
]
|