重构部分枚举, 让models包不依赖其他项目中的包

This commit is contained in:
2025-11-07 21:39:24 +08:00
parent 375af57afe
commit 2796d9bad7
17 changed files with 188 additions and 148 deletions

View File

@@ -2,8 +2,6 @@ package dto
import (
"git.huangwc.com/pig/pig-farm-controller/internal/infra/models"
"go.uber.org/zap/zapcore"
)
// NewListNotificationResponse 从模型数据创建通知列表响应 DTO
@@ -18,7 +16,7 @@ func NewListNotificationResponse(data []models.Notification, total int64, page,
UserID: item.UserID,
Title: item.Title,
Message: item.Message,
Level: zapcore.Level(item.Level),
Level: item.Level,
AlarmTimestamp: item.AlarmTimestamp,
ToAddress: item.ToAddress,
Status: item.Status,