代码拉取完成,页面将自动刷新
package devicemsglogic
import (
"gitee.com/unitedrhino/things/service/dmsvr/internal/domain/deviceLog"
"gitee.com/unitedrhino/things/service/dmsvr/pb/dm"
)
func ToDataHubLogIndex(log *deviceLog.Hub) *dm.HubLogInfo {
return &dm.HubLogInfo{
Timestamp: log.Timestamp.UnixMilli(),
Action: log.Action,
RequestID: log.RequestID,
TraceID: log.TraceID,
Topic: log.Topic,
Content: log.Content,
ResultCode: log.ResultCode,
RespPayload: log.RespPayload,
}
}
func ToDataSendLogIndex(log *deviceLog.Send) *dm.SendLogInfo {
return &dm.SendLogInfo{
Timestamp: log.Timestamp.UnixMilli(),
Account: log.Account,
UserID: log.UserID,
ProductID: log.ProductID,
DeviceName: log.DeviceName,
Action: log.Action,
DataID: log.DataID,
TraceID: log.TraceID,
Content: log.Content,
ResultCode: log.ResultCode,
}
}
func ToDataStatusLogIndex(log *deviceLog.Status) *dm.StatusLogInfo {
return &dm.StatusLogInfo{
Timestamp: log.Timestamp.UnixMilli(),
Status: log.Status,
ProductID: log.ProductID,
DeviceName: log.DeviceName,
}
}
// SDK调试日志
func ToDataSdkLogIndex(log *deviceLog.SDK) *dm.SdkLogInfo {
return &dm.SdkLogInfo{
Timestamp: log.Timestamp.UnixMilli(),
Loglevel: log.LogLevel,
Content: log.Content,
}
}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。