From dc617f8d0b17af3c26781d8421db4dcb7e7034c9 Mon Sep 17 00:00:00 2001 From: qiwang <1364512070@qq.com> Date: Thu, 25 May 2023 14:40:21 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E4=BF=AE=E6=94=B9=E7=AE=97=E6=B3=95?= =?UTF-8?q?=E5=88=97=E8=A1=A8bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Former-commit-id: 209d77bab8ae3ca1ead5558bf512ceb03fd00901 --- .../PCM-MODELARTS/rpc/internal/logic/listalgorithmslogic.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/adaptor/PCM-AI/PCM-MODELARTS/rpc/internal/logic/listalgorithmslogic.go b/adaptor/PCM-AI/PCM-MODELARTS/rpc/internal/logic/listalgorithmslogic.go index b0f06806..f4a947a4 100644 --- a/adaptor/PCM-AI/PCM-MODELARTS/rpc/internal/logic/listalgorithmslogic.go +++ b/adaptor/PCM-AI/PCM-MODELARTS/rpc/internal/logic/listalgorithmslogic.go @@ -46,7 +46,7 @@ func (l *ListAlgorithmsLogic) ListAlgorithms(in *modelarts.ListAlgorithmsReq) (* if modelArtsType == l.svcCtx.Config.HaweiModelArtsType { modelArtsUrl := l.svcCtx.Config.ModelArtsUrl - url := modelArtsUrl + in.ProjectId + "v2/" + "/algorithms?offset=" + offset + "&" + "limit=" + limit + url := modelArtsUrl + "v2/" + in.ProjectId + "/algorithms?offset=" + offset + "&" + "limit=" + limit token := common.GetToken() statusCode, body, err := tool.HttpClientWithBodyAndCode(tool.GET, url, nil, token) if err != nil { @@ -72,7 +72,7 @@ func (l *ListAlgorithmsLogic) ListAlgorithms(in *modelarts.ListAlgorithmsReq) (* Key: AK, Secret: SK, } - r, err := http.NewRequest("GET", NanjingModelArtsUrl+in.ProjectId+"/algorithms?offset="+offset+"&"+"limit="+limit, + r, err := http.NewRequest("GET", NanjingModelArtsUrl+"v2/"+in.ProjectId+"/algorithms?offset="+offset+"&"+"limit="+limit, bytes.NewBuffer([]byte("foo=bar"))) if err != nil { fmt.Println(err)