fix: 修复订阅列表查询逻辑并更新Dockerfile配置

修复订阅列表查询中服务器组为空时的处理逻辑,避免潜在错误
在getSubscribeListLogic.go中添加服务器数量统计功能
更新Dockerfile添加logs目录拷贝
清理ppanel.yaml配置文件中的合并冲突和冗余配置
This commit is contained in:
2025-08-17 04:28:32 -07:00
parent e898e6afbe
commit 41423ca666
4 changed files with 19 additions and 46 deletions
@@ -47,6 +47,13 @@ func (l *GetSubscribeListLogic) GetSubscribeList(req *types.GetSubscribeListRequ
l.Logger.Error("[GetSubscribeListLogic] JSON unmarshal failed: ", logger.Field("error", err.Error()), logger.Field("discount", item.Discount))
}
}
servers, err := l.svcCtx.ServerModel.FindServerListByGroupIds(l.ctx, sub.ServerGroup)
if err != nil {
l.Errorw("[QuerySubscribeListLogic] FindServerListByGroupIds error", logger.Field("error", err.Error()))
sub.ServerCount = 0
} else {
sub.ServerCount = int64(len(servers))
}
sub.Server = tool.StringToInt64Slice(item.Server)
sub.ServerGroup = tool.StringToInt64Slice(item.ServerGroup)
resultList = append(resultList, sub)