fix: 重命名通知渠道模型避免与 alert 模块冲突
All checks were successful
continuous-integration/drone/push Build is passing

- NotificationChannel -> TaskNotifyChannel
- platform_notification_channels -> platform_task_notify_channels
This commit is contained in:
2026-01-28 17:06:28 +08:00
parent 2fbba63884
commit b8e19dcde6
4 changed files with 23 additions and 23 deletions

View File

@@ -9,7 +9,7 @@ from .logs import PlatformLog
from .alert import AlertRule, AlertRecord, NotificationChannel
from .pricing import ModelPricing, TenantBilling
from .scheduled_task import ScheduledTask, TaskLog, ScriptVar, Secret
from .notification_channel import NotificationChannel
from .notification_channel import TaskNotifyChannel
__all__ = [
"Tenant",
@@ -31,5 +31,5 @@ __all__ = [
"TaskLog",
"ScriptVar",
"Secret",
"NotificationChannel"
"TaskNotifyChannel"
]

View File

@@ -1,12 +1,12 @@
"""通知渠道模型"""
"""任务通知渠道模型"""
from datetime import datetime
from sqlalchemy import Column, Integer, String, Enum, Boolean, DateTime
from ..database import Base
class NotificationChannel(Base):
"""通知渠道表"""
__tablename__ = "platform_notification_channels"
class TaskNotifyChannel(Base):
"""任务通知渠道表(用于定时任务推送)"""
__tablename__ = "platform_task_notify_channels"
id = Column(Integer, primary_key=True, autoincrement=True)
tenant_id = Column(String(50), nullable=False)