refactor: support i18n

This commit is contained in:
mlogclub
2026-05-25 12:06:15 +08:00
parent 309ac1fe9e
commit 988f55c80d
179 changed files with 10968 additions and 3763 deletions
+2 -1
View File
@@ -7,6 +7,7 @@ import (
"cs-agent/internal/pkg/constants"
"cs-agent/internal/pkg/dto/request"
"cs-agent/internal/pkg/dto/response"
"cs-agent/internal/pkg/i18nx"
"cs-agent/internal/services"
"cs-agent/internal/pkg/httpx/params"
@@ -27,7 +28,7 @@ func MCPAnyCatalog(ctx *gin.Context) {
httpx.WriteJSON(ctx, err)
return
}
items, err := services.ToolCatalogService.ListMCPTools(context.Background())
items, err := services.ToolCatalogService.ListMCPToolsWithLocale(context.Background(), i18nx.Locale(ctx))
if err != nil {
httpx.WriteJSON(ctx, err)
return